Skip to content

perf: pool HMM (kofam/sulfur) via -T bit-score prefilter [HOLD until campaign done]#12

Draft
tpall wants to merge 4 commits into
devfrom
perf/search-bundling
Draft

perf: pool HMM (kofam/sulfur) via -T bit-score prefilter [HOLD until campaign done]#12
tpall wants to merge 4 commits into
devfrom
perf/search-bundling

Conversation

@tpall

@tpall tpall commented Jun 28, 2026

Copy link
Copy Markdown
Owner

⛔ HOLD — do not merge until the current eluring campaign finishes

The 3 finished cohorts (samples_65_74_new, samples_12_18_new, dengl2025) and the in-flight ones (chulenbayeva → wu_rampelli → sajased-aftekas → curated_metagenomic) all run on the -E per-genome path. Merging this changes HMM (kofam/sulfur) output (-E-T, +0.08% kofam), so it must wait until the campaign is done — then it becomes the default for the next campaign (everything -T-pooled, consistent from the start).

Why this PR exists

PR #11 was stacked on perf/search-bundling and merged into that branch after PR #10 had already merged perf/search-bundling → dev. So #11's HMM commits never reached dev. This PR brings them in: it's exactly the 4 commits perf/search-bundling is ahead of dev:

ad9a0a78 Merge pull request #11
0034dc9b docs: reword O()
c9665817 docs: -T bit-score validated
03f0f5d8 experiment: HMM pooling via -T

What it does

Adds HMM (kofam/sulfur) to --pool_searches by switching hmmsearch from the Z-dependent e-value prefilter to a Z-independent bit-score prefilter:

hmmsearch -T 10 --domT 10   (was: -E 1e-5)

hmm_parser already filters on per-profile bit-score thresholds, so -E was the only search-space-size-dependent step. 10 sits below kofam's lowest profile threshold (15.07), so nothing a real threshold would keep is pre-cut. Bit score is identical alone vs pooled, so pooled HMM == per-genome HMM.

Validation (extraves)

per-genome(-T) vs pooled-chunked(-T), all 5 DBs: RESULT: IDENTICAL (141270 rows; kofam fanned to 8 chunks). With this, the entire annotation path (mmseqs + HMM) pools byte-identically.

  • Drift vs -E: +63 kofam calls (~0.08%) — the bit-score-significant hits -E 1e-5 silently dropped (arguably a latent-bug fix).
  • Output size unchanged (final annotations same; only transient domtblout grows).
  • -Z/--domZ doesn't work for a multi-genome pool (one -Z can't match variable per-genome sizes).
  • Full record: docs/dev/search-bundling.md.

🤖 Generated with Claude Code

tpall and others added 4 commits June 28, 2026 09:36
On branch perf/hmm-pool-bitscore (experiment, NOT for PR #10). Re-enables
kofam/sulfur pooling + chunking (un-reverts 3457a80) and switches hmmsearch from
the e-value prefilter (-E, scales with search-space size Z) to a bit-score
prefilter (-T 10 --domT 10). Bit scores are Z-independent, so pooled multi-genome
hmmsearch reports the SAME hits as per-genome; hmm_parser still applies per-profile
bit-score thresholds. Floor 10 < lowest kofam threshold (15.07), so no real hit is
pre-cut.

Goal: validate per-genome(-T) == pooled(-T) on extraves (proves -T removes the
Z-dependence that made -E pooling churn ~5% of kofam calls). NB changes results vs
-E, so a future pipeline-wide decision, not mid-campaign.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…validated)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
perf: pool HMM (kofam/sulfur) via Z-independent bit-score prefilter (-T)
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.

1 participant