TRIQS/nda 1.3.0
Multi-dimensional array library for C++
|
nda supports the usual installation procedure using CMake.
If you want to skip the installation step, you can go directly to Integration in C++ projects to see how you can integrate nda into your own C++ project by using CMake's FetchContent.
Note: To guarantee reproducibility in scientific calculations, we strongly recommend the use of a stable release version.
The dependencies of the C++ nda library are as follows:
For specific functionality, the following optional dependencies might be required:
nda fetches and builds the following libraries automatically (unless the user explicitly tells CMake not to and to use local installations instead):
For the Python interface, additional dependencies are required:
The Python interface is built with TRIQS/cpp2py. Please refer to the GitHub repository for further information.
Download the source code of the latest stable version by cloning the TRIQS/nda repository from GitHub:
Create and move to a new directory where you will compile the code:
In the build directory, call cmake including any additional custom CMake options (see below):
Note that it is required to specify CMAKE_INSTALL_PREFIX
, otherwise CMake will stop with an error.
Compile the code, run the tests and install the application:
Replace N
with the number of cores you want to use to build the library.
To choose a particular version, go into the directory with the sources, and look at all available versions:
Checkout the version of the code that you want:
and follow steps 2 to 4 above to compile the code.
The compilation of nda can be configured by calling cmake with additional command line options
The following options are available:
Options | Syntax |
---|---|
Specify an installation path | -DCMAKE_INSTALL_PREFIX=path_to_install_dir |
Build in Debugging Mode | -DCMAKE_BUILD_TYPE=Debug |
Disable testing (not recommended) | -DBuild_Tests=OFF |
Build the documentation | -DBuild_Documentation=ON |
Disable Python support | -DPythonSupport=OFF |
Build shared libraries | -DBUILD_SHARED_LIBS=ON |
Build benchmarks | -DBuild_Benchs=ON |
Test SSO memory optimizations | -DBuild_SSO_Tests=ON |
Enable CUDA support | -DCudaSupport=ON |
Enable MAGMA support | -DUse_Magma=ON |