2

I am following this guide here,

https://spinningup.openai.com/en/latest/user/installation.html

conda create -n spinningup python=3.6

source activate spinningup

git clone https://github.com/openai/spinningup.git

cd spinningup

pip install -e .

And I get the following error: enter image description here

I have overriden that error by

export PIP_REQUIRE_VIRTUALENV=false

But the none of the installed packages are not shown in the conda package list, it appears the packages are installed on the main python environment, not conda environment?

Installed dependencies not shown

which pip

does point to correct conda pip directory however.

enter image description here Pip list shows gym is installed, but when I open juptyer lab from this same terminal :

enter image description here

According to this link:

Most of the time (with some exceptions) there isn’t much of a difference between installing packages through conda or through pip. This is because pip packages are also installable into Conda environments.

It should have been installed into conda env I have created, but why isn't this working?

How can I fix this? I wish to install everything specified in this spinningup requirement.txt on conda env, like the guide suggested.

Many thanks in advance.

zcahfg2
  • 861
  • 1
  • 12
  • 27
  • did you check this? https://stackoverflow.com/questions/16460313/pip-could-not-find-an-activated-virtualenv-required . – Manoj Kengudelu Nov 12 '18 at 17:30
  • Yes, that is the exactly why I mention "setting PIP_REQUIRE_VIRTUALENV=false" here. If I do that, it installs in the main Python environment, not Conda environment. I want these dependencies to be installed in Conda env like the guide suggested. – zcahfg2 Nov 12 '18 at 17:57
  • 1
    What version of conda are you using? `source activate` is quite old; you should be using `conda activate`. – BallpointBen Nov 12 '18 at 21:00
  • 1
    As for the actual issue you're facing, you probably need to `conda install pip` into the active environment so that `pip` refers to that environment's pip, not the system pip. – BallpointBen Nov 12 '18 at 21:01
  • I am using the latest version of conda. Thank you for conda activate tip. 'which pip' already points to /anaconda3/envs/spinningup/bin/pip so this isn't the issue.. – zcahfg2 Nov 12 '18 at 21:06

0 Answers0