huggingface / huggingface/deep-rl-class
[HANDS-ON BUG] unit 3: cannot load the correct trained model
- Dominant language
- MDX
- Stars
- 5k
- Forks
- 811
- PR merge metrics
- No merged PRs in 30d
Description
# Describe the bug
I finished the training an agent with RL-Baselines3-Zoo. The model was saved to the path" /usr/local/lib/python3.12/dist-packages/rl_zoo3/logs//dqn/SpaceInvadersNoFrameskip-v4_1"
However, when I try to evaluate the trained agent by running these commands
!cd "/usr/local/lib/python3.12/dist-packages/rl_zoo3/"
!python -m rl_zoo3.enjoy --algo dqn --env SpaceInvadersNoFrameskip-v4 --no-render --n-timesteps 5000 --folder logs/
I got the following error "ValueError: No model found for dqn on SpaceInvadersNoFrameskip-v4, path: logs/dqn/SpaceInvadersNoFrameskip-v4.zip"
I did check the content in the path by using the command
!ls "/usr/local/lib/python3.12/dist-packages/rl_zoo3/logs/dqn/"
I realize that SpaceInvadersNoFrameskip-v4.zip was saved in the "/usr/local/lib/python3.12/dist-packages/rl_zoo3/logs/dqn/SpaceInvadersNoFrameskip" subdirectory, rather than the directory "/usr/local/lib/python3.12/dist-packages/rl_zoo3/logs/dqn/"
In this case, without changing train.py and enjoy.py, is there any other way to solve this bug?
# Material
- Did you use Google Colab? Yes
If not:
- Your Operating system (OS): Mac OS Big Sur
- Version of your OS: 11.7.10
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.