When installing packages on an Ubuntu server, you often use sudo apt-get install package name or sudo pip install package name. What is the difference between the two? 1. Difference pip is used to install all Python dependency packages from PyPI (https://www.python.org/), and can choose to install any previous version of dependency packages uploaded on PyPI, which I personally think are Python-related packages and third-party packages and various versions; apt-get can be used to install software, update sources, and can also be used to update typical dependency packages from Ubuntu (https://launchpad.net/ubuntu). Typical installation means that it only installs a single version (the latest release, or the most recent one), and we cannot decide the version of the dependency package we want to install or choose a previous version. Personally, I think they are easy to distinguish: after all, one is updating the system-level package, and the other is updating a programming language-level package (library). 2. Installation and application apt-get can be used directly in the following format: $ sudo apt-get install/delete package $ sudo apt-get -f install #Repair installation$ sudo apt-get dist-upgrade #Upgrade system$ sudo apt-get upgrade #Update installed packages$ apt-get source package #Download the source code of the package$ sudo apt-get build-dep package #Install related compilation environment$ sudo apt-get clean && sudo apt-get autoclean #Clean up useless packages pip needs to be installed before it can be used. The installation process is as follows (applicable to Ubuntu 10.10 and above), using the format: pip install package. $ sudo apt-get install python-pip python-dev build-essential $ sudo pip install --upgrade pip Installing Python library under Linux sudo apt-get install python-numpy sudo apt-get install python-scipy sudo apt-get install python-matplotlib sudo apt-get install python-pip other pip list lists all libraries pip show torch View library information The above detailed explanation of the update commands for software (libraries) under Linux is all the content that the editor shares with you. I hope it can give you a reference. I also hope that you will support 123WORDPRESS.COM. You may also be interested in:
|
>>: Vue Element front-end application development: Use of API Store View in Vuex
This article introduces the CSS scrollbar selecto...
After clicking the a tag in the page, you want to ...
The following two errors were encountered when co...
One day I found that the execution speed of a SQL...
Use CSS3 to animate the input box similar to the ...
Table of contents 1. Introduction to pid-file 2.S...
Code implementation: Copy code The code is as fol...
As a newbie who has just come into contact with t...
Table of contents 1. Scope 2. Scope Chain 3. Lexi...
Table of contents Preface text 1. Panel 2. Huaron...
Problem Description In the framework of Ele.me UI...
Table of contents Preface environment Install Cre...
Table of contents Preface Parsing parameters Modi...
As shown below: XML/HTML CodeCopy content to clip...
This article uses examples to illustrate the usag...