Closed theo-michel closed 1 year ago
The examples are set up to be run from the meltingpot root directory, so instead of:
cd <meltingpot_root>/examples/rllib
python3 self_play_train.py
You should run with:
cd <meltingpot_root>
python3 examples/rllib/self_play_train.py
If that doesn't work either, you can also take a look at test-extras.sh for how we run it. The issue is fundamentally that we don't install the extras into your python directory, and we don't assume anything about your general dev setup. Instead, we provide an example that could be run from your usual project root.
Description: I am trying to get familiar with the Melting Pot environment in order to create my own environment. However, I encountered an issue while trying to run the rllib example provided in the repository.
Steps to reproduce:
cd <meltingpot_root>
pip3 install -e .[rllib]
cd <meltingpot_root>/examples/rllib
python3 self_play_train.py
Expected behavior: The self_play_train.py script should run successfully without any errors.
Actual behavior: When running the self_play_train.py script, I encounter the following error:
Additional information: It appears that the self_play_train.py script is unable to find the 'examples' module, leading to the ModuleNotFoundError.
Possible solution: A fix I found is running
export PYTHONPATH=$(pwd)
in the parent directoryFurther improvements: I think it is not clear in the Readme that this is needed for the rllib example as well. Or maybe there is a more convenient fix