Skip to content

Add NetTCR dataframe input - #258

Merged
iskandr merged 1 commit into
masterfrom
agent/nettcr-dataframe-tcr-aliases
Jul 10, 2026
Merged

Add NetTCR dataframe input#258
iskandr merged 1 commit into
masterfrom
agent/nettcr-dataframe-tcr-aliases

Conversation

@iskandr

@iskandr iskandr commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Summary

Fixes #255.

Adds a DataFrame-based NetTCR.predict_dataframe(...) path that treats each input row as one (peptide, TCR) pair and builds TCR objects from canonical CDR columns or caller-provided cdr_cols mappings.

Also expands TCR.from_dict to accept case-insensitive a1..b3 / A1..B3 aliases and adds TCR.from_series for pandas row inputs.

Impact

Callers can score receptor tables without hand-building TCR objects per row, while the existing predict_dataframe(peptides, tcrs) cross-product API remains supported.

Validation

  • pytest tests/test_tcr.py tests/test_nettcr.py -q
  • ./lint.sh
  • ./test.sh (650 passed, 51 skipped, 2 xfailed)

Version

Bumped package version from 3.31.2 to 3.31.3.

@iskandr
iskandr marked this pull request as ready for review July 10, 2026 23:50
@iskandr
iskandr merged commit 8f325cc into master Jul 10, 2026
5 checks passed
@iskandr
iskandr deleted the agent/nettcr-dataframe-tcr-aliases branch July 10, 2026 23:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

NetTCR: add a DataFrame prediction entry point; TCR.from_dict should accept the a1/A1 short names

1 participant