def float_eq(a, b):
    return abs(a - b) < 0.01
A = FuzzyDict(float_eq=float_eq)
B = FuzzyDict(float_eq=float_eq)
A['a'] = 2.345
A['b'] = 'a string'
B['a'] = 2.345
B['b'] = 'a string'
B['a'] = 2.3445
A == B
B['a'] = 234.55
A == B
B['a'] = 2.345
B['b'] = 'a strin'
A == B
Comparing Python dicts with floating point values included