Skip to content

Using and Installing CCL on NERSC

Heather Kelly edited this page Oct 22, 2019 · 23 revisions

To use the central installation of pyCCL at NERSC.

  • Using the CCL Python module in the shared environment :
    • Setup the environment: source /global/common/software/lsst/common/miniconda/setup_current_python.sh
    • Quick test to be sure things are set up correctly You can check whether pyccl has been set up correctly by running python -c "import pyccl" and checking that no errors are returned.

or

  • Run Example Notebooks

    source /global/common/software/lsst/common/miniconda/kernels/setup.sh

    • Clone the CCL repo to your NERSC $HOME directory

    git clone https://github.com/LSSTDESC/CCL.git

    1. Start up http://jupyter.nersc.gov/

    2. Open your notebook

    3. Change the kernel to desc-stack

    4. Run your notebook

To Build the CCL Paper

  • git clone https://github.com/LSSTDESC/CCL.git
  • cd CCL
  • git checkout ccl_paper
  • module load python/3.6-anaconda-4.4
  • module load latex
  • pip install --user mkauthlist
  • export MKAUTHLIST=$HOME/.local/cori/3.6-anaconda-4.4/bin/mkauthlist
  • cd doc/ccl_paper
  • make apj

pyccl >= v2.0.1 Installation

  1. If class is not installed already (The last step needs to be done in CCL installation directory).

    • export CFLAGS=-fPIC
    • export CRAYPE_LINK_TYPE=dynamic
    • export XTPE_LINK_TYPE=dynamic
    • python class_install.py
  2. Load the necessary modules. You can run the steps as follows (or put them in a script, e.g., CCL_setup.sh, and do source CCL_setup.sh)

    • module load gsl/2.1
    • module load cray-fftw
    • module load cmake
    • module load swig
    • export LDFLAGS+="-L$GSL_DIR/lib -L$FFTW_DIR"
    • export CPPFLAGS+="-I$GSL_DIR/include -I$FFTW_DIR/../include"
  3. pip install pyccl==2.0.1