deeptime

March 29, 2026 ยท View on GitHub

License: LGPL v3 Tests codecov DOI

Deeptime is a general purpose Python library offering various tools to estimate dynamical models based on time-series data including conventional linear learning methods, such as Markov State Models (MSMs), Hidden Markov Models (HMMs) and Koopman models, as well as kernel and deep learning approaches such as VAMPnets and deep MSMs. The library is largely compatible with scikit-learn, having a range of Estimator classes for these different models, but in contrast to scikit-learn also provides Model classes, e.g., in the case of an MSM, which provide a multitude of analysis methods to compute interesting thermodynamic, kinetic and dynamical quantities, such as free energies, relaxation times and transition paths.

Installation via conda or pip. Both provide compiled binaries for Linux, Windows, and MacOS (x86_64 and arm64).

conda-forgePyPI
conda install -c conda-forge deeptimepip install deeptime

Documentation: deeptime-ml.github.io.

Main components of deeptime

Dimension reductionDeep dimension reductionSINDy
Dimension reductionDeep dimension reductionSINDy
Markov state modelsHidden Markov modelsDatasets
MSMsHMMsDatasets

Building the latest trunk version of the package:

Using pip with a local clone and pulling dependencies:

git clone https://github.com/deeptime-ml/deeptime.git

cd deeptime
pip install .

Or using pip directly on the remote:

pip install git+https://github.com/deeptime-ml/deeptime.git@main

Building as a standalone CMake project

The C++ library and tests can be built directly with CMake. This requires Python (with development headers), NumPy, and pybind11 to be available.

cmake -B build \
  -DDEEPTIME_BUILD_CPP_TESTS=ON \
  -DPython_ROOT_DIR=/path/to/venv \
  -DPython_FIND_VIRTUALENV=ONLY \
  -Dpybind11_DIR=$(python -c "import pybind11; print(pybind11.get_cmake_dir())")

cmake --build build --target tests
./build/tests/tests

CMake options

VariableDefaultDescription
DEEPTIME_BUILD_CPP_TESTSOFFBuild the C++ unit tests (Catch2)
DEEPTIME_VERSION0.0.0Version string without commit offset
DEEPTIME_VERSION_INFO0.0.0Full version string

Required CMake variables for dependency discovery

VariableDescription
pybind11_DIRPath to pybind11's CMake config (e.g. from python -c "import pybind11; print(pybind11.get_cmake_dir())")
Python_ROOT_DIRPython installation or virtualenv prefix (helps CMake find the right interpreter)
Python_FIND_VIRTUALENVSet to ONLY when using a virtualenv to prevent CMake from picking up the system Python