GPR - Basic Gaussian Process Library
Basic Gaussian process regression library. (Eigen3 required)
- Multivariate Gaussian process regression
- Calculation of the derivative at a point
- Calculation of the uncertainty at a point
- Save and Load the Gaussian process to/from files
- Kernels: White, Gaussian, Periodic, RationalQuadratic, Sum and Product
- Derivative of the kernels
- Likelihood functions: Gaussian Log Likelihood (incl. derivative wrt. kernel parameter)
- Prior distributions: Gaussian, Inverse Gaussian, Gamma (incl. sampling, cdf and inverse cdf)
- Prior distributions can be built by providing their mode and variance
To setup the library clone the git repository first
git clone https://github.com/ChristophJud/GPR.git
The building of GPR is based on cmake. So navigate to the main directory GPR and create a build directory.
mkdir build # create a build directory cd build ccmake .. # ccmake is an easy tool to set config parameters
Set the build type and the installation directory and
Since GPR depends on the matrix library Eigen provide its include directory
If not all required Boost libraries are found on the system provide a custom installation
Boost_INCLUDE_DIR /path/to/boost/boost_1_57_0/ Boost_LIBRARY_DIR /path/to/boost/boost_1_57_0/stage/lib/
Make sure that boost has been built with C++11 by adding
cxxflags="-std=c++11" to the
make install -j8
and the library including all test programs will be built.
Include the library in your own cmake project
If you want to include the library into your own project the straight forward way is the following: Add
to your CMakeLists.txt file and provide
In the CMakeLists.txt you can link your program with
The tests can be seen as good examples to how to use the library.
- Matrix valued kernels
- Store/load into/from hdf5 files
A thorough introduction can be found in the open book of C.E. Rasmussen: Rasmussen, Carl Edward. Gaussian processes for machine learning. (2006).