AI4Finance-Foundation / ElegantRL

Massively Parallel Deep Reinforcement Learning. 🔥
https://ai4finance.org
Other
3.56k stars 819 forks source link

TypeError: cannot pickle 'isaacgym._bindings.linux-x86_64.gym_38.Gym' object #221

Open 13253591602 opened 1 year ago

13253591602 commented 1 year ago

When I run examples/demo_Isaac_Gym.py. The following error has occurred:

Traceback (most recent call last): File "examples/demo_IsaacGym.py", line 81, in demo(task) File "examples/demo_IsaacGym.py", line 76, in demo train_and_evaluate(args) File "/home/yh/py-packages/ElegantRL/elegantrl/train/run.py", line 89, in train_and_evaluate evaluator = init_evaluator(args, gpu_id) File "/home/yh/py-packages/ElegantRL/elegantrl/train/run.py", line 68, in init_evaluator eval_env = build_env(args.env, eval_func, eval_args) File "/home/yh/py-packages/ElegantRL/elegantrl/train/config.py", line 208, in build_env env = deepcopy(env) File "/home/yh/anaconda3/envs/erl/lib/python3.8/copy.py", line 172, in deepcopy y = _reconstruct(x, memo, rv) File "/home/yh/anaconda3/envs/erl/lib/python3.8/copy.py", line 270, in _reconstruct state = deepcopy(state, memo) File "/home/yh/anaconda3/envs/erl/lib/python3.8/copy.py", line 146, in deepcopy y = copier(x, memo) File "/home/yh/anaconda3/envs/erl/lib/python3.8/copy.py", line 230, in _deepcopy_dict y[deepcopy(key, memo)] = deepcopy(value, memo) File "/home/yh/anaconda3/envs/erl/lib/python3.8/copy.py", line 172, in deepcopy y = _reconstruct(x, memo, rv) File "/home/yh/anaconda3/envs/erl/lib/python3.8/copy.py", line 270, in _reconstruct state = deepcopy(state, memo) File "/home/yh/anaconda3/envs/erl/lib/python3.8/copy.py", line 146, in deepcopy y = copier(x, memo) File "/home/yh/anaconda3/envs/erl/lib/python3.8/copy.py", line 230, in _deepcopy_dict y[deepcopy(key, memo)] = deepcopy(value, memo) File "/home/yh/anaconda3/envs/erl/lib/python3.8/copy.py", line 161, in deepcopy rv = reductor(4) TypeError: cannot pickle 'isaacgym._bindings.linux-x86_64.gym_38.Gym' object

I use Isaac Gym - Preview 4 Release.

Yonv1943 commented 1 year ago

In addition:

13253591602 commented 1 year ago

In addition:

yeah, this function works well on my server

Timkeeper2018 commented 1 year ago

" RTX3080ti , Isaac Gym - Preview 4 " got this error too.

mikygit commented 1 year ago

Is there a workaround a part from downgrading IsaacGym?

Skylark0924 commented 1 year ago

" RTX3090 , Isaac Gym - Preview 4 " got this error too.