Anaconda managing multiple Python versions

Source: Internet
Author: User
Tags jupyter jupyter notebook

1. Installing Anaconda

: Tsinghua Mirror Station
For your operating system, select the appropriate version in the application software->conda, download link . The installation method is relatively simple and is not described in detail.
The Windows System installation process needs to be noted, tick the Add software to the Windows path (can also be added manually, that is, in the environment variable path will be added to the Conda.exe file path), so that the cmd command can run the Conda command.

2.conda list (view the packages already installed in the current environment)

After installation, by <conda list> looking at the packages already installed in Conda, the name __ and __ versions of __ are displayed.

3.conda Creating an isolated python environment

There are two ways of doing this:

conda create -name env package-name(创建环境)在程序开始菜单中打开anaconda Navigator,通过GUI界面创建新的环境
4.conda env List

View a list of currently established environments (or you can view the list of environments directly in the GUI interface of Navigator)

5.activate env_name (activating environment)

Using this command, you can activate the Create environment

6. View the built-in dependent libraries in an active environment and add (install) the required libraries
    • <conda list> (view installed libraries)
    • Conda Install packagename (Install a library)
    • For example, install Pyreadl INE (a jupyter-based Python code auto-complete library, recommended)
      <conda install pyreadline>

      7. Export an environment for sharing
    • for users using Anaconda to export the configuration in the current environment (the installation of the library) to the YAML format (it is recommended to provide this file when you share a Python project. Allows the companion to use the next command can be configured in the current environment)
      <conda env export > env_name.yaml>
    • Configure the current environment with an external import
      <conda env update-f=path/env_name.yaml>

      for users who do not use anaconda

      <pip Freeze > Env_name.txt>
      <+pip install-r path/env_name.txt>

      8.conda env Remove- Name Env_name (delete environment) 9. Highly Recommended package
    • Jupyter Notebook Click to view Jupyter notebook introduction
      <conda Install Jupyter Notebook>
    • Auto-correlate Environment dependency package (based on jupyter notebook )
      <conda install nb_conda>
    • Code Auto-complete package (based on jupyter notebook )
      < Conda install pyreadline>
      Reference: More

Anaconda managing multiple Python versions

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.