Documentation Index
Fetch the complete documentation index at: https://mintlify.com/DedalusProject/dedalus_conda/llms.txt
Use this file to discover all available pages before exploring further.
Overview
Bothconda_install_dedalus2.sh and conda_install_dedalus3.sh share the same configuration options. These options are defined as shell variables at the top of each script and control the installation behavior, dependencies, and environment configuration.
Configuration Variables
Environment Options
Name of the conda environment to create or update.Default values:
dedalus2for v2 scriptdedalus3for v3 script
Skip conda prompts by automatically confirming all operations.Values:
1: Skip prompts (pass-yflag to conda)0: Prompt for confirmation
Suppress verbose conda output during installation.Values:
1: Quiet output (pass-qflag to conda)0: Verbose output
MPI Configuration
Control whether to install OpenMPI from conda or use a custom MPI installation.Values:
1: Install OpenMPI from conda-forge0: Use custom MPI (requiresMPI_PATHto be set)
- conda-forge compilers
- OpenMPI library
- openmpi-mpicc wrapper
- mpi4py Python bindings
Path to custom MPI installation prefix. Required when The script will add
INSTALL_MPI=0.The path should point to the MPI installation root directory containing bin/, lib/, and include/ subdirectories.Example:${MPI_PATH}/bin to PATH and use it to build mpi4py.When using custom MPI, ensure the MPI compiler wrappers (
mpicc, mpicxx, mpifort) are in ${MPI_PATH}/bin.FFTW Configuration
Control whether to install FFTW from conda or use a custom FFTW installation.Values:Example:
1: Install FFTW from conda-forge0: Use custom FFTW (requiresFFTW_PATHto be set)
--no-deps to avoid pulling unnecessary dependencies:Path to custom FFTW installation prefix. Required when
INSTALL_FFTW=0.The path should point to the FFTW installation root directory containing lib/ and include/ subdirectories.Example:HDF5 Configuration
Control whether to install HDF5 from conda or use a custom HDF5 installation.Values:
1: Install HDF5 from conda-forge0: Use custom HDF5 (requiresHDF5_DIRto be set)
- If
INSTALL_MPI=1: Installs parallel HDF5 (hdf5=*=mpi*,h5py=*=mpi*) - If
INSTALL_MPI=0: Installs serial HDF5 (hdf5=*=nompi*,h5py=*=nompi*)
Path to custom HDF5 installation prefix. Required when
INSTALL_HDF5=0.The path should point to the HDF5 installation root directory containing lib/ and include/ subdirectories.Example:Indicate whether custom HDF5 installation has parallel (MPI) support. Only relevant when
INSTALL_HDF5=0.Values:"ON": HDF5 built with parallel/MPI support- Not set or
"OFF": HDF5 built without MPI support
- If
HDF5_MPI="ON": Builds h5py withCC=mpiccfor parallel support - Otherwise: Builds h5py without MPI support
HDF5 from conda will only have parallel support if MPI is also installed from conda (
INSTALL_MPI=1).BLAS Configuration
Choose the BLAS/LAPACK implementation for numpy and scipy.Values:
"openblas": Use OpenBLAS (open-source, generally good performance)"mkl": Use Intel Math Kernel Library (optimized for Intel CPUs)
- Installs
libblas=*=*openblas - Sets
FFTW_STATIC=0(dynamic linking) - On Apple Silicon with arm64 builds, pins
libopenblas<0.3.20to avoidggeverrors
- Installs
libblas=*=*mkl - Sets
FFTW_STATIC=1(static linking to avoid symbol conflicts) - May provide better performance on Intel processors
Python Configuration
Python version to install in the conda environment.Supported versions:
Any Python 3.x version supported by conda-forge (typically 3.8+).Example:
Dedalus requires Python 3.8 or newer. Check the Dedalus documentation for specific version requirements.
Apple Silicon Configuration
Control architecture for Apple Silicon (M1/M2/M3) Macs.Values:
0: Use x86_64 packages via Rosetta 2 emulation (osx-64)1: Use native arm64 packages (osx-arm64)
- Better compatibility with scientific libraries
- Uses Rosetta 2 translation (minimal performance impact)
- Sets
CONDA_SUBDIR=osx-64
- Native Apple Silicon performance
- May have compatibility issues with some packages
- Automatically pins
libopenblas<0.3.20when using OpenBLAS to avoid numerical errors
Example Configurations
Standard Installation with Conda Packages
Custom MPI with Conda FFTW and HDF5
When using custom MPI with conda FFTW, ensure your MPI is OpenMPI-compatible since conda FFTW is built with OpenMPI.
Fully Custom Dependencies
Intel MKL Configuration
When using MKL, the script automatically sets
FFTW_STATIC=1 to statically link FFTW, avoiding symbol conflicts between MKL and FFTW.Apple Silicon Native Build
Verbose Installation for Debugging
Environment Variables Set by Script
In addition to the configuration options, the script sets several environment variables during installation:During Installation
Prevents Python from adding user site-packages directory to
sys.path.Unset to ensure a clean Python environment without interference from system packages.
Automatically set based on BLAS choice:
0for OpenBLAS (dynamic linking)1for MKL (static linking)
When using custom MPI, the script prepends
${MPI_PATH}/bin to PATH:Set to
mpicc when installing mpi4py, h5py, and Dedalus to ensure proper MPI linking:On Apple Silicon with
APPLE_SILICON_BUILD_ARM=0, sets architecture to x86_64:Persistent Environment Variables
These are saved to the conda environment and active whenever the environment is activated:Disables OpenMP threading by default to avoid oversubscription in MPI jobs.
Limits NumExpr threads to prevent performance issues with MPI.
Validation and Error Checking
The scripts perform several validation checks before installation:Required Environment Check
Custom Path Validation
When using custom installations (INSTALL_*=0), the corresponding path variable must be set:
FFTW_PATH and HDF5_DIR.
Platform Detection
BLAS Validation
Modifying Options
To customize the installation, edit the configuration section at the top of the script before running it:
Alternatively, you can set environment variables before running the script:
Environment variables set before running the script only affect variables explicitly exported in the script (like
MPI_PATH, FFTW_PATH, HDF5_DIR). Internal script variables must be edited within the script file itself.