Work

Bijx: Bijections and normalizing flows with JAX/NNX

Year: 2025
Type: article
Abstract: Normalizing flows (NF) are a powerful class of generative models that allow for both efficient sampling and exact likelihood evaluation (Kobyzev et al., 2021;Papamakarios et al., 2021;Rezende & Mohamed, 2015). Here we present bijx, a JAX library (Bradbury et al., 2018) built on Flax NNX (Heek et al., 2024) that combines a general normalizing flow API with specialized tools for physics, especially in the context of lattice quantum field theory. The API mirrors standard patterns (e.g., Bijection, Distribution, Chain, Transformed) while making every component an nnx. Module for coherent parameter/state management and seamless use with modern JAX ML tools. Beyond this general core, bijx provides first-class support for continuous normalizing flows (via diffrax), structure-preserving Crouch-Grossmann integrators for matrix Lie groups, symmetry-aware vector fields for lattice data, and utilities for Fourier and Lie algebra valued data. The package is available via pip, with source code on GitHub (https://github.com/mathisgerdes/bijx).Each capability can be used independently: the general NF API, continuous normalizing flow (CNF) interface, Lie-group integrators, and physics utilities are modular and separable. General ML users can adopt the standard flow API and CNF interface without the physics utilities, and vice versa.
Language: English
Open Access status: diamond
OpenAlex ID: W4417077482
FWCI: 0.864
Cites: 8
Cited by: 5
Related to: 10