0

I want try this command:

rllib train --env=Pong-ram-v4 --run=PPO

but rllib is can't find, I can do this by directly execute train.py in rllib source code, but run with a command is certainly more elegant. can some one tell me what's wrong?

here is the command I install ray:

pip install ray[rllib]

I try install it with/without virutual environment, both failed.

Progman
  • 16,827
  • 6
  • 33
  • 48
scott huang
  • 2,478
  • 4
  • 21
  • 36
  • You said that `pip install ray[rllib]` failed. Can you share the error message? – Robert Nishihara Feb 28 '19 at 23:13
  • the installation is sucessfull. I can import ray and rllib in a python script, I just can't user rllib as a shell command. – scott huang Mar 01 '19 at 04:15
  • Maybe you're using an old version of Ray? Try `pip install -U --force-reinstall ray` and make sure `python -c "import ray; print(ray.__version__)"` prints at least `0.6.3`. Also, try `which ray` and look in the same directory as that executable and see if there is an `rllib` executable. – Robert Nishihara Mar 01 '19 at 04:54
  • This appears to have been addressed at https://groups.google.com/d/topic/ray-dev/FMNa1K6789M/discussion. – Robert Nishihara Mar 14 '19 at 22:50

2 Answers2

2

pip install 'ray[rllib]' should work. When using special characters like '[' and ']', it is safe to use an apostrophe before and after the module name.

aargun
  • 126
  • 4
0

The problem here is not the installation of ray/rllib. It is the python installation that is not done correctly. Meaning, that not all library paths are in the system path. You need to add the "site packages" folder to your system path.

Take a look here to figure out how to find the path: How do I find the location of my Python site-packages directory?

Rocket
  • 1,030
  • 5
  • 24