Skip to main content

MOSFiT

Python Version PyPI version Documentation Status ascl:1710.006

MOSFiT (Modular Open-Source Fitter for Transients) is a Python 3.11+ package for fitting, sharing, and estimating the parameters of transients via user-contributed transient models. This is MOSFiT 2.0. Data for a transient can be provided by the user in a wide range of formats (JSON, ASCII tables, CDS, LaTeX).

See CHANGELOG.md for unreleased work and versioned notes.

Installation

Development installs use uv and Python 3.11+:

git clone https://github.com/guillochon/MOSFiT.git
cd MOSFiT
uv sync

Then run MOSFiT with uv run mosfit ..., or activate .venv.

Published installs are also available via conda and pip. conda-forge will ship 2.0 after a feedstock update (see recipe/); astrocats >= 0.5.0 must land on conda-forge first:

conda install -c conda-forge mosfit

or:

pip install mosfit

MPI support (mpi4py) is optional and needs a system MPI library:

uv sync --extra mpi

The SESN SEDONA emulator (sesn_sedona) needs PyTorch. Install that extra with:

uv sync --extra sedona

or, for a published install, pip install 'mosfit[sedona]'. Default models do not require it.

Using MOSFiT

The default sampler is nested sampling with dynesty. Pass local catalog JSON (or ASCII) with -e. Use --max-cores for local process-pool parallelism (no MPI required):

mosfit -e ./my_transient.json -m slsn --max-cores 10
mosfit -e mosfit/tests/PS1-10jh.json -m tde --max-cores 10 -R

Switch to ensemble MCMC with -D ensembler, or UltraNest with -D ultranest. Fits write products under products/ (including walkers.h5, and optionally chain.h5 if run with -c). For detailed instructions, see the documentation on RTD: https://mosfit.readthedocs.io/

Metadata

Release files for mosfit 2.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mosfit 2.1.1
File Size Uploaded Provenance Actions
mosfit-2.1.1.tar.gz 60.4 MB With provenance Details for mosfit-2.1.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for mosfit 2.1.1
File Interpreter ABI Platform Actions
mosfit-2.1.1-py3-none-any.whl Python 3 none any Details for mosfit-2.1.1-py3-none-any.whl

Total release size: 121.1 MB

Release files / mosfit-2.1.1.tar.gz

Download URL mosfit-2.1.1.tar.gz
Size 60.4 MB
Tags Source
SHA-256 checksum
How to use checksums
6d24f17380a937f2d29ae3db1433d0450b3b17501bbb1e4c24a7eacd7cca2137
BLAKE2b-256 checksum
How to use checksums
00060ce3ce7a983fd122704ee8861ce9cbad4035fc4f32716a1defd62a5e440b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 28, 2026.

Transparency log

Release files / mosfit-2.1.1-py3-none-any.whl

Download URL mosfit-2.1.1-py3-none-any.whl
Size 60.7 MB
Tags Python 3
SHA-256 checksum
How to use checksums
50e4b1f048662c383b7a4808f75f47a7f6c34d5aa6ee500c25bf241678a77161
BLAKE2b-256 checksum
How to use checksums
4d00517cc8af88f851bc3b0e60645277a61aae77ae2a70afcc3c56a73c360021
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 28, 2026.

Transparency log

Security for mosfit 2.1.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for mosfit-2.1.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 28, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

2.1.1 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page