Skip to main content

Gamut

An open file format for parametric simulation studies,
with libraries for Python, MATLAB, Julia, C++ and C.

CI


Gamut is a file format for parametric simulation studies: the hundreds or thousands of CFD or FEA runs behind a design sweep, an aerodynamic database or a surrogate model. One file holds the run table, each run's inputs, results and status, and, when the runs have a mesh, the mesh and every field on it, all with units. Python, MATLAB, Julia and C++ read and write it with the same calls. Files are HDF5 laid out as netCDF-4, so h5py, xarray and the netCDF tools open them too, and a published specification says what every array in them means.

A select call on a study file and the four runs it returns, each with its values, units and split beside the pressure field read for that run.

Example

Nine runs of potential flow past a cylinder on one mesh: eight written as a sweep, a ninth added after reopening the file, then the pressure at one node read back from every run. points, cells and solve stand for your mesh and your solver, and the complete programs are in examples/.

Python

with gamut.create("cylinder.gamut", writer="example sweep", mesh="shared", per="fixed",
                   coordinates={"units": "m", "axes": 2},
                   parameters={"gamma": {"units": "m2 s-1", "role": "design"}},
                   fields={"cp": {"units": "1", "at": "node"}}) as study:
    study.set_mesh(points, cells)
    for gamma in np.linspace(0.0, 3.5, 8):
        study.add_run({"gamma": gamma}, fields={"cp": solve(gamma)})

with gamut.open("cylinder.gamut", mode="a") as study:
    study.add_run({"gamma": 4.0}, fields={"cp": solve(4.0)})

with gamut.open("cylinder.gamut") as study:
    cp = study.get_field("cp", nodes=[12])                 # runs x nodes

MATLAB

study = gamut.create('cylinder.gamut', 'writer', 'example sweep', 'mesh', 'shared', 'per', 'fixed', ...
    'coordinates', struct('units', 'm', 'axes', 2), ...
    'parameters', struct('gamma', struct('units', 'm2 s-1', 'role', 'design')), ...
    'fields', struct('cp', struct('units', '1', 'at', 'node')));
study.setMesh(points, cells);
for gamma = linspace(0, 3.5, 8)
    study.addRun(struct('gamma', gamma), 'fields', struct('cp', solve(gamma)));
end
study.close();

study = gamut.open('cylinder.gamut', 'mode', 'a');
study.addRun(struct('gamma', 4), 'fields', struct('cp', solve(4)));
study.close();

study = gamut.open('cylinder.gamut');
cp = study.getField('cp', 'nodes', 13);                         % runs x nodes, from 1
study.close();

Julia

Gamut.create("cylinder.gamut"; writer="example sweep", mesh="shared", per="fixed",
              coordinates=(units="m", axes=2),
              parameters=Dict("gamma" => (units="m2 s-1", role="design")),
              fields=Dict("cp" => (units="1", at="node"))) do study
    Gamut.set_mesh!(study; points, cells)
    for gamma in range(0, 3.5; length=8)
        Gamut.add_run!(study, Dict("gamma" => gamma); fields=Dict("cp" => solve(gamma)))
    end
end

Gamut.open("cylinder.gamut"; mode="a") do study
    Gamut.add_run!(study, Dict("gamma" => 4.0); fields=Dict("cp" => solve(4.0)))
end

cp = Gamut.open("cylinder.gamut") do study
    Gamut.get_field(study, "cp"; nodes=[13])                 # runs × nodes, from 1
end

C++

auto study = gamut::create("cylinder.gamut", "example sweep", "shared", "fixed");
study.declare_coordinates("m", 2);
study.declare_parameter("gamma", "design", "m2 s-1");
study.declare_field("cp", "node", "1");
study.set_mesh(points, cells);
for (double gamma = 0.0; gamma < 3.75; gamma += 0.5)
  study.add_run({{"gamma", gamma}}, {{"cp", solve(gamma)}});
study.close();

study = gamut::open("cylinder.gamut", "a");
study.add_run({{"gamma", 4.0}}, {{"cp", solve(4.0)}});
study.close();

study = gamut::open("cylinder.gamut");
auto cp = study.get_field("cp", gamut::all, {12});    // runs x nodes

All four print the same values:

cp at the top of the cylinder, run by run: -3.00 -2.69 -2.39 -2.10 -1.83 -1.57 -1.32 -1.08 -0.86

MATLAB and Julia count positions from 1, so node 12 in Python and C++ is node 13 in MATLAB and Julia.

What you can do with it

Use one file everywhere Python, MATLAB, Julia, C++ and C call one core, so a query returns the same values in each, and each reads what another wrote.
Read only what you need Choose runs by condition (mach > 0.7 and status == converged) and nodes by zone. On a shared mesh, one region of every run or one node across thousands of runs is a single read, and Python can convert values to the units you ask for (reading parts).
Train models on it Each field on a shared mesh is one block of runs × nodes (or cells). Labels record status, fidelity or solver, a split says which rows are for training and which for testing, and a file can name the group a fair test must hold out whole. Standard deviations, quantiles and derivatives are stored beside the results they describe (run tables, uncertainty).
Share fitted models A model is a file in the same format with no runs and no code inside. Evaluating it on new inputs gives an ordinary study; a model type of your own is registered by the software that defines it (models).
Hold tables, families and time series A table of runs with no mesh, one mesh for every run, one geometry per member of a family of shapes on one topology, a mesh per run, or transient runs with a row per saved step (families, time series).
Check what you receive Writers require units on parameters, results, constants and coordinates, and gamut validate checks the 34 numbered rules of the specification. A corpus of 64 valid, broken and hostile files runs in CI through the Python, MATLAB and Julia libraries and the C interface under them, and readers check sizes before allocating memory and never follow links (files from outside).

Performance

Size on disk and three read times for one study stored as Gamut, HDF5 with a group per run, netCDF-4, VTKHDF, Zarr, a NumPy file per run, uncompressed NumPy arrays and VTK files.

Gamut is about the size of netCDF-4 and Zarr, a little smaller than VTKHDF and HDF5 written a run at a time, and a sixth of the VTK files. Choosing runs by condition and reading a result of each takes about a millisecond, as fast as a Parquet file of the run table alone. Opening a file costs Gamut about 0.9 ms, so HDF5 and VTKHDF read straight with h5py fetch one small run faster, and uncompressed NumPy arrays, at 2.3 times the size, read fastest of all. Gamut's chunks are laid out for reading whole runs, so one node across every run takes 127 ms, slower than Zarr or netCDF-4. HDF5 decompresses on one core; with threads turned on, Gamut fetches the compressed chunks of a whole-run or contiguous read through HDF5 and decompresses them in parallel, and four threads bring that read to 39 ms. On the AirfRANS study queried in the picture at the top, with meshes of about 176,000 nodes, one run reads in 15 ms against 124 ms from its VTK file.

Apple M3, 8 GB, macOS 27, files in the operating system's cache; medians of five reads, each opening the file. The benchmarks page has every number, the method and the scripts to repeat it.

Install

Language Install
Python 3.10 or later pip install gamut-format
MATLAB build_mex(core) once in the matlab folder of a checkout
Julia 1.9 or later Pkg.add(url="https://github.com/bijective-systems-org/gamut", subdir="julia")
C++ and C CMake build and install, then find_package(gamut); include gamut/gamut.hpp (C++17) or gamut/gamut.h (C)

The Python wheels for macOS, Linux and Windows contain the core with HDF5 linked in. MATLAB and Julia use the same core: the wheel's (gamut.library_path() prints where it is) or one built with CMake. Installing has the details for each language.

Documentation

The guide has one short page per concept, each running one script from examples/. The specification defines the format for anyone writing another implementation, and how it compares sets Gamut beside VTK, CGNS, Exodus, netCDF-CF and Zarr.

Before version 1 the format was called mestra. Its files (mestra/0) are refused with their version named; its 0.1 releases stay on PyPI under that name.

License

Apache 2.0. Made by Bijective Systems. If you use Gamut in published work, please cite it (CITATION.cff).

Metadata

Release files for gamut-format 1.1.0

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

Source distribution (sdist)

Source distribution for gamut-format 1.1.0
File Size Uploaded Provenance
gamut_format-1.1.0.tar.gz 215.1 kB With provenance Details

Built distributions (wheels)

Table of built distributions (wheels) for gamut-format 1.1.0
File
gamut_format-1.1.0-py3-none-win_amd64.whl Python 3 none Windows x86-64 Details
gamut_format-1.1.0-py3-none-manylinux_2_28_x86_64.whl Python 3 none Linux glibc 2.28+ x86-64 Details
gamut_format-1.1.0-py3-none-macosx_11_0_x86_64.whl Python 3 none macOS 11.0+ x86-64 Details
gamut_format-1.1.0-py3-none-macosx_11_0_arm64.whl Python 3 none macOS 11.0+ ARM64 Details

Total release size: 7.6 MB

Release files / gamut_format-1.1.0.tar.gz

Download URL gamut_format-1.1.0.tar.gz
Size 215.1 kB
Tags Source
SHA-256 checksum
How to use checksums
ae9bc4caea971f89fb76bb2ecc1268be373a08aba9f743f6aa8606d88ee866a5
BLAKE2b-256 checksum
How to use checksums
2f1604c45a9d2c5b2978993e47afeb792ffe231a5c7ddf089569aba7945ca11f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 19, 2026.

Transparency log

Release files / gamut_format-1.1.0-py3-none-win_amd64.whl

Download URL gamut_format-1.1.0-py3-none-win_amd64.whl
Size 1.6 MB
Tags Python 3 Windows x86-64
SHA-256 checksum
How to use checksums
b25818c34a1fecad3d5484c61c43d08ab8da224d5c3b6a65eeb84f4af9164555
BLAKE2b-256 checksum
How to use checksums
1fc7a3be66deaff8052b4027a46d90e20aada2bf0f2c1dfc4d8d09fcf5e85ae9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 19, 2026.

Transparency log

Release files / gamut_format-1.1.0-py3-none-manylinux_2_28_x86_64.whl

Download URL gamut_format-1.1.0-py3-none-manylinux_2_28_x86_64.whl
Size 2.3 MB
Tags Linux glibc 2.28+ x86-64 Python 3
SHA-256 checksum
How to use checksums
6946be723ddfc2184a00fe615b84d37d297a7bcb0b7baf5156a389bcd3a84b51
BLAKE2b-256 checksum
How to use checksums
b4101e088b9ae33452766c54e5dfe82c6742c0addf3a1362a5f27bb731abe745
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 19, 2026.

Transparency log

Release files / gamut_format-1.1.0-py3-none-macosx_11_0_x86_64.whl

Download URL gamut_format-1.1.0-py3-none-macosx_11_0_x86_64.whl
Size 1.9 MB
Tags Python 3 macOS 11.0+ x86-64
SHA-256 checksum
How to use checksums
866694777763117a7347e2c13c7d0a7610e1c00573c35c042a34b89cc49fb49d
BLAKE2b-256 checksum
How to use checksums
651fb8c3e52e04ccf92b4469da60955e290bb502fbac09de161080615f8c7a4b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 19, 2026.

Transparency log

Release files / gamut_format-1.1.0-py3-none-macosx_11_0_arm64.whl

Download URL gamut_format-1.1.0-py3-none-macosx_11_0_arm64.whl
Size 1.6 MB
Tags Python 3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
1b89c8d47e26bf6bc5ea4d9b66a3edaea28a72cc09046dbb0b5a9f9613d79504
BLAKE2b-256 checksum
How to use checksums
dd2d05d720a2e0ae960ed877c44d6b5b4d1816819cd92f9d4226827477e5fb75
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 19, 2026.

Transparency log

Security for gamut-format 1.1.0

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 5 files in this release have been uploaded with provenance metadata.

Select from 5 files

Attestation for gamut_format-1.1.0.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 19, 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.

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