Header Ads Widget

Atomistic Simulation Using Python Interfaces

Last Posts

10/recent/ticker-posts

How to install the package manager conda

 


To install the library we need to install the anaconda which includes conda package manager, python3.9 version and Jupyter Notebook used for scientific computing and data science.

 

* Download Anaconda installer for Linux.

 * Verify your installer hashes 

sha256sum Anaconda3-2021.11-Linux-x86_64.sh

* .Run 

/abinitio> chmod +x Anaconda3-2021.11-Linux-x86_64.sh
/abinitio> ./Anaconda3-2021.11-Linux-x86_64.sh

accept the default choices

We get the following

==> For changes to take effect, close and re-open your current shell. <==

If you'd prefer that conda's base environment not be activated on startup,
set the auto_activate_base parameter to false:

conda config --set auto_activate_base false

Thank you for installing Anaconda3!

===========================================================================

Working with Python and Jupyter notebooks is a breeze with PyCharm Pro,
designed to be used with Anaconda. Download now and have the best data
tools at your fingertips.

PyCharm Pro for Anaconda is available at: https://www.anaconda.com/pycharm


* Source the ~/.bashrc file

source ~/.bashrc

 

How to avoid conda to activate base environment?

By default conda init will add to your .bashrc file for the base environment, which will slow down your terminal.

You can remove them in your .bashrc file or answer no to that question in the last step of your anaconda installation.

And then add the following to your .bashrc file. If you changed the default installation directory, change ~/anaconda3/ to that directory.

source ~/anaconda3/etc/profile.d/conda.sh
if [[ -z ${CONDA_PREFIX+x} ]]; then
    export PATH="~/conda/bin:$PATH"
fi

To test it, open a new terminal tab or run source .bashrc. Run conda activate base, then you should see (base) in front of your Bash prompt.

Now you can create another environment and activate it using Anaconda. If you frequently use one environment, you can also add conda activate [env] to your .bashrc file.

 

NB: You can install miniconda packae which is  a minimal free Conda installer. It’s a thin, bootstrap version that contains just conda, Python, the packages they depend on, and a limited range of other helpful modules like pip, zlib, and a few others. 


Installing the  ASE

 Update conda

vasp-ase-tutorials> conda update -n base -c defaults conda


Collecting package metadata (current_repodata.json): done
Solving environment: done

## Package Plan ##

  environment location: /home/algerien1970/anaconda3

  added / updated specs:
    - conda


The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    conda-4.13.0               |   py39h06a4308_0         895 KB
    conda-pack-0.7.0           |     pyh6c4a22f_0          30 KB  conda-forge
    conda-package-handling-1.8.1|   py39h7f8727e_0         889 KB
    pyjwt-2.4.0                |   py39h06a4308_0          34 KB
    xmltodict-0.13.0           |     pyhd8ed1ab_0          13 KB  conda-forge
    ------------------------------------------------------------
                                           Total:         1.8 MB

The following packages will be UPDATED:

  conda                               4.10.3-py39h06a4308_0 --> 4.13.0-py39h06a4308_0
  conda-pack         pkgs/main::conda-pack-0.6.0-pyhd3eb1b~ --> conda-forge::conda-pack-0.7.0-pyh6c4a22f_0
  conda-package-han~                   1.7.3-py39h27cfd23_1 --> 1.8.1-py39h7f8727e_0
  pyjwt                                2.1.0-py39h06a4308_0 --> 2.4.0-py39h06a4308_0
  xmltodict          pkgs/main::xmltodict-0.12.0-pyhd3eb1b~ --> conda-forge::xmltodict-0.13.0-pyhd8ed1ab_0


Proceed ([y]/n)? y


Downloading and Extracting Packages
conda-package-handli | 889 KB    | #################################################################################################################################################### | 100%
conda-4.13.0         | 895 KB    | #################################################################################################################################################### | 100%
xmltodict-0.13.0     | 13 KB     | #################################################################################################################################################### | 100%
pyjwt-2.4.0          | 34 KB     | #################################################################################################################################################### | 100%
conda-pack-0.7.0     | 30 KB     | #################################################################################################################################################### | 100%
Preparing transaction: done
Verifying transaction: done
Executing transaction: done

Post a Comment

0 Comments