huggingface / huggingface/deep-rl-class

[HANDS-ON BUG] Unit 4 PixelCopter environment not found

Open
#648 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
MDX
Stars
5k
Forks
811
PR merge metrics
No merged PRs in 30d

Description

# Describe the bug

When trying to code the notebook of unit 4, I cannot create the pixelcopter enviroment.

Code:
`env_id = "Pixelcopter-PLE-v0"
env = gym.make(env_id)
eval_env = gym.make(env_id)
s_size = env.observation_space.shape[0]
a_size = env.action_space.n`

Error:
`---------------------------------------------------------------------------

NameNotFound Traceback (most recent call last)

[/tmp/ipython-input-881273010.py](https://localhost:8080/#) in ()
1 env_id = "Pixelcopter-PLE-v0"
----> 2 env = gym.make(env_id)
3 eval_env = gym.make(env_id)
4 s_size = env.observation_space.shape[0]
5 a_size = env.action_space.n

3 frames

[/usr/local/lib/python3.12/dist-packages/gym/envs/registration.py](https://localhost:8080/#) in _assert_name_exists(self, namespace, name)
295 message += f" Did you mean: `{suggestions[0]}`?"
296 # Throw the error
--> 297 raise error.NameNotFound(message)
298
299 def _assert_version_exists(

NameNotFound: Environment `Pixelcopter-PLE` doesn't exist.`

A clear and concise description of what the bug is.
**Please share your notebook link so that we can reproduce the error**
[notebook url](https://colab.research.google.com/drive/1ZerBPukIHAeMkC_epOxWBf4PlFr6C9Si?usp=sharing)

# Material

- Did you use Google Colab? Yes

If not:
- Your Operating system (OS)
- Version of your OS

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.