Skip to main content

tsinfer

License PyPI version Supported Python Versions Docs Build Tests codecov

Infer whole-genome tree sequences from genetic variation data. Tsinfer implements efficient algorithms to reconstruct ancestral haplotypes and recombination breakpoints, producing succinct tree sequences that capture shared ancestry across the genome. It scales to large cohorts and integrates cleanly with the broader tskit ecosystem for downstream statistics and analysis.

The documentation (stable • latest) contains details of how to use this software, including installation instructions.

Installation

python -m pip install tsinfer
# or
conda install -c conda-forge tsinfer

The initial algorithm, its rationale, and results from testing on simulated and real data are described in the following Nature Genetics paper:

Jerome Kelleher, Yan Wong, Anthony W Wohns, Chaimaa Fadil, Patrick K Albers and Gil McVean (2019) Inferring whole-genome histories in large population datasets. Nature Genetics 51: 1330-1338

Tsinfer versions 0.2.0 onwards allow missing data and provide a fully parameterised Li & Stephens matching algorithm (i.e. which allows mismatch). These improvements are described in the following Science paper:

Anthony Wilder Wohns, Yan Wong, Ben Jeffery, Ali Akbari, Swapan Mallick, Ron Pinhasi, Nick Patterson, David Reich, Jerome Kelleher, and Gil McVean (2022) A unified genealogy of modern and ancient genomes. Science 375: eabi8264

Please cite either or both of these if you use tsinfer in your work. Code to reproduce the results in the first paper is present in a separate GitHub repository.

Note that tsinfer does not attempt to infer node times (i.e. branch lengths of the inferred trees). If you require a tree sequence where the dates of common ancestors are expressed in calendar or generation times, you should post-process the tsinfer output using software such as tsdate.

Metadata

Release files for tsinfer 0.5.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 tsinfer 0.5.1
File Size Uploaded Provenance Actions
tsinfer-0.5.1.tar.gz 889.8 kB With provenance Details for tsinfer-0.5.1.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for tsinfer 0.5.1
File Actions
tsinfer-0.5.1-cp313-cp313-win_amd64.whl CPython 3.13 CPython 3.13 Windows x86-64 Details for tsinfer-0.5.1-cp313-cp313-win_amd64.whl
tsinfer-0.5.1-cp313-cp313-win32.whl CPython 3.13 CPython 3.13 Windows x86-32 Details for tsinfer-0.5.1-cp313-cp313-win32.whl
tsinfer-0.5.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.28+ x86-64, Linux glibc 2.17+ x86-64 Details for tsinfer-0.5.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
tsinfer-0.5.1-cp313-cp313-macosx_11_0_arm64.whl CPython 3.13 CPython 3.13 macOS 11.0+ ARM64 Details for tsinfer-0.5.1-cp313-cp313-macosx_11_0_arm64.whl
tsinfer-0.5.1-cp313-cp313-macosx_10_13_x86_64.whl CPython 3.13 CPython 3.13 macOS 10.13+ x86-64 Details for tsinfer-0.5.1-cp313-cp313-macosx_10_13_x86_64.whl
tsinfer-0.5.1-cp312-cp312-win_amd64.whl CPython 3.12 CPython 3.12 Windows x86-64 Details for tsinfer-0.5.1-cp312-cp312-win_amd64.whl
tsinfer-0.5.1-cp312-cp312-win32.whl CPython 3.12 CPython 3.12 Windows x86-32 Details for tsinfer-0.5.1-cp312-cp312-win32.whl
tsinfer-0.5.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.17+ x86-64, Linux glibc 2.28+ x86-64 Details for tsinfer-0.5.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
tsinfer-0.5.1-cp312-cp312-macosx_11_0_arm64.whl CPython 3.12 CPython 3.12 macOS 11.0+ ARM64 Details for tsinfer-0.5.1-cp312-cp312-macosx_11_0_arm64.whl
tsinfer-0.5.1-cp312-cp312-macosx_10_13_x86_64.whl CPython 3.12 CPython 3.12 macOS 10.13+ x86-64 Details for tsinfer-0.5.1-cp312-cp312-macosx_10_13_x86_64.whl
tsinfer-0.5.1-cp311-cp311-win_amd64.whl CPython 3.11 CPython 3.11 Windows x86-64 Details for tsinfer-0.5.1-cp311-cp311-win_amd64.whl
tsinfer-0.5.1-cp311-cp311-win32.whl CPython 3.11 CPython 3.11 Windows x86-32 Details for tsinfer-0.5.1-cp311-cp311-win32.whl
tsinfer-0.5.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.17+ x86-64, Linux glibc 2.28+ x86-64 Details for tsinfer-0.5.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
tsinfer-0.5.1-cp311-cp311-macosx_11_0_arm64.whl CPython 3.11 CPython 3.11 macOS 11.0+ ARM64 Details for tsinfer-0.5.1-cp311-cp311-macosx_11_0_arm64.whl
tsinfer-0.5.1-cp311-cp311-macosx_10_9_x86_64.whl CPython 3.11 CPython 3.11 macOS 10.9+ x86-64 Details for tsinfer-0.5.1-cp311-cp311-macosx_10_9_x86_64.whl

Total release size: 3.6 MB

Release files / tsinfer-0.5.1.tar.gz

Download URL tsinfer-0.5.1.tar.gz
Size 889.8 kB
Tags Source
SHA-256 checksum
How to use checksums
c6c6b1b658ed24a08eb8017a92b67e5bef07009b439c78eab294e144faf2df30
BLAKE2b-256 checksum
How to use checksums
0a291540bb7c26c7a0bbc08a2d79869ebe7fea7adbd94dfaab5da229dee1e2e3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp313-cp313-win_amd64.whl

Download URL tsinfer-0.5.1-cp313-cp313-win_amd64.whl
Size 143.0 kB
Tags CPython 3.13 Windows x86-64
SHA-256 checksum
How to use checksums
f2f05fc5d91b0ac6601cbb7e0fe72d282aa3a91a021140dec2759292fbcb1c4c
BLAKE2b-256 checksum
How to use checksums
c263a8aced1d9d273a7a49c8dff602d6376c28d9db579c3dc8b2841dda7652c4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp313-cp313-win32.whl

Download URL tsinfer-0.5.1-cp313-cp313-win32.whl
Size 137.7 kB
Tags CPython 3.13 Windows x86-32
SHA-256 checksum
How to use checksums
fe6bdc633366a0738f8cf244fec906bf40b4e454c2bb627147817972b33a17f6
BLAKE2b-256 checksum
How to use checksums
09e1c31629df71412004aa042e81f2821f96ee10f7e5b1fcfc9490cb9a86f360
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL tsinfer-0.5.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 307.4 kB
Tags CPython 3.13 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
5f0331bb8ce2b451b1741248c221e830f19b9cdae87e54d070477c0dedb392a2
BLAKE2b-256 checksum
How to use checksums
f331e9f6d5bf77d27d0312e927015d7a4f3ea0bf39a46084571cfce1db9651f7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp313-cp313-macosx_11_0_arm64.whl

Download URL tsinfer-0.5.1-cp313-cp313-macosx_11_0_arm64.whl
Size 162.3 kB
Tags CPython 3.13 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
919802809179850534640806c25f804e6565439f13371628b8d4d0f34ccccbf2
BLAKE2b-256 checksum
How to use checksums
fc733520cd0e53c58f19a0e1c451e16f7ea5adc627e46340616ce36cc7966c86
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp313-cp313-macosx_10_13_x86_64.whl

Download URL tsinfer-0.5.1-cp313-cp313-macosx_10_13_x86_64.whl
Size 165.5 kB
Tags CPython 3.13 macOS 10.13+ x86-64
SHA-256 checksum
How to use checksums
9befdee01fefb92d91138d0b8ab49650a81542b7289010b0971fbee8559efce8
BLAKE2b-256 checksum
How to use checksums
6b94d0cda70275c06263c5b129769e7c3c9a49e60880addc435ba364053442f0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp312-cp312-win_amd64.whl

Download URL tsinfer-0.5.1-cp312-cp312-win_amd64.whl
Size 142.8 kB
Tags CPython 3.12 Windows x86-64
SHA-256 checksum
How to use checksums
90490041882f31c7ed7334230430da14cc426edbfae28f2ebc88c36c428cae0e
BLAKE2b-256 checksum
How to use checksums
ff9de14f481f0b93150b346d66446d8834abdbe0fc9d10b690db336b5756c76d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp312-cp312-win32.whl

Download URL tsinfer-0.5.1-cp312-cp312-win32.whl
Size 137.6 kB
Tags CPython 3.12 Windows x86-32
SHA-256 checksum
How to use checksums
327999e205e670ee342158a518b493edbc4d35b86cc81cf65dab0253915b9cfe
BLAKE2b-256 checksum
How to use checksums
1f75147414f17ded7127ea189e07d62dade0a018f196c9a05bc181c15598e67e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL tsinfer-0.5.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 306.9 kB
Tags CPython 3.12 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
e0def60a001897c99ab85b101d343009b32f46b11905e288682d1717954ae36a
BLAKE2b-256 checksum
How to use checksums
e4271ffa21b39ec3d66f27e0986ca5b78f1b012b8f93ab26046fbcc631ef68fc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp312-cp312-macosx_11_0_arm64.whl

Download URL tsinfer-0.5.1-cp312-cp312-macosx_11_0_arm64.whl
Size 162.1 kB
Tags CPython 3.12 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
9b4f3724ffaf248cdff0200bf99572b2cac40b5d6decb1c6b77083e4537b00c9
BLAKE2b-256 checksum
How to use checksums
0fdba296904680a9326c3ddad066088b6a095a9163573ff092658c5c52cf311f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp312-cp312-macosx_10_13_x86_64.whl

Download URL tsinfer-0.5.1-cp312-cp312-macosx_10_13_x86_64.whl
Size 165.2 kB
Tags CPython 3.12 macOS 10.13+ x86-64
SHA-256 checksum
How to use checksums
67d3258ce7392f07a2d202cc282e64120badb4fc13a50bf4962ddea3fb74f9bd
BLAKE2b-256 checksum
How to use checksums
a823c955d0d4896ad46d16fbeb901dca3c9a758af84a944166af20dd525ce617
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp311-cp311-win_amd64.whl

Download URL tsinfer-0.5.1-cp311-cp311-win_amd64.whl
Size 142.7 kB
Tags CPython 3.11 Windows x86-64
SHA-256 checksum
How to use checksums
61d2705fb0861d7f9a455ee9e0ab95275ab8c0b41b2ae7270f2c3f3aed85771c
BLAKE2b-256 checksum
How to use checksums
2516176e55d9babe6c58b67bafd9d0ee6450ce6c5d28406525bebddd5d5084f4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp311-cp311-win32.whl

Download URL tsinfer-0.5.1-cp311-cp311-win32.whl
Size 137.4 kB
Tags CPython 3.11 Windows x86-32
SHA-256 checksum
How to use checksums
1b5c6cb6b983d9639aefab9c0f71df2cb40e09de54938a903b02c28247daad4d
BLAKE2b-256 checksum
How to use checksums
9ac551250c24a2367c21850a38a036ac7dc04fa2e9bbfbf98672a3ea2c3d2f59
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL tsinfer-0.5.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 303.5 kB
Tags CPython 3.11 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
68da9ef192a0ce8ee853b889dd70f6fbd1f097b3dbf93088dffdfa036907782f
BLAKE2b-256 checksum
How to use checksums
5f4b5c2ffa94d3f0df4ac167f6ab85c1b854a19faedbf617118cbaff47ddbbd4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp311-cp311-macosx_11_0_arm64.whl

Download URL tsinfer-0.5.1-cp311-cp311-macosx_11_0_arm64.whl
Size 162.0 kB
Tags CPython 3.11 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
66fdd65627334f4642e87ef1ebc7144d5f76ae8b9af103f3641c61dd08de27b5
BLAKE2b-256 checksum
How to use checksums
25cfebc6523b2e816556185569c4096fb85c9659e06660da532271aa799e595b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Release files / tsinfer-0.5.1-cp311-cp311-macosx_10_9_x86_64.whl

Download URL tsinfer-0.5.1-cp311-cp311-macosx_10_9_x86_64.whl
Size 164.9 kB
Tags CPython 3.11 macOS 10.9+ x86-64
SHA-256 checksum
How to use checksums
d77241881c191525026fec53daeaefd28aa86c171bf91a9fe5c1be385503d0ed
BLAKE2b-256 checksum
How to use checksums
d949bd447115b9d4bda2de09cd3723be9b9c686fa4ca47ade2ffed83d4390e22
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Mar 5, 2026.

Transparency log

Security for tsinfer 0.5.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 16 files in this release have been uploaded with provenance metadata.

Select from 16 files

Attestation for tsinfer-0.5.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 Mar 5, 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