Citlali is the official data reduction pipeline engine for TolTEC.
It is developed as part of TolTECA, the TolTEC data analysis software suite.
While citlali is developed targeting LMT/TolTEC, it can also be adapted to with other telescope/detectors that shares similar architectural properties.
Citlali requires a C++20 compiler and CMake 3.20+ to build.
The software is fully tested for the following platform/operating system/compilers:
- x86_64 macOS 11 (Big Sur); LLVM 13+
- x86_64 Ubuntu 20.04; GCC 10+
Build on other Linux-like operating systems should also work, given a C++20 capable compiler and the required dependencies.
Homebrew is required to install the compiler, build tools, and some optional dependencies.
To install the compiler and build tools:
$ brew install git cmake llvm libomp python conan
The package libomp
and python
are not required, but highly recommended.
conan
can be installed either through brew
or python
.
By default, the installed LLVM compiler is in /usr/local/opt/llvm/bin
. If
not sure, consult brew info llvm
.
Optionally, the following packages can be installed via Homebrew, and be made
available to the build system via the CMake variables USE_INSTALLED_*
(see section below for details of the CMake configuration):
$ brew install fmt spdlog gflags glog gtest benchmark boost cfitsio ccfits netcdf numpy
The following package are required to build citlali:
$ sudo apt install build-essential gcc-10 g++-10
By default, citlali requires a CMake version that is newer than what the APT repo would provide. To install the latest version of CMake, follow the instruction here: https://apt.kitware.com.
Optionally, the following packages can be installed and be made available to
the build system via the CMake variables USE_INSTALLED_*
:
$ sudo apt install libnetcdf-dev python3-pip python3-dev libboost-all-dev
For additional performance with Intel CPUs, the Intel OneAPI toolkit (MKL) may be installed. The instruction can be found in the official website.
First, clone the repo or download the source code from the github page:
$ git clone https://github.com/toltec-astro/citlali.git $ cd citlali
To build, go into the source directory:
// in the cloned citlali directory: $ mkdir build $ cd build $ cmake .. -DCMAKE_BUILD_TYPE=Release [more options...] $ make citlali_cli
To customize the build, add options like -D<key>=<value>
to the cmake command
line. Some options to set are:
CMAKE_BUILD_TYPE
: The build type, can beRelease
orDebug
.CMAKE_C_COMPILER
andCMAKE_CXX_COMPILER
: The compiler to use, if they are not in the default location. For example, macOS users would need to specify the LLVM compiler paths as:-DCMAKE_C_COMPILER=/usr/local/opt/llvm/bin/clang -DCMAKE_CXX_COMPILER=/usr/local/opt/llvm/bin/clang++
USE_INTEL_ONEAPI
: This can be set toON
to use the Intel OneAPI toolkit (MKL) for additional performance.
The build dependencies are managed by the CMake super-build scripts provided in the tula_cmake folder. The following dependencies are managed in this way:
Boost
Ceres
Clipp
Csv
Eigen3
Enum
Grppi
MXX
NetCDF
NetCDFCXX4
Re2
Spectra
Yaml
logging
testing
perflibs
Each dependency comes with three CMake options to configure how it is integrated:
USE_INSTALLED_{dep}
: Use the dependency installed in the system via brew or apt.CONAN_INSTALL_{dep}
: Use Conan to install the dependency automatically. To use this option, the Python packageconan
has to be installed:$ python3 -m pip install conan
FETCH_{dep}
: Use CMakeFetchContent
to download the source code of the package and build the dependency inline.
By default, most of the dependencies above are set to use the
CONAN_INSTALL_*
option whenever they are available in the Conan Index,
otherwise FETCH_*
is used.
Once successfully built, the created executables will be available in
build/bin
.
To check the version of the program:
// In the build directory: $ ./bin/citlali --version
To show the help screen of the commandline interface:
// In the build directory: $ ./bin/citlali --help
Please see the API documentation for details.
3-Clause BSD.