Skip to main content

Twindex

Your inverse solver returned a parameter. Twindex proves whether the data could have determined it.

Least squares, Bayesian inference and physics-informed neural networks always return a parameter. On their own, they do not give an independently checkable proof of whether a very different parameter fits your measurements just as well. Twindex finds such twins and proves it: it writes a JSON certificate that a small exact checker (standard-library Python, no floating point, type-checked with mypy --strict) replays and verifies. A VALID pair certificate proves that no method can recover the parameter from those data with worst-case error below half the certified gap.

Certified problem classes:

ODE systems    u' = F(t, u; theta), u(0) = u0(theta), F and u0 any polynomials
               (SIR/SEIR, pharmacokinetics, mass-action kinetics, Lotka-Volterra,
                FitzHugh-Nagumo, ...)
1-D BVP        -u'' + q(x; theta) f(u) = g on (0, 1)
2-D elliptic   -Laplace(u) + q(x, y; theta) f(u) = g on (0, 1)^2
heat equation  u_t - u_xx + q(x; theta) f(u) = g on (0, 1) x (0, 1]

Any other simulator you can call from Python gets a numerical audit, clearly labelled as evidence rather than proof.

$ pip install twindex                      # exact checker + CLI, zero dependencies
$ pip install "twindex[general,report]"    # + ODE workflow, audits and evidence reports

$ twindex example theta500_pair > pair.json
$ twindex check pair.json
pair.json: VALID: ... every estimator of theta_0 has worst-case error >= 500 on these data

$ twindex ode model.json data.csv --eps 1/100 --box k10=0,1 --box k12=0,1 --box k21=0,1 --target k10 --output out/
VALID: certified_pair; certified L = ... (about 0.287761); No U claimed. Wrote out/report.md

$ twindex report pair.json --output evidence/
  • Certificates: witness and pair (twins) for every problem class; box and paving (two-sided bounds) for the 1-D problem.
  • Headline result: early-epidemic SIR data at noise 1e-3 provably cannot determine R0 (certified twins with R0 = 2.5 and about 1.72).
  • twindex ode / identify_ode: a model file and a CSV in, a certificate and a report out.
  • audit_model / certify_audit: numerical audits of any simulator, with certified replay where an exact model exists.
  • twindex.fit: check any callable (a PINN, scipy, FEM) as an exact candidate.
  • Certified derived targets such as R0 = beta/gamma, and certified upper bounds (identifiability) for polynomial and elementary ODE models.
  • A tested trust boundary: a small exact core, 91 adversarial certificates, mutation testing, an independent reference checker for 1-D certificates, and resource budgets on every input.
  • Every step is proved: https://arnav-m10.github.io/Twindex/THEORY/

Documentation: https://arnav-m10.github.io/Twindex/ · Source: https://github.com/Arnav-M10/Twindex

Metadata

Release files for twindex 0.9.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 twindex 0.9.0
File Size Uploaded Provenance Actions
twindex-0.9.0.tar.gz 2.0 MB With provenance Details for twindex-0.9.0.tar.gz

Built distribution (wheel)

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

Total release size: 2.1 MB

Release files / twindex-0.9.0.tar.gz

Download URL twindex-0.9.0.tar.gz
Size 2.0 MB
Tags Source
SHA-256 checksum
How to use checksums
d4cb086eb869ea2ef51fd562c14a830b6591c0e6374de0e3e4d6e8f6c8589afd
BLAKE2b-256 checksum
How to use checksums
c2c019e174ff4c44a26ec375c5ffc337d26cdc8ea084d28fbf129bd70fa15811
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 Nov 9, 2026.

Transparency log

Release files / twindex-0.9.0-py3-none-any.whl

Download URL twindex-0.9.0-py3-none-any.whl
Size 139.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
24451047bade93b42d09c5fe08cd916ef817bfd7c14e6f721c2f431ba6c55744
BLAKE2b-256 checksum
How to use checksums
ee2d666ec9223ea7d876e236b044c787915ed4ca08f16e9bc3423bd5d3215bf4
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 Nov 9, 2026.

Transparency log

Security for twindex 0.9.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

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for twindex-0.9.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 Nov 9, 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