changed cloud,pickle -> dill for better support of function pickling
Automatic style corrections courtesy of autopep8