Install python though anaconda on ubuntu20.04

after I installed anaconda, the version of python should be like “Python 3.6.5 :: Anaconda, Inc”.
although I changed the ~/.bashrc, it still does not show anaconda.
was my installation wrong?

The first things I’d check:

  • Do you have conda on your path? Does conda --version work? If not, you might need to restart your shell, or maybe something went wrong with the installation
  • Has the base conda environment been activated? Typically this shows up as a modification like (base) in the shell prompt (but this depends on your shell config). If conda is working you can activate the base environment with conda activate
  • If conda installed fine and you’re in the base environment: was Python installed there? Try conda list and which python to check.

Hello there… ummh so how is your anaconda PATH can you confirm? echo "$PATH"

coonda --version work and the conda environment has been activated.
python version in conda list is the same as which python shows

my anaconda path is home/myname/anacnda3

What path does which python return? It should say something like /home/[myname]/anaconda3/bin/python.

yes . it is /home/myname/anaconda3/bin/python

I’m confused. What happens when you run python and what did you expect?

Hey… so if the environment has been activated correctly then I think you good just as @jamestwebber has stated what was your expectation?.. can you run conda commands? I thought at first you couldn’t run conda commands… paste your conda info

i would like to use it for deep-learning, so i wonder if it will influence. for now, i have not run any codes yet.

active environment : base
    active env location : /home/myname/anaconda3
            shell level : 1
       user config file : /home/myname/.condarc
 populated config files : /home/myname/.condarc
          conda version : 23.9.0
    conda-build version : 3.27.0
         python version : 3.11.5.final.0
       virtual packages : __archspec=1=x86_64
                          __cuda=12.2=0
                          __glibc=2.31=0
                          __linux=5.15.0=0
                          __unix=0=0
       base environment : /home/myname/anaconda3  (writable)
      conda av data dir : /home/myname/anaconda3/etc/conda
  conda av metadata url : None
           channel URLs : https://repo.anaconda.com/pkgs/main/linux-64
                          https://repo.anaconda.com/pkgs/main/noarch
                          https://repo.anaconda.com/pkgs/r/linux-64
                          https://repo.anaconda.com/pkgs/r/noarch
          package cache : /home/myname/anaconda3/pkgs
                          /home/myname/.conda/pkgs
       envs directories : /home/myname/anaconda3/envs
                          /home/myname/.conda/envs
               platform : linux-64
             user-agent : conda/23.9.0 requests/2.31.0 CPython/3.11.5 Linux/5.15.0-86-generic ubuntu/20.04.6 glibc/2.31 aau/0.4.3 c/2cEHeZhCOSIj5d2_qFWJNQ s/PZ31ttrwkDWqbfzQjX2bOQ e/uVs5aGY_4uEIqMchAZa0yw
                UID:GID : 1000:1000
             netrc file : None
           offline mode : False

It looks like everything is fine. You are using Python 3.11 which is the nearly-latest version (3.12 just came out this month). If you were expecting 3.6, that’s probably just because whatever guide you’re reading is from back then.

okay, thanks a lot!