Skip to main content

JRIF

Peptide retention time (RT) and ion mobility (IM) prediction.

pip install jrif

Models

name predicts chemistry
rt_lf retention time label-free
rt_psmtag retention time PSMtag
im_psmtag ion mobility PSMtag

Weights are bundled with the package.

Features

  • Calibrate a model to your experiment using your identified peptides
  • Predict RT/IM for a full spectral library, output in your experiment's units
  • New modifications in your data are handled automatically
  • Runs on GPU when available (CUDA or Apple), otherwise CPU

Usage

Calibrate on your IDs, then predict your library:

import pandas as pd
from jrif import RTPredictor
from jrif.checkpoints import checkpoint_path

ids = pd.read_csv("psm_ids.tsv", sep="\t")      # columns: seq, rt
lib = pd.read_csv("library.tsv", sep="\t")      # column:  seq

p = RTPredictor.from_checkpoint(checkpoint_path("rt_psmtag"))
p.calibrate(ids)
lib["pred_rt"] = p.predict(lib)

Ion mobility (needs a charge column):

from jrif import IMPredictor

m = IMPredictor.from_checkpoint(checkpoint_path("im_psmtag"))
m.calibrate(ids)                                # columns: seq, charge, im
lib["pred_im"] = m.predict(lib)                 # columns: seq, charge

Sequence format: residues, with modifications as delta masses (S[+79.9663], C[+57.0215]) or UniMod (S(UniMod:21)). N-terminal modifications are a leading n[+mass], C-terminal ones a trailing c[+mass]. A bare C is unmodified cysteine. Masses match at the precision you write them, so S[80] uses the model's S[+79.9663]. The older spellings C[160], M[147], K[308] and .[308] are also accepted.

Modifications the model has never seen (e.g. S[80]) don't need any setup: calibrate() adds new tokens to the vocabulary and learns them from your IDs automatically.

Save and reload a calibrated model:

p.save("my_experiment.pt")
p = RTPredictor.from_checkpoint("my_experiment.pt")

Training new base models (maintainers)

uv run jrif-train-label-free --data-path <library.tsv>
uv run jrif-train-psmtag    --data-path <library.tsv | report-lib.parquet>

Metadata

Release files for jrif 0.2.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 jrif 0.2.0
File Size Uploaded Provenance Actions
jrif-0.2.0.tar.gz 1.9 MB With provenance Details for jrif-0.2.0.tar.gz

Built distribution (wheel)

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

Total release size: 3.8 MB

Release files / jrif-0.2.0.tar.gz

Download URL jrif-0.2.0.tar.gz
Size 1.9 MB
Tags Source
SHA-256 checksum
How to use checksums
0b4fc1c3ddab57060cd61f1424042a7142547e6beb379a2a3aedadbf8453ee06
BLAKE2b-256 checksum
How to use checksums
9e14d7d09287880b5292ad2800b455314542072c3e8a11e1c34939b3a79fd551
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 29, 2026.

Transparency log

Release files / jrif-0.2.0-py3-none-any.whl

Download URL jrif-0.2.0-py3-none-any.whl
Size 1.9 MB
Tags Python 3
SHA-256 checksum
How to use checksums
7a18ea35e0f83d084be63d6036336b14b0e9c0e730672336c43c13be97e0d881
BLAKE2b-256 checksum
How to use checksums
04a10138b2100eb03d53c34ecf300e86b76f64e89cff98c738a6f934150c719a
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 29, 2026.

Transparency log

Security for jrif 0.2.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 jrif-0.2.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 29, 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