Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
432 views
in Technique[技术] by (71.8m points)

python - Why Anaconda does not recognize conda command?

I installed the latest version of Anaconda. Now I want to install OpenCV within it. When I type:

conda install -c https://conda.binstar.org/anaconda opencv

I get this message error: "conda is not recognized as internal command ..." (sorry, I try to translate from French because my OS is in French)

The problem is that conda comes with Anaconda, so I wonder why lauching Anaconda and type the above command does not work ?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

For Windows

Go to Control PanelSystem and SecuritySystemAdvanced System Settings then look for Environment Variables.

Your user variables should contain Path=PathoAnaconda3Scripts.

You need to figure where your Anaconda3 folder is (i.e. the path to this folder) . Mine was in C:Users.

For Linux

You need to add conda to PATH. To do so, type:

export PATH=/path/to/anaconda3/bin:$PATH.

Same thing, you need to figure the path to anaconda3 folder (Usually, the path is stored in $HOME)

If you don't want to do this everytime you start a session, you can also add conda to PATH in your .bashrc file:

echo 'export PATH=/path/to/anaconda3/bin:$PATH' >> ~/.bashrc


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...