" command to install the library. To install a specific version, specify the version number: "pip install Home >Backend Development >Python Tutorial >How to download third-party libraries in python To use pip to install Python third-party libraries, please perform the following steps: If pip is not installed, please use the "python3 -m ensurepip --upgrade" command to install it. Use the "pip install Normally, pip has been automatically installed during Python installation. If pip is not installed, please use the following command: Use pip to install third-party libraries, Just enter the following command at the command line: To install a specific version of the library, Specify the version number in the command: For example, to install version 1.22.0 of NumPy: To install the local library, use For example, to install the To uninstall the library, Please use the For example, to uninstall NumPy: In addition to pip, there are other libraries Installation method, for example: Please note that it is recommended to use pip as the main tool for installing Python third-party libraries. The above is the detailed content of How to download third-party libraries in python. For more information, please follow other related articles on the PHP Chinese website!How to download third-party libraries in python
Install Python third-party libraries using pip
Install pip
<code>python3 -m ensurepip --upgrade</code>
Use pip to install third-party libraries
<code>pip install <库名称></p>
<p>For example, to install the NumPy library: </p>
<pre class="brush:php;toolbar:false"><code>pip install numpy</code>
Install a specific version of the library
<code>pip install <库名称>==<版本号></code>
<code>pip install numpy==1.22.0</code>
Install the local library
-e
Options: <code>pip install -e <库路径></code>
my_library
library in the current directory: <code>pip install -e ./my_library</code>
Uninstall the library
uninstall
command: <code>pip uninstall <库名称></code>
<code>pip uninstall numpy</code>
Other installation methods