-
-
Notifications
You must be signed in to change notification settings - Fork 907
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
How can be modified the max steps parameter in CartPole env? #397
Comments
thank you @Kallinteris-Andreas I tried to run your suggested code as following
but this arises the following error that is beyond my comprehension skills, but probably conflicts with the following TensorFlow instruction tf_py_environment.TFPyEnvironment
|
|
@pseudo-rnd-thoughts thank you, the error was due the Tensorflow TFPyEnvironment that I do not master; but you and @Kallinteris-Andreas "inspired" me. so giving a look to tf_agents.environments.suite_gym.load I found
so that the instantiation should take the parameter max_episode_steps and pass it to the environment instantiation. So the following code
is not giving any error anymore, but running the training code I can see that it is still limited to 500 steps as the maximum. In the training code, I reset the environment when
hope that is last part was correctly coded. So the question: have you ever tried to train a CartPole environment with more than max 500 steps, for instance, 5000? Or less? Has it changed anything? |
Sorry, I just saw this again. |
Question
I need to extend the max steps parameter of the CartPole environment. I looked around and found some proposals for Gym rather than Gymnasium such as something similar to this:
found here openai/gym#463
but in my case seems to not work:
Is there any other way? Thank you.
The text was updated successfully, but these errors were encountered: