[python] How to store and retrieve a dictionary with redis