PIANISTpy
Particle Initial conditions with ANISoTropy · ver. 1.0.0
PIANISTpy logo

Anisotropic spherical models, truncated in phase space

PIANISTpy builds spherical, non-rotating, velocity-anisotropic equilibrium models, self-consistently truncated in phase space, for dark matter (sub)halos, dwarf galaxies, stellar spheroids and star clusters. The package provides distribution functions, particle initial conditions, radial and tangential velocity dispersion profiles and line-of-sight observables, with JAX-based end-to-end differentiability for gradient-based Monte Carlo inference.

Install

pip install pianistpy. Python 3.11 or later. PIANISTpy runs on the CPU on Linux, macOS and Windows, and on a CUDA GPU under Linux.

Dependencies and platforms →

Quick start

A few lines of code go from an input density profile and an anisotropy model to the distribution function, a model truncated in phase space, particle initial conditions and velocity observables.

Run the example →

Examples

Jupyter notebooks for generating particle initial conditions and for computing observables from a model.

Examples →

Accuracy

For each model of a fixed grid, the relative error of the density computed back from the distribution function, and the tier that the result reports, or the exception that the package raises for a model that the package does not build.

Accuracy tables →

What PIANISTpy does

Release notes (ver. 1.0.0)

Ver. 1.0.0 is the initial public release of PIANISTpy, described in Chiang, van den Bosch and Schive (2026d), MNRAS submitted, arXiv:2610.28758, henceforth Chiang+(2026d). Ver. 1.0.0 provides the distribution functions and their truncation, particle sampling with draws restricted to a user-specified range of radii or velocities, the observables (sigma_r, sigma_t, sigma_los, losvd, aperture_losvd, pdf_v), a report of the numerical accuracy with every result, and gradients in the superposition weights, the mass and length scales and, for Method II components, the anisotropy parameters. Ver. 1.0.0 runs on the CPU and, with a CUDA build of JAX under Linux, on the GPU. The dependencies, standard and minimum, are listed on the Install page.

Release notes →

Citation

PIANISTpy is described in Chiang+(2026d).

How to cite →

© 2026 Barry T. Chiang