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

[bug report] sac, ddpg, deepq: train.py: error: unrecognized arguments: --policy #43

Open
ncble opened this issue May 21, 2019 · 2 comments
Labels
bug Something isn't working

Comments

@ncble
Copy link
Collaborator

ncble commented May 21, 2019

Describe the bug
In the scripts rl_baselines/rl_algorithm/sac.py, deepq.py, ddpg.py:

  def customArguments(self, parser):
    ## forget to add: super().customArguments(parser)

Code example
The following command line reproduces the issue:

  • python -m rl_baselines.train --algo sac -c --policy lstm --num-timesteps 10000 --env MobileRobotGymEnv-v0
  • python -m rl_baselines.train --algo deepq -c --policy lstm --num-timesteps 10000 --env MobileRobotGymEnv-v0
  • python -m rl_baselines.train --algo ddpg -c --policy lstm --num-timesteps 10000 --env MobileRobotGymEnv-v0
@araffin
Copy link
Owner

araffin commented May 21, 2019

Hello,
Recurrent policies are not supported by those algorithms. Anyway, it seems also like a legit bug, thanks.

@araffin araffin added the bug Something isn't working label May 21, 2019
@kalifou
Copy link
Collaborator

kalifou commented May 21, 2019

Hi, thanks for noticing the bug.
As the repository as been updated few hours ago (pending PR now closed),
these policies are now available
policy_fn = {'cnn': "CnnPolicy", 'cnn-lstm': "CnnLstmPolicy", 'cnn-lnlstm': "CnnLnLstmPolicy", 'mlp': "MlpPolicy", 'lstm': "MlpLstmPolicy", 'lnlstm': "MlpLnLstmPolicy"}[args.policy] (see rl_baselines/base_classes.py, L241)

and it seems like your fix might work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants