Issue with installing OpenAI's Spinning Up on macOS

I’m trying to install the Spinning Up library from OpenAI on my macOS and following the installation steps. However, when I check if it’s properly set up, I run into issues.

I executed the following command:

python -m spinup.run ppo --hid [32,32] --env Walker2d-v2 --exp_name installtest

Yet, I encounter the following error:

Traceback (most recent call last):
File “/Users/Leon/spinningup/spinup/utils/run_entrypoint.py”, line 10, in
thunk = pickle.loads(zlib.decompress(base64.b64decode(args.encoded_thunk)))
File “/Users/Leon/anaconda/lib/python3.6/site-packages/cloudpickle/cloudpickle.py”, line 800, in _make_skel_func
closure = _reconstruct_closure(closures) if closures else None
File “/Users/Leon/anaconda/lib/python3.6/site-packages/cloudpickle/cloudpickle.py”, line 792, in _reconstruct_closure
return tuple([_make_cell(v) for v in values])
TypeError: ‘int’ object is not iterable

What could be causing this problem?

definitely sounds like a cloudpickle problem dude. had similar stuff on python 3.6. try going back to cloudpickle 1.2.2 or maybe even update python, cause that pickle module is kinda finicky with closures.

This happens when Spinning Up’s Python dependencies don’t play nice together. The cloudpickle serialization breaks during multiprocessing setup for parallel training. I ran into the same thing - had conflicting gym and mujoco-py versions with an old numpy install. Create a fresh conda environment with Python 3.7 and reinstall Spinning Up from scratch. Also make sure you’ve got the right MuJoCo binaries since Walker2d-v2 needs them. That base64 decoding error means the pickled function got corrupted between processes.

This topic was automatically closed 4 days after the last reply. New replies are no longer allowed.