MRax#

MRax logo

A Python library for quantitative MRI research.

MRax provides data structures and optimization utilities for quantitative MRI research. It includes unit-aware observables, common signal models, reconstruction helpers, and portable .mrax study bundles.

MRax is intended for research use only.

Main components#

Signal models

Built-in model factories for common quantitative MRI equations, plus a template for custom models.

Named experiments

Experiment and Quantity objects keep dimensions and units attached to arrays.

JAX optimization

Differentiable fitting with masks, constraints and regularization, using Optax and proximal solvers.

MRI reconstruction

Cartesian and non-Cartesian helpers, k-space processing blocks, variational solvers, and model-based parameter reconstruction.

Storage

Portable .mrax study bundles for images, k-space, fitted maps and metadata, with NIfTI and DICOM export.

Core workflow#

  1. Build or import a Study from synthetic data, Pulseq, Bruker ParaVision, or a custom loader.

  2. Pick a model for each experiment and insert any required observables from study globals or prior fits.

  3. Plan and execute fits with mrax.core.study_runner.plan_study_fits() and mrax.core.study_runner.execute_study_plan(), or call mrax.core.loss_builder.run_fit() directly for a single experiment.

  4. Inspect fitted fields, derived maps, and convergence history.

  5. Save the study and results in a .mrax bundle. See MRax Study Storage. Use Post-fit Analysis for ROI or group summaries.

Start Here#

Quick API Jump#