News from this site

 Rental advertising space, please contact the webmaster if you need cooperation


+focus
focused

classification  

no classification

tag  

no tag

date  

no datas

PyCharm添加Anaconda中的虚拟环境,Python解释器出现Conda executable is not found

posted on 2023-05-21 17:51     read(1130)     comment(0)     like(10)     collect(3)


After Anaconda configures the virtual environment , the environment needs to be added to PyCharm. (Or when creating a new project, set the operating environment for a certain project), choose Conda Environment, and sometimes the Conda executable is not found error will appear.
The error source of this article is in the process of configuring Anaconda and Pytorch. For the installation process of this machine, see this article WIndows10 system installation Anaconda, Pycharm and Pytorch environment (NVIDIA GPU version)
error
solution steps:

  1. Click on the folder icon
    Step 1
  2. Because it is Conda executable, we have to choose Conda.exe but not the Python interpreter, so we have to choose the _Conda.exe in the Anaconda root directory ( note: there is an underscore in the file name ). One thing to note is that in the Script directory, there is also a Conda.exe, click on that exe, my computer loads very slowly ( note: choose _conda.exe in the root directory, do not choose the one in the script directory ). ( Why, old buddies who understand can give pointers ) After the selection is completed, finally click Load Environments on the right
    insert image description here
  3. Next, because we have created a virtual environment in Anaconda, click Use existing environment, select the virtual environment in the installed Anaconda, and click OK in the lower right corner.
    select environment
  4. Return to the create project page, click Create
    Create Project
  5. Enter the environment successfully
    success
    At this point, you can look at the lower right corner of PyCharm, and the name of the virtual environment will be displayed. If it is successfully displayed, the environment is added successfully.
    If you solve the problem, please vote and like it, and make progress together with everyone.

Feedback:
1: Many students commented that _conda.exe could not be found.

_conda.exe is the following application:
_conda.exe
If you can’t find _conda.exe, you can try to install an old version of pycharm or anaconda to see if it works? Or retrieve the absolute path of _conda.exe and copy the path directly?

2. Unrecognized in the Previously configured interpreter

Check whether python is installed in the virtual environment to be added. If python is not installed in the environment, it will not be recognized. That is to say, only create a virtual environment, and pycharm should not be able to recognize it.

3. Some students in the comments said that if you add Anaconda Scripts to the environment variable Path, you can use conda.exe in Scripts



Category of website: technical article > Blog

Author:cindy

link:http://www.pythonblackhole.com/blog/article/25300/f26046e24d881cd13c8f/

source:python black hole net

Please indicate the source for any form of reprinting. If any infringement is discovered, it will be held legally responsible.

10 0
collect article
collected

Comment content: (supports up to 255 characters)