conda changes the virtual environment name

#Due to the conflict between the original environment name and the new environment name (yolov5 was originally used, and the environment name was pytorch. Later, a new yolov8 environment was built, which always felt weird)#

I checked many blogs and found that there seems to be no way to directly change the environment name. It is more about backing up the original environment to create a new environment, and then deleting the original environment to achieve the effect of changing the environment name. (It’s also possible that you didn’t check carefully enough. If you have any other ideas, you can write them down in the comment area)

First activate the environment, back up the environment, and change the backup environment to the name you want to change.

conda activate PyTorch

conda create --name yolov5 --clone PyTorch

These two environment names are my own. If you use them, change them to your own names.

A message similar to this appears to prove success. Wait for a moment and wait for backup.

Then delete the original environment

conda env remove --name PyTorch

 It’s done now

 Finally check, check the environment name to see if it is successful

conda env list

If you find it useful, please give it a like, thank you friends

Guess you like

Origin blog.csdn.net/weixin_74258524/article/details/134652900