Various methods for Anaconda to install python third-party libraries

Various methods for Anaconda to install python third-party libraries (updated offline installation)

The previous article talked about some introduction and installation of anaconda, and third-party sources were also introduced. This article introduces various methods of Anaconda to install the third python library

The first:

1. Double-click to open Anaconda Navigator, select the Environments interface

2. Then select Not install , search for the desired library package name in the search box on the right , select the desired library package, and select apply to install

the second

1. Double-click to open Anaconda Prompt (Anaconda 3) (you can see it when you open the system menu and find anaconda), enter pip install (xxx), and the name of the third-party package to be installed is in brackets. Press Enter to complete the installation. (This is a command install)

The third (a method I often use)

1. Double-click to open Anaconda Prompt (Anaconda 3) (you can see it when you open the system menu and find anaconda), enter conda install (xxx) , and the name of the third-party package to be installed is in brackets. Press Enter to complete the installation. (This is a command installation) **Other:** You can also execute pip install xxx or conda

install xxx in the window after opening the python editor (Anaconda is spyder) . to install

-------------------------------------------------- -------Dividing line----------------------------------------- ---------
Update an offline installation method here, 100% can be installed successfully! ! !
1. First, we need to download the required installation package from a library package source website, for example: https://www.lfd.uci.edu/~gohlke/pythonlibs/
2. I am here because I have been unable to install the opencv library package, so I chose the opencv library package

3. After downloading, I went to the corresponding download folder. Here I am the path of the library package directly in anaconda (the path is arbitrary, it is best not to appear in Chinese)

4. Then open the anaconda powershell promat ( anaconda3), go to the path you just downloaded, and do
pip install .\opencv_python-4.4.0-cp37-cp37m-win_amd64.whlInstallation


5. The installation is successful, go back to test (the test method is optional) I went to spyder to test, the test code is as follows

import cv2
 print ( cv2 . __file__ ) # print the path where
 it is located
  • 1
  • 2

Test Results

Related: Various methods for Anaconda to install python third-party libraries