Notebooks#

The notebooks directory of the repository holds two marimo notebooks, which run in the browser on molab straight from GitHub:

Notebook

Contents

Run

lifted_convolutions.py

Each convolution of s2conv, checked numerically against the closed forms of the article, a literal evaluation on a sampling of the rotation group and the real-space definitions.

Open in molab

real_fields.py

The lifted convolutions applied to real spin fields of the Earth and the sky.

Open in molab

Each notebook lists its dependencies at the top of the file, as inline script metadata (PEP 723), which molab reads to install them. When the notebook runs without the repository, as in molab, real_fields.py downloads its fields from the notebooks/data directory on GitHub.

To run a notebook locally, install s2conv with the notebook extras (see Installation) and open it with marimo, from the repository root:

pip install "s2conv[notebooks]"
marimo edit notebooks/lifted_convolutions.py

Alternatively, marimo can install the dependencies listed in the notebook into an isolated environment, with uv:

marimo edit --sandbox notebooks/lifted_convolutions.py