- Notifications
You must be signed in to change notification settings - Fork1.8k
A system-level, binary package and environment manager running on all major operating systems and platforms.
License
conda/conda
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Conda is a cross-platform, language-agnostic binary package manager. It is apackage manager used in conda distributions likeMiniforgeand theAnaconda Distribution, but it may beused for other systems as well. Conda makes environments first-classcitizens, making it easy to create independent environments even for Clibraries. The conda command line interface is written entirely in Python,and is BSD licensed open source.
Conda is enhanced by organizations, tools, and repositories created and managed bythe amazing members of theconda community. Some of themcan be foundhere.
To bootstrap a minimal distribution, use a minimal installer such asMiniconda orMiniforge.
Conda is also included in theAnaconda Distribution.
To updateconda
to the newest version, use the following command:
$ conda update -n base conda
Tip
It is possible thatconda update
does not install the newest versionif the existingconda
version is far behind the current release.In this case, updating needs to be done in stages.
For example, to update fromconda 4.12
toconda 23.10.0
,conda 22.11.1
needs to be installed first:
$ conda install -n base conda=22.11.1$ conda update conda
If you install the Anaconda Distribution, you will already have hundreds of packagesinstalled. You can see what packages are installed by running:
$ conda list
to see all the packages that are available, use:
$ conda search
and to install a package, use
$ conda install<package-name>
The real power of conda comes from its ability to manage environments.In conda, an environment can be thought of as a completely separate installation.Conda installs packages into environments efficiently usinghard links by default when it is possible, soenvironments are space efficient, and take seconds to create.
The default environment, whichconda
itself is installed into, is calledbase
.To create another environment, use theconda create
command.For instance, to create an environment with PyTorch, you would run:
$ conda create --name ml-project pytorch
This creates an environment calledml-project
with the latest version of PyTorch, and its dependencies.
We can now activate this environment:
$ conda activate ml-project
This puts thebin
directory of theml-project
environment in the front of thePATH
,and sets it as the default environment for all subsequent conda commands.
To go back to the base environment, use:
$ conda deactivate
You can easily build your own packages for conda, and upload themtoanaconda.org, a free service for hostingpackages for conda, as well as other package managers.To build a package, create a recipe. Package building documentation is availablehere.SeeAnacondaRecipes for the recipes that make up the Anaconda Distribution anddefaults
channel.Conda-forge andBioconda are community-driven conda-based distributions.
To upload to anaconda.org, create an account. Then, install theanaconda-client and login:
$ conda install anaconda-client$ anaconda login
Then, after you build your recipe:
$ conda build<recipe-dir>
you will be prompted to upload to anaconda.org.
To add your anaconda.org channel, or other's channels, to conda sothatconda install
will find and install their packages, run:
$ conda config --add channels https://conda.anaconda.org/username
(replacingusername
with the username of the person whose channel you wantto add).
Contributions to conda are welcome. See thecontributing documentationfor instructions on setting up a development environment.
About
A system-level, binary package and environment manager running on all major operating systems and platforms.