In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-31 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/02 Report--
This article introduces you how to modify environmental variables in Python, the content is very detailed, interested friends can refer to, hope to be helpful to you.
Create a virtual environment manually
After the software is installed, under the start menu, locate the Anaconda3 (64-bit) folder and click Anaconda Navigator.
When you open it, it looks like this: create a Python3.6 virtual environment:
Is creating, this will take some time Python version 3.6.8 virtual environment to create the open command line, found that the system default version of Python is not Python3.6.8, but Anaconda default Python3.7.X, this is because the creation of the installation of Anaconda checked the option to add Anaconda to the environment variable, it also takes the default Python version of Anaconda as the system default version, modify the environment variable. Right-click on my computer-- > Properties-- > Advanced system Settings-- > Environment variables-double-click the PATH environment variable. The path to the Python3.6 virtual environment we created is: C:\ ProgramData\ Anaconda3\ envs\ py36 found that there are five Anaconda-related variables in the system environment variables, which are automatically added by the program after the add to environment variable option is checked when Anaconda is installed. We just need to add the path to the virtual environment and overwrite it in front of the Anaconda environment variable. Command line to create a Python environment
Conda operating virtual environment
# View the virtual environment conda env list# to create an environment named py36, specify the version as 3.6conda create-n py36 python=3.6 activation environment # activate the activate py36 exit environment using activate in the windows environment # use deactivatedeactivate in the windows environment
# Delete virtual environment conda remove-n py36-all
# View the list of existing environments conda info-e command line switch virtual environment source activate python3.6activate python3.6conda activate python3.6 command line close virtual environment source deactivate python3.6deactivate python3.6conda deactivate command line install Python package # install numpypip install numpy# install matplotlibpip install matplotlib# install pandaspip install pandas# install sklearnpip install scikit-learn# install tensorflow and specify the version to install requestspip install requests# for 1.6.0pip install tensorflow==1.6.0# Install ini profile parsing pip install configparser# install mysql driver pip install pymysq# install dbutils database connection pool anaconda search-t conda dbutils
On how to modify the environment variables in Python to share here, I hope that the above content can be of some help to you, can learn more knowledge. If you think the article is good, you can share it for more people to see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.