Repository navigation
feat(extract): a diaPASEF extraction gate (extract.gate_support_min, opt-in) - #206
Merged
RobbinBouwmeester merged 8 commits intoOct 17, 2026
Merged
Conversation
The window-mean gate was tuned on Astral and Q Exactive runs, where 0.6 keeps about 5% of the library. On the six HYE diaPASEF runs it keeps 33%, and a higher threshold buys speed with identifications: 0.75 kept 45% of the gate-0.6 candidates for -2.4% peptides and -5.6% ProteoBench ions at k = 3. extract.gate_support_min adds a second threshold under gate_mode = window_mean, on the window-mean score plus apex intensity and MS1 terms and, on spectra that carry 1/K0, three 1/K0 terms: the apex 1/K0 error against the calibrated prediction, the 1/K0 spread of the matched fragments at the apex, and the MS1-to-fragment 1/K0 difference. The 1/K0 weights were fitted by logistic regression on gate-time quantities of two runs (a standalone extract with the gate diagnostics, which now include the window-mean score), on targets only, so the score cannot learn to tell decoys from targets; at every cut decoys pass at the rate of unidentified targets. The apex 1/K0 evidence is computed once, before the gate when the gate reads it, and the output row reuses it. 0 (the default) changes nothing. Measured end to end without the 1/K0 terms (threshold 1.215, 42% of the candidates): 96,624 peptides and 86,323 ions against 96,154 and 84,912 for a window-mean threshold of 0.75 at 45%. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
RobbinBouwmeester
added this pull request to stack #207
October 17, 2026 08:02
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of a stack on #196; merge in order: 9 -> 10 -> 11 -> 12 -> 13 -> 14 -> 15 -> 16 -> 17. Measured on the six ProteoBench HYE diaPASEF runs (60 min, timsTOF SCP) on a 128-core host at 120 threads, NN seed 0,
MUMDIA_CACHE_DIR=off; docs/35_diapasef.md section 16 has the details.Summary
The window-mean gate keeps about 5% of the library on Astral but 33% on these diaPASEF runs, and a higher threshold trades identifications for time.
extract.gate_support_minadds a second threshold on the window-mean score plus apex intensity, MS1 and, on spectra that carry 1/K0, three 1/K0 terms (apex 1/K0 error, 1/K0 spread of the matched fragments, MS1-to-fragment 1/K0 difference). Weights were fitted on gate-time quantities of two runs, on targets only; at every cut decoys pass at the rate of unidentified targets. The gate diagnostics now carry the window-mean score.Opt-in. E. coli entrapment and the 5 min HYE set at 0.845 and 0.82 are running; results will be added here.
Checks
cargo fmt --check,cargo clippy --workspace --all-targets -D warnings,cargo test --workspace,ci/gen_config_reference.py --check,ci/check_doc_refs.py,python -m compileall scripts.🤖 Generated with Claude Code