How to install conda linux

InstallationВ¶

The fastest way to obtain conda is to install Miniconda , a mini version of Anaconda that includes only conda and its dependencies. If you prefer to have conda plus over 7,500 open-source packages, install Anaconda.

We recommend you install Anaconda for the local user, which does not require administrator permissions and is the most robust type of installation. You can also install Anaconda system wide, which does require administrator permissions.

For information on using our graphical installers for Windows or macOS, see the instructions for installing Anaconda.

System requirementsВ¶

32- or 64-bit computer.

For Miniconda—400 MB disk space.

For Anaconda—Minimum 3 GB disk space to download and install.

Windows, macOS, or Linux.

For Windows: Windows 8.1 or newer for Python 3.9, or Windows Vista or newer for Python 3.8.

You do not need administrative or root permissions to install Anaconda if you select a user-writable install location.

Regular installationВ¶

Follow the instructions for your operating system:

Installing in silent modeВ¶

You can use silent installation of Miniconda or Anaconda for deployment or testing or building services such as Travis CI and AppVeyor.

Follow the silent-mode instructions for your operating system:

Installing conda on a system that has other Python installations or packagesВ¶

You do not need to uninstall other Python installations or packages in order to use conda. Even if you already have a system Python, another Python installation from a source such as the macOS Homebrew package manager and globally installed packages from pip such as pandas and NumPy, you do not need to uninstall, remove, or change any of them before using conda.

Install Anaconda or Miniconda normally, and let the installer add the conda installation of Python to your PATH environment variable. There is no need to set the PYTHONPATH environment variable.

To see if the conda installation of Python is in your PATH variable:

On Windows, open an Anaconda Prompt and run— echo %PATH% .

On macOS and Linux, open the terminal and run— echo $PATH .

To see which Python installation is currently set as the default:

On Windows, open an Anaconda Prompt and run— where python .

On macOS and Linux, open the terminal and run— which python .

To see which packages are installed in your current conda environment and their version numbers, in your terminal window or an Anaconda Prompt, run conda list .

© Copyright 2017, Anaconda, Inc Revision c1579681 .

Источник

InstallationВ¶

The fastest way to obtain conda is to install Miniconda , a mini version of Anaconda that includes only conda and its dependencies. If you prefer to have conda plus over 7,500 open-source packages, install Anaconda.

We recommend you install Anaconda for the local user, which does not require administrator permissions and is the most robust type of installation. You can also install Anaconda system wide, which does require administrator permissions.

For information on using our graphical installers for Windows or macOS, see the instructions for installing Anaconda.

System requirementsВ¶

32- or 64-bit computer.

For Miniconda—400 MB disk space.

For Anaconda—Minimum 3 GB disk space to download and install.

Windows, macOS, or Linux.

For Windows: Windows 8.1 or newer for Python 3.9, or Windows Vista or newer for Python 3.8.

You do not need administrative or root permissions to install Anaconda if you select a user-writable install location.

Regular installationВ¶

Follow the instructions for your operating system:

Installing in silent modeВ¶

You can use silent installation of Miniconda or Anaconda for deployment or testing or building services such as Travis CI and AppVeyor.

Follow the silent-mode instructions for your operating system:

Installing conda on a system that has other Python installations or packagesВ¶

You do not need to uninstall other Python installations or packages in order to use conda. Even if you already have a system Python, another Python installation from a source such as the macOS Homebrew package manager and globally installed packages from pip such as pandas and NumPy, you do not need to uninstall, remove, or change any of them before using conda.

Читайте также:  Pycharm ��� linux mint

Install Anaconda or Miniconda normally, and let the installer add the conda installation of Python to your PATH environment variable. There is no need to set the PYTHONPATH environment variable.

To see if the conda installation of Python is in your PATH variable:

On Windows, open an Anaconda Prompt and run— echo %PATH% .

On macOS and Linux, open the terminal and run— echo $PATH .

To see which Python installation is currently set as the default:

On Windows, open an Anaconda Prompt and run— where python .

On macOS and Linux, open the terminal and run— which python .

To see which packages are installed in your current conda environment and their version numbers, in your terminal window or an Anaconda Prompt, run conda list .

© Copyright 2017, Anaconda, Inc Revision c1579681 .

Источник

InstallationВ¶

The fastest way to obtain conda is to install Miniconda , a mini version of Anaconda that includes only conda and its dependencies. If you prefer to have conda plus over 7,500 open-source packages, install Anaconda.

We recommend you install Anaconda for the local user, which does not require administrator permissions and is the most robust type of installation. You can also install Anaconda system wide, which does require administrator permissions.

For information on using our graphical installers for Windows or macOS, see the instructions for installing Anaconda.

System requirementsВ¶

32- or 64-bit computer.

For Miniconda—400 MB disk space.

For Anaconda—Minimum 3 GB disk space to download and install.

Windows, macOS, or Linux.

For Windows: Windows 8.1 or newer for Python 3.9, or Windows Vista or newer for Python 3.8.

You do not need administrative or root permissions to install Anaconda if you select a user-writable install location.

Regular installationВ¶

Follow the instructions for your operating system:

Installing in silent modeВ¶

You can use silent installation of Miniconda or Anaconda for deployment or testing or building services such as Travis CI and AppVeyor.

Follow the silent-mode instructions for your operating system:

Installing conda on a system that has other Python installations or packagesВ¶

You do not need to uninstall other Python installations or packages in order to use conda. Even if you already have a system Python, another Python installation from a source such as the macOS Homebrew package manager and globally installed packages from pip such as pandas and NumPy, you do not need to uninstall, remove, or change any of them before using conda.

Install Anaconda or Miniconda normally, and let the installer add the conda installation of Python to your PATH environment variable. There is no need to set the PYTHONPATH environment variable.

To see if the conda installation of Python is in your PATH variable:

On Windows, open an Anaconda Prompt and run— echo %PATH% .

On macOS and Linux, open the terminal and run— echo $PATH .

To see which Python installation is currently set as the default:

On Windows, open an Anaconda Prompt and run— where python .

On macOS and Linux, open the terminal and run— which python .

To see which packages are installed in your current conda environment and their version numbers, in your terminal window or an Anaconda Prompt, run conda list .

© Copyright 2017, Anaconda, Inc Revision c1579681 .

Источник

Установка Anaconda в Ubuntu

Anaconda — это очень популярный дистрибутив Python, который содержит удобный пакетный менеджер Conda, несколько предустановленных версий Python (2.7, 3.4 и 3.7), а также среду разработки IDLE Spider и множество библиотек, которые очень просто установить. Ещё здесь есть библиотеки для обработки Big Data, прогнозной аналитики и научных вычислений. Также можно всем управлять через графическую утилиту Anaconda Navigator.

В этой статье мы рассмотрим, как скачать и установить Anaconda Python Ubuntu 18.04 с официального сайта программы, а также как подготовить эту платформу к работе.

Установка Anacoda в Ubuntu

1. Скачивание и установка программы

Сначала нужно скачать установщик платформы с официального сайта. На момент написания статьи самая свежая версия программы — 2019.03. Нажмите кнопку Download, а затем выберите операционную систему Linux:

Читайте также:  Моноблок hp как поставить windows

Вы можете скачать программу прямо в браузере или скопировать ссылку для загрузки через 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

Как я уже сказал, Сonda — это пакетный менеджер, а также это менеджер окружений. Вы можете создать несколько окружений с разными версиями Python, а также с разными установленными в них библиотеками. Посмотреть список доступных окружений можно командой:

conda info —envs

Для активации окружения используется команда activate. Например, сделаем активным окружение base:

conda activate base

Также вы можете создать новое окружение с другой версией Python. Например, сделаем окружение с Python 3.5:

conda create —name ptn35env python=3.5

Программа создаст окружение и сообщит, какие пакеты ей надо установить, соглашаемся на установку:

Затем активируем нужное окружение:

conda activate ptn35env

Чтобы деактивировать текущее окружение, используйте команду deactivate:

Чтобы удалить окружение ptn35env, нужно использовать не команду uninstall, а remove:

conda remove —name ptn35env -all

4. Установка пакетов Conda

Посмотреть список установленных пакетов можно командой list:

Чтобы найти нужный пакет, используйте search, например, ищем пакетный менеджер Python — pip:

comda search pip

А для установки пакета используйте install. Например, установим tensorflow:

conda install tensorflow

Удалить пакет можно командой remove:

conda remove tensorflow

Удаление Anaconda

Чтобы удалить Anaconda из своей системы, достаточно выполнить следующие команды:

/.bashrc и удалите оттуда строки, добавленные Anaconda, обычно, находятся между тегами conda initialize:

Затем удалите скрытые папки с дополнительными файлами и конфигурацией платформы:

Выводы

Теперь установка Anaconda в Ubuntu завершена. Вы можете начать пользоваться пакетным менеджером Conda, использовать виртуальные окружения в Python и легко устанавливать пакеты. Мы разобрали только основы использования conda, чтобы изучить программу лучше, читайте официальную документацию.

Источник

Getting started with condaВ¶

Conda is a powerful package manager and environment manager that you use with command line commands at the Anaconda Prompt for Windows, or in a terminal window for macOS or Linux.

This 20-minute guide to getting started with conda lets you try out the major features of conda. You should understand how conda works when you finish this guide.

SEE ALSO: Getting started with Anaconda Navigator, a graphical user interface that lets you use conda in a web-like interface without having to enter manual commands. Compare the Getting started guides for each to see which program you prefer.

Before you startВ¶

You should have already installed Anaconda.

ContentsВ¶

Starting conda on Windows, macOS, or Linux. 2 MINUTES

Managing conda . Verify that Anaconda is installed and check that conda is updated to the current version. 3 MINUTES

Managing environments . Create environments and move easily between them. 5 MINUTES

Managing Python . Create an environment that has a different version of Python. 5 MINUTES

Managing packages . Find packages available for you to install. Install packages. 5 MINUTES

TOTAL TIME: 20 MINUTES

Starting condaВ¶

Windows

From the Start menu, search for and open «Anaconda Prompt.»

On Windows, all commands below are typed into the Anaconda Prompt window.

MacOS

Open Launchpad, then click the terminal icon.

On macOS, all commands below are typed into the terminal window.

Linux

Open a terminal window.

Читайте также:  Файловый менеджер для dos windows

On Linux, all commands below are typed into the terminal window.

Managing condaВ¶

Verify that conda is installed and running on your system by typing:

Conda displays the number of the version that you have installed. You do not need to navigate to the Anaconda directory.

EXAMPLE: conda 4.7.12

If you get an error message, make sure you closed and re-opened the terminal window after installing, or do it now. Then verify that you are logged into the same user account that you used to install Anaconda or Miniconda.

Update conda to the current version. Type the following:

Conda compares versions and then displays what is available to install.

If a newer version of conda is available, type y to update:

We recommend that you always keep conda updated to the latest version.

Managing environmentsВ¶

Conda allows you to create separate environments containing files, packages, and their dependencies that will not interact with other environments.

When you begin using conda, you already have a default environment named base . You don’t want to put programs into your base environment, though. Create separate environments to keep your programs isolated from each other.

Create a new environment and install a package in it.

We will name the environment snowflakes and install the package BioPython. At the Anaconda Prompt or in your terminal window, type the following:

Conda checks to see what additional packages («dependencies») BioPython will need, and asks if you want to proceed:

Type «y» and press Enter to proceed.

To use, or «activate» the new environment, type the following:

Windows: conda activate snowflakes

macOS and Linux: conda activate snowflakes

conda activate only works on conda 4.6 and later versions.

For conda versions prior to 4.6, type:

Windows: activate snowflakes

macOS and Linux: source activate snowflakes

Now that you are in your snowflakes environment, any conda commands you type will go to that environment until you deactivate it.

To see a list of all your environments, type:

A list of environments appears, similar to the following:

The active environment is the one with an asterisk (*).

Change your current environment back to the default (base): conda activate

For versions prior to conda 4.6, use:

macOS, Linux: source activate

When the environment is deactivated, its name is no longer shown in your prompt, and the asterisk (*) returns to base. To verify, you can repeat the conda info —envs command.

Managing PythonВ¶

When you create a new environment, conda installs the same Python version you used when you downloaded and installed Anaconda. If you want to use a different version of Python, for example Python 3.5, simply create a new environment and specify the version of Python that you want.

Create a new environment named «snakes» that contains Python 3.9:

When conda asks if you want to proceed, type «y» and press Enter.

Activate the new environment:

Windows: conda activate snakes

macOS and Linux: conda activate snakes

conda activate only works on conda 4.6 and later versions.

For conda versions prior to 4.6, type:

Windows: activate snakes

macOS and Linux: source activate snakes

Verify that the snakes environment has been added and is active:

Conda displays the list of all environments with an asterisk (*) after the name of the active environment:

The active environment is also displayed in front of your prompt in (parentheses) or [brackets] like this:

Verify which version of Python is in your current environment:

Deactivate the snakes environment and return to base environment: conda activate

For versions prior to conda 4.6, use:

macOS, Linux: source activate

Managing packagesВ¶

In this section, you check which packages you have installed, check which are available and look for a specific package and install it.

To find a package you have already installed, first activate the environment you want to search. Look above for the commands to activate your snakes environment .

Check to see if a package you have not installed named «beautifulsoup4» is available from the Anaconda repository (must be connected to the Internet):

Conda displays a list of all packages with that name on the Anaconda repository, so we know it is available.

Install this package into the current environment:

Check to see if the newly installed program is in this environment:

Источник

Оцените статью