python dictionary based on perfect minimal hashing