How to install anaconda ubuntu
How to install anaconda ubuntu
How To Install Anaconda on Ubuntu 18.04 [Quickstart]
Introduction
Designed for data science and machine learning workflows, Anaconda is an open-source package manager, environment manager, and distribution of the Python and R programming languages.
This tutorial will guide you through installing Anaconda on an Ubuntu 18.04 server. For a more detailed version of this tutorial, with better explanations of each step, please refer to How To Install the Anaconda Python Distribution on Ubuntu 18.04.
Step 1 — Retrieving the Latest Version of Anaconda
From a web browser, go to the Anaconda Distribution page, available via the following link:
Find the latest Linux version and copy the link to the installer bash script.
Step 2 — Downloading the Anaconda Bash Script
Logged into your Ubuntu 18.04 server as a sudo non-root user, move into the /tmp directory and use curl to download the link you copied from the Anaconda website:
Step 3 — Running the Anaconda Script
You’ll receive the following output to review the license agreement by pressing ENTER until you reach the end.
When you get to the end of the license, type yes then press ENTER as long as you agree to the license to complete installation.
Step 4 — Completing the Installation Process
Once you agree to the license, you will be prompted to choose the location of the installation. You can press ENTER to accept the default location, or specify a different location.
At this point, the installation will proceed. Note that the installation process takes some time.
Step 5 — Selecting Options
Once installation is complete, you’ll receive the following output:
It is recommended that you type yes to use the conda command.
Step 6 — Activating Installation
You can now activate the installation with the following command:
Step 7 — Testing Installation
Use the conda command to test the installation and activation:
You’ll receive output of all the packages you have available through the Anaconda installation.
Step 8 — Setting Up Anaconda Environments
You can create Anaconda environments with the conda create command. For example, a Python 3 environment named my_env can be created with the following command:
Activate the new environment like so:
Your command prompt prefix will change to reflect that you are in an active Anaconda environment, and you are now ready to begin work on a project.
Related Tutorials
Here are links to more detailed tutorials that are related to this guide:
Want to learn more? Join the DigitalOcean Community!
Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in our Questions & Answers section, find tutorials and tools that will help you grow as a developer and scale your project or business, and subscribe to topics of interest.
Установка Anaconda в Ubuntu
В этой статье мы рассмотрим, как скачать и установить Anaconda Python Ubuntu 18.04 с официального сайта программы, а также как подготовить эту платформу к работе.
Установка Anacoda в Ubuntu
1. Скачивание и установка программы
Вы можете скачать программу прямо в браузере или скопировать ссылку для загрузки через wget. Например, для текущей версии команда будет выглядеть так:
Поскольку это достаточно большой файл, после завершения загрузки желательно проверить его по контрольной суме. Найти контрольную сумму загруженного файла можно командой:
Затем её нужно сравнить с сумой, указанной на этой странице для вашей версии программы. Если полученные значения совпадают, значит всё правильно.
Далее запустите полученный скрипт:
На первом шаге установки нажмите Enter, затем наберите yes, чтобы принять лицензионное соглашение:
Далее нужно выбрать папку, куда будет установлена программа:
Затем пойдёт установка Anaconda 3 Ubuntu. Процесс установки займёт некоторое время.
В конце установки программа предложит изменить
/.bashrc таким образом, чтобы Сonda запускалась автоматически при запуске терминала. Если вы не сделали это во время установки, то это можно выполнить потом командой:
conda init bash
Затем выполните следующую команду, чтобы система перечитала настройки:
Теперь вы можете проверить, всё ли работает, выполнив такую команду:
На этом установка Anaconda Ubuntu завершена.
2. Обновление Anaconda
Обновление Anaconda тоже достаточно просто выполнить. Сначала нужно обновить инструмент conda. Для этого выполните:
conda update conda
На вопросы программы отвечайте y. Когда обновление завершится, можно обновить саму Anaconda 3:
conda update anaconda
Аналогично предыдущему пункту, нажмите y, чтобы продолжить обновление.
3. Окружения Conda
Для активации окружения используется команда activate. Например, сделаем активным окружение base:
conda activate base
Также вы можете создать новое окружение с другой версией Python. Например, сделаем окружение с Python 3.5:
Программа создаст окружение и сообщит, какие пакеты ей надо установить, соглашаемся на установку:
Затем активируем нужное окружение:
conda activate ptn35env
Чтобы деактивировать текущее окружение, используйте команду deactivate:
Чтобы удалить окружение ptn35env, нужно использовать не команду uninstall, а remove:
4. Установка пакетов Conda
Посмотреть список установленных пакетов можно командой list:
comda search pip
А для установки пакета используйте install. Например, установим tensorflow:
conda install tensorflow
Удалить пакет можно командой remove:
conda remove tensorflow
Удаление Anaconda
Чтобы удалить Anaconda из своей системы, достаточно выполнить следующие команды:
/.bashrc и удалите оттуда строки, добавленные Anaconda, обычно, находятся между тегами conda initialize:
Затем удалите скрытые папки с дополнительными файлами и конфигурацией платформы:
Выводы
Теперь установка Anaconda в Ubuntu завершена. Вы можете начать пользоваться пакетным менеджером Conda, использовать виртуальные окружения в Python и легко устанавливать пакеты. Мы разобрали только основы использования conda, чтобы изучить программу лучше, читайте официальную документацию.
How to Install Anaconda on Ubuntu 18.04 and 20.04
Home » SysAdmin » How to Install Anaconda on Ubuntu 18.04 and 20.04
Anaconda is a package manager used in scientific computing and data science. It’s designed to provide scientific libraries and dependencies in the Python programming language. Anaconda is commonly used for machine learning and artificial intelligence applications.
This step by step guide will show you how to install Anaconda on an Ubuntu 18.04 or Ubuntu 20.04 system.
Note: This guide is also available for CentOS 7 or CentOS 8.
Steps For Installing Anaconda
Our tutorial on installing Anaconda on Ubuntu 18.04 or Ubuntu 20.04 includes downloading the latest version, verifying data integrity of the installer, and running the bash install script.
Step 1: Update Local Package Manager
Start by updating the local package manager. Open a terminal window and enter the following:
If your system doesn’t have curl, install it by entering:
Step 2: Download the Latest Version of Anaconda
At the time this article was written, the latest version of Anaconda is 2020.02. Check the developer’s download page to view the newest version.
Note the URL and use it to download the correct version.
Switch to the /tmp directory and use curl to download the installer using your command terminal:
This version is designed for Python 3.7. If you are using Python 2.7, use the appropriate URL.
Step 3: Verify the Download Checksum
Checksum is a security tool used to verify the authenticity and integrity of a downloaded script.
Enter the following:
Your system will display a series of letters and numbers:
Compare those to the appropriate checksum (or hash) in the Anaconda documentation. If you have chosen a different version, make sure to check the documentation for that version’s checksum.
Step 4: Run Anaconda Installation Script
The Anaconda installer is a bash script. To run the installation script, use the command:
A license agreement will appear. Use the Enter key to review the agreement.
At the bottom, type yes to agree to the terms.
The installer will prompt you to accept the default location, or install to a different location. Use the default path unless you have a specific need to change it. (You may cancel the installation here if needed.)
The installation will finish. After sucessful installation, the following will appear:
This determines if you want to use the conda command without changing the directory. Type yes and hit enter, unless you have a specific need to do otherwise. The system will respond as follows:
(Optional) Step 5: Install VSCode Editor
The system will ask if you want to install Microsoft Visual Studio Code Editor. It will display the following:
Decide by typing yes or no to continue.
Step 6: Activate and Test Installation
Once finished, activate the installation by entering:
Use the conda command to test the installation:
The system should display a list of data similar to:
How to Update Anaconda on Ubuntu
To update Anaconda on Ubuntu, start by updating the conda utility:
Next, run the Anaconda package update command:
Create and Activate Anaconda Environments
Create a Python 3 environment named test_environment by entering the following:
Activate this environment:
The command prompt will change. This indicates that you are now in a shell environment using Python 3. You can now work in this environment.
You now have a working Anaconda installation on your Ubuntu System for use within your Python environment.
Get started with scientific computing, data processing, and predictive analytics with over 1,500 open source packages available from its repository.
You can also install Python independently by following our step by step guide on installing Python 3.7 on Ubuntu 18.04.
How To Install the Anaconda Python Distribution on Ubuntu 20.04 [Quickstart]
Introduction
Anaconda is an open-source package manager, environment manager, and distribution of the Python and R programming languages.
This tutorial will guide you through installing the Python 3 version of Anaconda on an Ubuntu 20.04 server. For a more detailed version of this tutorial, with more thorough explanations of each step, please refer to How To Install the Anaconda Python Distribution on Ubuntu 20.04.
Step 1 — Retrieving the Latest Version of Anaconda
From a web browser, find the latest version of Anaconda for Python 3 at the Anaconda Downloads page:
At the time of writing, the latest version is 2020.02, but you should use a later stable version if it is available.
Step 2 — Downloading the Anaconda Bash Script
Change to the /tmp directory on your Ubuntu 20.04 server as a sudo non-root user.
Use curl to download the link that you copied from the Anaconda website. We’ll output this to a file called anaconda.sh for quicker use.
Step 3 — Verifying the Data Integrity of the Installer
You should check the output against the hashes available at the Anaconda with Python 3 on 64-bit Linux page for your appropriate Anaconda version.
Step 4 — Running the Anaconda Script
You’ll receive the following output to review the license agreement by pressing ENTER until you reach the end.
When you get to the end of the license, type yes as long as you agree to the license to complete installation.
Step 5 — Completing the Installation Process
Choose the location of your installation or press ENTER to accept the default location.
At this point, the installation process will continue. Note that it may take some time.
Step 6 — Selecting Options
Once installation is complete, you’ll receive the following output:
Type yes so that you can initialize Anaconda3. You’ll receive some output that states changes made in various directories along with a thank you for installing Anaconda.
Step 7 — Activating the Installation
You can now activate the installation by sourcing the
Once you have done that, you’ll be placed into the default base programming environment.
Step 8 — Testing the Installation
Use the conda command to test the installation and activation:
You’ll receive output of all the packages you have available through the Anaconda installation:
Step 9 — Setting Up Anaconda Environments
It’s best practice to create new environments for each of your projects. To create a Python 3 environment called my_env the syntax is as follows:
Press y to verify setup.
You can activate your new environment by typing the following:
With your environment activated, your command prompt prefix will reflect that you are no longer in the base environment, but in the new one that you just created.
When you’re ready to deactivate your Anaconda environment, you can do so by typing:
Related Tutorials
Here are links to more detailed tutorials that are related to this guide:
Want to learn more? Join the DigitalOcean Community!
Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in our Questions & Answers section, find tutorials and tools that will help you grow as a developer and scale your project or business, and subscribe to topics of interest.
How to install Anaconda on Ubuntu?
How to install Anaconda for Python on Ubuntu?
I only have command line access to my server. How do I install Anaconda on Ubuntu 14.04 from the command line?
11 Answers 11
You can use wget to download from commandline:
32 bits version:
64 bits version
And after download is finished do:
For users using Python2, the «3» directly after Anaconda should be changed to a 2.
See Anaconda Hompepage for more detail!
Installation Instructions [Linux Install]
These instructions explain how to install Anaconda on a Linux system.
After downloading the Anaconda installer, run the following command from a terminal:
After accepting the license terms, you will be asked to specify the install location (which defaults to
Note: You do NOT need root privileges to install Anaconda, if you select a user writable install location, such as
/anaconda.* After the self extraction is finished, you should add the anaconda binary directory to your PATH environment variable.
As all of Anaconda is contained in a single directory, uninstalling Anaconda is easy (you simply remove the entire install location directory).
If you encounter any issues, please try disabling your antivirus software. Linux/OS X Uninstall
As all of Anaconda is contained in a single directory, uninstalling Anaconda is simple (you simply remove the entire install location directory):
Nobody has explained here why apt-get and other package managers don’t have packages for anaconda.
An important reason for this is that anaconda is meant to be usable by a user who, for whatever reason, doesn’t have root privileges. In that case the user just installs into
Package managers always require sysadmin privileges.
If you are trying to it entirely in command line you use a bash script python 2 anaconda install bash script:
In addition to @Vivek’s answer, to get the latest python3 64-bit Linux version:
The grep filters in line 3 can be altered to match your requirements, of course.
Источники информации:
- http://losst.ru/ustanovka-anaconda-v-ubuntu
- http://phoenixnap.com/kb/how-to-install-anaconda-ubuntu-18-04-or-20-04
- http://www.digitalocean.com/community/tutorials/how-to-install-the-anaconda-python-distribution-on-ubuntu-20-04-quickstart
- http://askubuntu.com/questions/505919/how-to-install-anaconda-on-ubuntu