-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
ModuleNotFoundError: No module named 'baselines' #227
Comments
pip install baseline |
Should it be in the requirements of this project then? Btw, Collecting baselines
Using cached baselines-0.1.5.tar.gz (123 kB)
Preparing metadata (setup.py) ... done
Requirement already satisfied: gym[atari,classic_control,mujoco,robotics] in /usr/local/lib/python3.11/dist-packages (from baselines) (0.25.2)
Requirement already satisfied: scipy in /usr/local/lib/python3.11/dist-packages (from baselines) (1.13.1)
Requirement already satisfied: tqdm in /usr/local/lib/python3.11/dist-packages (from baselines) (4.67.1)
Requirement already satisfied: joblib in /usr/local/lib/python3.11/dist-packages (from baselines) (1.4.2)
Collecting zmq (from baselines)
Using cached zmq-0.0.0.zip (2.2 kB)
Preparing metadata (setup.py) ... done
Collecting dill (from baselines)
Using cached dill-0.3.9-py3-none-any.whl.metadata (10 kB)
Requirement already satisfied: progressbar2 in /usr/local/lib/python3.11/dist-packages (from baselines) (4.5.0)
Collecting mpi4py (from baselines)
Using cached mpi4py-4.0.2.tar.gz (466 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Installing backend dependencies ... done
Preparing metadata (pyproject.toml) ... done
Requirement already satisfied: cloudpickle in /usr/local/lib/python3.11/dist-packages (from baselines) (3.1.1)
Requirement already satisfied: tensorflow>=1.4.0 in /usr/local/lib/python3.11/dist-packages (from baselines) (2.18.0)
Requirement already satisfied: click in /usr/local/lib/python3.11/dist-packages (from baselines) (8.1.8)
Requirement already satisfied: absl-py>=1.0.0 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (1.4.0)
Requirement already satisfied: astunparse>=1.6.0 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (1.6.3)
Requirement already satisfied: flatbuffers>=24.3.25 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (25.1.24)
Requirement already satisfied: gast!=0.5.0,!=0.5.1,!=0.5.2,>=0.2.1 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (0.6.0)
Requirement already satisfied: google-pasta>=0.1.1 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (0.2.0)
Requirement already satisfied: libclang>=13.0.0 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (18.1.1)
Requirement already satisfied: opt-einsum>=2.3.2 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (3.4.0)
Requirement already satisfied: packaging in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (24.2)
Requirement already satisfied: protobuf!=4.21.0,!=4.21.1,!=4.21.2,!=4.21.3,!=4.21.4,!=4.21.5,<6.0.0dev,>=3.20.3 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (4.25.6)
Requirement already satisfied: requests<3,>=2.21.0 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (2.32.3)
Requirement already satisfied: setuptools in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (75.1.0)
Requirement already satisfied: six>=1.12.0 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (1.17.0)
Requirement already satisfied: termcolor>=1.1.0 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (2.5.0)
Requirement already satisfied: typing-extensions>=3.6.6 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (4.12.2)
Requirement already satisfied: wrapt>=1.11.0 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (1.17.2)
Requirement already satisfied: grpcio<2.0,>=1.24.3 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (1.70.0)
Requirement already satisfied: tensorboard<2.19,>=2.18 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (2.18.0)
Requirement already satisfied: keras>=3.5.0 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (3.8.0)
Requirement already satisfied: numpy<2.1.0,>=1.26.0 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (1.26.4)
Requirement already satisfied: h5py>=3.11.0 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (3.12.1)
Requirement already satisfied: ml-dtypes<0.5.0,>=0.4.0 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (0.4.1)
Requirement already satisfied: tensorflow-io-gcs-filesystem>=0.23.1 in /usr/local/lib/python3.11/dist-packages (from tensorflow>=1.4.0->baselines) (0.37.1)
WARNING: gym 0.25.2 does not provide the extra 'robotics'
Requirement already satisfied: gym_notices>=0.0.4 in /usr/local/lib/python3.11/dist-packages (from gym[atari,classic_control,mujoco,robotics]->baselines) (0.0.8)
INFO: pip is looking at multiple versions of gym[atari,classic-control,mujoco,robotics] to determine which version is compatible with other requirements. This could take a while.
Collecting gym[atari,classic_control,mujoco,robotics] (from baselines)
Downloading gym-0.26.2.tar.gz (721 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 721.7/721.7 kB 15.3 MB/s eta 0:00:00
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
WARNING: gym 0.26.2 does not provide the extra 'robotics'
Collecting ale-py~=0.8.0 (from gym[atari,classic_control,mujoco,robotics]->baselines)
Downloading ale_py-0.8.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (8.1 kB)
Collecting pygame==2.1.0 (from gym[atari,classic_control,mujoco,robotics]->baselines)
Downloading pygame-2.1.0.tar.gz (5.8 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 5.8/5.8 MB 71.5 MB/s eta 0:00:00
error: subprocess-exited-with-error
× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
Preparing metadata (setup.py) ... error
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.v |
Then try installing pygame before baselines |
Looks like the problem is in outdated pypi package of I was able to install from source ModuleNotFoundError Traceback (most recent call last)
[<ipython-input-3-c78a96aa2548>](https://localhost:8080/#) in <cell line: 0>()
5 from dopamine.jax.agents.quantile import quantile_agent
6 from dopamine.jax.agents.rainbow import rainbow_agent
----> 7 from dopamine.replay_memory import circular_replay_buffer
8 from dopamine.utils import example_viz_lib
9 import gin
ModuleNotFoundError: No module named 'dopamine.replay_memory' |
!pip install --upgrade --no-cache-dir git+https://github.com/google/dopamine.git # Reinstalling dopamine Restart the runtime after this installation.Try importing again:from dopamine.replay_memory import circular_replay_buffer See i tried this but i think there is some issue with the file structure of the installed package or a conflict with other installed libraries.Double-check the output of !pip show dopamine to ensure it's installed and points to the correct location. You may need to examine the package structure to ensure replay_memory and circular_replay_buffer are present in the expected locations. |
Installing both from souce !pip install git+https://github.com/openai/baselines git+https://github.com/google/dopamine.git fails The conflict is caused by:
|
Hello.
When running jax_agent_visualizer.ipynb notebook in colab this error is raised on
from dopamine.discrete_domains import atari_lib
The text was updated successfully, but these errors were encountered: