Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to convert function return value to a Python type #332

Open
TianrongChen opened this issue Jun 18, 2019 · 1 comment
Open

Unable to convert function return value to a Python type #332

TianrongChen opened this issue Jun 18, 2019 · 1 comment

Comments

@TianrongChen
Copy link

Answer the following questions:

  • what are you trying to do?

  • what is the problem and how can it be recreated?

  • what scrimmage commit are you on? You can see this with git rev-parse HEAD

  • describe any changes you made to scrimmage.

  • If you can recreate the issue using only plugins in the scrimmage repository, what mission file are you running?

@TianrongChen
Copy link
Author

I tried to run the scrimmage in my project. I install scrimmage and scrimmage bind successfully, but it seems like that the problem occurred when we run the environment.
We bind the openai env in this case, and it returns a error report as following:
Traceback (most recent call last):
File "/usr/lib/python3.6/runpy.py", line 193, in _run_module_as_main
"main", mod_spec)
File "/usr/lib/python3.6/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/home/iamctr/Desktop/papers/MARL/Hierarchical-Learning-integration/submodules/evolutionary-strategies-agent/es_distributed/main.py", line 122, in
cli()
File "/home/iamctr/Desktop/papers/MARL/MARL/lib/python3.6/site-packages/click/core.py", line 764, in call
return self.main(*args, **kwargs)
File "/home/iamctr/Desktop/papers/MARL/MARL/lib/python3.6/site-packages/click/core.py", line 717, in main
rv = self.invoke(ctx)
File "/home/iamctr/Desktop/papers/MARL/MARL/lib/python3.6/site-packages/click/core.py", line 1137, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/home/iamctr/Desktop/papers/MARL/MARL/lib/python3.6/site-packages/click/core.py", line 956, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/home/iamctr/Desktop/papers/MARL/MARL/lib/python3.6/site-packages/click/core.py", line 555, in invoke
return callback(*args, **kwargs)
File "/home/iamctr/Desktop/papers/MARL/Hierarchical-Learning-integration/submodules/evolutionary-strategies-agent/es_distributed/main.py", line 63, in master
run_master(redis_cfg, log_dir, exp)
File "/home/iamctr/Desktop/papers/MARL/Hierarchical-Learning-integration/submodules/evolutionary-strategies-agent/es_distributed/es.py", line 216, in run_master
config, env, sess, policy = setup(exp, single_threaded=False)
File "/home/iamctr/Desktop/papers/MARL/Hierarchical-Learning-integration/submodules/evolutionary-strategies-agent/es_distributed/es.py", line 165, in setup
env = create_scrimmage_env(**exp['env'])
File "/home/iamctr/Desktop/papers/MARL/Hierarchical-Learning-integration/submodules/evolutionary-strategies-agent/es_distributed/es.py", line 156, in create_scrimmage_env
return gym.make(env_id)
File "/home/iamctr/Desktop/papers/MARL/MARL/lib/python3.6/site-packages/gym/envs/registration.py", line 167, in make
return registry.make(id)
File "/home/iamctr/Desktop/papers/MARL/MARL/lib/python3.6/site-packages/gym/envs/registration.py", line 130, in make
max_episode_seconds=env.spec.max_episode_seconds)
File "/home/iamctr/Desktop/papers/MARL/MARL/lib/python3.6/site-packages/gym/wrappers/time_limit.py", line 6, in init
super(TimeLimit, self).init(env)
File "/home/iamctr/Desktop/papers/MARL/MARL/lib/python3.6/site-packages/gym/core.py", line 243, in init
self.action_space = self.env.action_space
TypeError: Unable to convert function return value to a Python type! The signature was
(arg0: scrimmage.bindings.py_bindings.ScrimmageOpenAIEnv) -> object

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant