# smolgp

_**S**tate Space **M**odels for **O**(**L**inear/Log) **G**aussian **P**rocesses_

[![docs](https://readthedocs.org/projects/smolgp/badge/?version=latest)](https://smolgp.readthedocs.io/en/latest/index.html)
[![Tests](https://github.com/smolgp-dev/smolgp/actions/workflows/tests.yml/badge.svg)](https://github.com/smolgp-dev/smolgp/actions/workflows/tests.yml)
[![codecov](https://codecov.io/github/smolgp-dev/smolgp/branch/main/graph/badge.svg?token=KQLRPBCV9X)](https://codecov.io/github/smolgp-dev/smolgp)
[![Journal](https://img.shields.io/badge/AAS_Journals-AJ_171_259-blue)](https://doi.org/10.3847/1538-3881/ae4d0b)
[![arXiv](https://img.shields.io/badge/arXiv-2601.02527-b31b1b.svg)](https://arxiv.org/abs/2601.02527)
[![DOI](https://zenodo.org/badge/1065470871.svg)](https://doi.org/10.5281/zenodo.18418837)

[`smolgp`](https://github.com/smolgp-dev/smolgp) is a Python/JAX standalone extension of the [`tinygp`](https://github.com/dfm/tinygp) package that uses the state space representation of Gaussian Process to achieve substantial performance boosts. Like `tinygp` it is built on top of [`jax`](https://github.com/google/jax) and so can utilize just-in-time compliation, automatic differentiation, and GPU-accelerated linear algebra. It can even be [parallelized](tutorials/parallel) for a further performance boost.

To get started, check out the {ref}`guide` and then the {ref}`quickstart` to hit the ground running. There are also many useful {ref}`tutorials` with example usage, including {doc}`tutorials/introssm` for those interested in the framework that powers `smolgp`. For all the nitty-gritty details, see the [full API documentation](autoapi/smolgp/index). 

If you use `smolgp` in your research, please see {ref}`citing`.

```{admonition} When should I use <code>smolgp</code> instead of <code>tinygp</code> ?
:class: tip

<div style="display: flex; align-items: flex-start;">
  <div style="width:75px; margin-right: 16px;">
    <img src="_static/quasiperiodic.png" style="max-width: 100%; height: auto;">
  </div>
  <div style="flex: 1;">
    <strong>Scalable non-quasiseparable kernels</strong><br>
    If you want scalable (O(N) or better) performance for GP kernels which do not have quasiseparable representations but can be approximated by a state space model, such as the quasiperiodic kernel (see See <a href="tutorials/kernels.html#arbitrary-kernels">Defining Kernels</a>).
  </div>
</div>
<br>
<div style="display: flex; align-items: flex-start;">
  <div style="width:75px; margin-right: 16px;">
    <img src="_static/integrated_measurement.png" style="max-width: 100%; height: auto;">
  </div>
  <div style="flex: 1;">
    <strong>Integrated measurements</strong><br>
    If your measurements are integrated over finite time intervals that are appreciable compared to the variability timescale of the GP. <code>smolgp</code>  correctly accounts for the integrated covariance while maintaining scalable performance. See <a href="tutorials/integrated.html">Integrated Measurements</a> for more details.
  </div>
</div>
<br>
<div style="display: flex; align-items: flex-start;">
  <div style="width:75px; margin-right: 16px;">
    <img src="_static/overlapping_measurements.png" style="max-width: 100%; height: auto;">
  </div>
  <div style="flex: 1;">
    <strong>Overlapping datasets</strong><br>
    If you are jointly modeling integrated data from multiple instruments where exposures overlap with one another, <code>smolgp</code> naturally accounts for the covariances during the overlap by construction, preserving scalability.
  </div>
</div>
```

If you find any bugs, please raise them on the [GitHub issues
page](https://github.com/smolgp-dev/smolgp/issues).


## Table of contents

```{toctree}
:maxdepth: 2

guide
tutorials
apidocs/index
GitHub Repository <https://github.com/smolgp-dev/smolgp>
```

## Authors & license

Copyright 2025, 2026 Simons Foundation, Inc.

`smolgp` is built and maintained by [Ryan Rubenzahl](https://github.com/rrubenza) and [Soichiro Hattori](https://github.com/soichiro-hattori), but contributions from all via the [Issue
Tracker](https://github.com/smolgp-dev/smolgp/issues) are welcome. Licensed under the MIT license (see `LICENSE`).