Goal: A list of commonly asked questions that will be addressed here, but not necessarily within the workshop itself.
Can I use modules with Conda environments?
Question: Can I perform module loads
while using an activated Conda environment?
Yes, but…
Remember, performing a module load
is basically extending various environment variables, including PATH
. So, in principle if you have loaded a module that provides access to say some command-line utility, scripts and/or libraries, then these are still available.
But, will they function as expected? Maybe…
Since you have a Conda environment activated, then whatever is within it is being used. For example, maybe the Conda environment has been built with Python version 3.9 - but what happens if the module you have loaded is running scripts that have been built to use Python version 3.12 and are not compatible with 3.9? Will they run?
The moral of this answer is that in principle you can, but you need to test that there are no dependency issues that might occur.
Also, regards reproducibility, you can share the Conda environment, but how will you share the module load
to say work on another/different cluster/desktop environment?
Prev | Workshop Home | Next |