dwell templates require a TSV column literally named 'aa'

Aperta
#147 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
55/100
Tipo di issue
Refactoring
Chiarezza
Abbastanza chiara
Stato di attività
Tranquilla
Stack tecnologico
python

Direzione di ricerca

The hard-coded aa column is read in src/leech/dataset.py around line 102, where aa_list is built from df["aa"]. The same table is consumed from the --dwell-template-table option in cli.py (lines 642-647, help text at 646) and from inference/bundle.py (lines 313-326). Start by reading the dataset loader, then make it accept a class column while still accepting aa as a deprecated alias. Done when a table with a class column trains and runs inference, an aa table still works, and the help text no longer says 20 channels.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

enhancement

Found during the generalization audit (#125). Not currently listed there.

Problem

The dwell-template feature is generic in shape — per-class expected-dwell ratio channels — but requires a TSV column named literally aa:

https://github.com/rnabioco/leech/blob/main/src/leech/dataset.py#L102

df = pl.read_csv(table_path, separator="\t")
aa_list = sorted(df["aa"].unique().to_list())

Reached from both training (--dwell-template-table, cli.py:642-647) and bundle inference (inference/bundle.py:313-326). A user with per-barcode or per-modification expected-dwell profiles must name their column aa.

The CLI help at cli.py:646 is also wrong on a second count: it says "20-channel template features", but the channel count is derived from the table (n_aa), not fixed at 20.

Suggested fix

Accept a class (or group) column, keeping aa as a deprecated alias so existing tables keep working. Rename the locals aa_list / aa_to_idx / aa_order and the attribute _template_aa_order accordingly, and reword the help to "one ratio channel per class in the table".

Lingua principale
Python
Stelle
0
Fork
0
Merge medio
11h 17m
PR unite (30g)
23

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di rnabioco/leech

Tutte le issue di rnabioco/leech

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.