Setup on Levante using Conda#

This section will present how to create your own customized workspace using a conda enviroment.

  1. Access a Levante login node via ssh:

  2. Download the latest version of miniconda:

  3. Install miniconda in your project work directory:

  4. Create a conda environment:

    conda create --name mycondaenv python=3.8.10
  5. Activate the conda environment:

    conda activate mycondaenv
  6. Install all your desired libraries such as pytorch, keras, numpy, etc. using:

    conda install <package name>
    • For recursively installing all packages at once consider writing a requirements.txt file, where each individual package name is written on a separate line and then use:

      pip install -r requirements.txt
    • If you already have a local environment set up on your laptop, you can take a snapshot of all your dependencies via:

      pip freeze > requirements.txt

      and then copy the generated requirements.txt file to the server and use the recursive installation line presented earlier to install the same dependencies on the server.

  7. Provided that all dependencies were installed, now you should be able to run your python scripts within this conda environment on Levante. However, do not run them on the Levante login node. Rather, allocate a compute node on Levante, then ssh into it, and then activate the created conda environment on the compute node. It is at this point that you can finally run your script via: