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

reset() takes 1 positional argument but 2 were given #5

Closed
soomean opened this issue Oct 22, 2021 · 4 comments
Closed

reset() takes 1 positional argument but 2 were given #5

soomean opened this issue Oct 22, 2021 · 4 comments

Comments

@soomean
Copy link

soomean commented Oct 22, 2021

Hello,
thank you for the great work!

While running vae_motion/train_controller.py,
An error shows up as below:

logger.warn(
Traceback (most recent call last):
File "train_controller.py", line 240, in
main()
File "train_controller.py", line 206, in main
obs = env.reset(reset_indices)
TypeError: reset() takes 1 positional argument but 2 were given

Can I ask how it would be fixed?

@soomean
Copy link
Author

soomean commented Oct 22, 2021

I resolved this issue.
In my version of the code, I needed to use the named argument for that.

I'll close this by myself.

Best,

@soomean soomean closed this as completed Oct 22, 2021
@edentliang
Copy link

Hello, I got the same problem like yours, but I have no idea where is the issue. Can u give some hints?

Thank you

@soomean
Copy link
Author

soomean commented Apr 13, 2022

Hi, @edentliang
In my case, the error was gone by explicitly setting reset_indices with its keyword as obs = env.reset(indices=reset_indices).

@edentliang
Copy link

@soomean oh, it works. Thank you again. Very curious about the named argument, since I can't find that in the gym package

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

2 participants