Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
(/cluster/medbow/project/arcc/salexan5/conda/py_env) [salexan5@mblog1 conda]$ pwd
/project/arcc/salexan5/conda

(/cluster/medbow/project/arcc/salexan5/conda/py_env) [salexan5@mblog1 conda]$ ls py_env/lib/python3.12/site-packages/
numpy  numpy-2.0.0.dist-info  numpy.libs

Try Installing pandas into our Conda environment

...

Recommendation: Always set the PYTHONUSERBASE environment variable

Sessions/Environments can get confused if you have previously set environment variables and have forgotten what has/hasn’t been set within a session.

Note

Starting a new session, notice which version of numpy is being used by our conda environment before and after setting our PYTHONUSERBASE environment variable.

Code Block
[salexan5@mblog2 ~]$ module load miniconda3/24.3.0
[salexan5@mblog2 ~]$ conda activate /project/arcc/salexan5/conda/py_env
(/project/arcc/salexan5/conda/py_env) [salexan5@mblog2 ~]$ pip list -v
Package                 Version     Location                                                         Installer
----------------------- ----------- ---------------------------------------------------------------- ---------
...
numpy                   2.0.0       /home/salexan5/.local/lib/python3.12/site-packages               pip
...

(/project/arcc/salexan5/conda/py_env) [salexan5@mblog2 ~]$ export PYTHONUSERBASE=$CONDA_PREFIX
(/project/arcc/salexan5/conda/py_env) [salexan5@mblog2 ~]$ pip list -v
Package                 Version  Location                                                         Installer
----------------------- -------- ---------------------------------------------------------------- ---------
...
numpy                   2.0.0    /project/arcc/salexan5/conda/py_env/lib/python3.12/site-packages pip
...

...

...