Skip to main content

Residue-level epitope prediction pipeline for peptide/protein workflows.

Project description

PepSeqPred logo

PyPI version Python versions License: GPL-3.0 API: Pretrained API: Artifact Path

PepSeqPred predicts residue-level epitope locations for protein sequences.

At A Glance

  • Pretrained Use bundled models with load_pretrained_predictor(...).
  • Artifact Use your own .pt or .json artifacts with load_predictor(...).
  • Output Get residue-aligned binary epitope masks via result.binary_mask.
  • Device Use device="auto" to select CUDA when available, otherwise CPU.

Install

pip install pepseqpred

Predict With A Bundled Pretrained Model

from pepseqpred import load_pretrained_predictor

protein_seq = "ACDEFGHIKLMNPQRSTVWY"

predictor = load_pretrained_predictor(model_id="default", device="auto")
result = predictor.predict_sequence(protein_seq, header="example_protein")

print(result.binary_mask)     # e.g. 000001110000...
print(result.n_epitopes)      # number of residues predicted as epitope
print(result.frac_epitope)    # fraction of residues predicted as epitope

To inspect available bundled models:

from pepseqpred import list_pretrained_models

for info in list_pretrained_models():
    print(info.model_id, info.aliases, info.is_default)

Predict From Your Own Artifact Path

Use this when you have your own trained PepSeqPred artifact:

  • single checkpoint: .pt
  • ensemble manifest: .json
from pepseqpred import load_predictor

predictor = load_predictor(
    model_artifact="path/to/ensemble_manifest.json",  # or path/to/model.pt
    device="auto"
)

result = predictor.predict_sequence("ACDEFGHIKLMNPQRSTVWY")
print(result.binary_mask)

FASTA I/O

results = predictor.predict_fasta("input.fasta")
predictor.write_fasta_predictions("input.fasta", "predicted_masks.fasta")

Notes

  • device="auto" uses CUDA if available, otherwise CPU.
  • result.binary_mask is aligned to the cleaned protein sequence.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pepseqpred-1.0.0.tar.gz (19.3 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pepseqpred-1.0.0-py3-none-any.whl (19.3 MB view details)

Uploaded Python 3

File details

Details for the file pepseqpred-1.0.0.tar.gz.

File metadata

  • Download URL: pepseqpred-1.0.0.tar.gz
  • Upload date:
  • Size: 19.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for pepseqpred-1.0.0.tar.gz
Algorithm Hash digest
SHA256 a9ebcfe17b78f73c2849bdf85b99c7a83f3e83fab7c736f1e1a0287e2b9f0f94
MD5 0ceb9cc465ec09f3d48de602b9e97fd3
BLAKE2b-256 55f751026a7d191d3532da38c55ef374a6669ab13c990b3b007be4f5e3b45bfc

See more details on using hashes here.

Provenance

The following attestation bundles were made for pepseqpred-1.0.0.tar.gz:

Publisher: publish.yml on LadnerLab/PepSeqPred

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pepseqpred-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: pepseqpred-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 19.3 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for pepseqpred-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ae33f0e2bc5eb5ec26dcd55ad6d4621497a89a7b8225d7ac48fa5f1a99552e46
MD5 a5599c501c36edef1e47cead7b0818cc
BLAKE2b-256 652cf22c9a8cc5c438afcba53ea8e85a1c2bb20af6800a660caed0d7c27889bd

See more details on using hashes here.

Provenance

The following attestation bundles were made for pepseqpred-1.0.0-py3-none-any.whl:

Publisher: publish.yml on LadnerLab/PepSeqPred

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page