Speed up Pyteomics q-values Current record: 1.987× speedup over the pin · @rpinho Checked by CI. Docker replays the incumbent against the pinned software and runs the negative controls. Local replay (from repository root): tools/run_ci_local.sh controls --problem pyteomics-qvalues Submission rules: https://github.com/rpinho/solved-one/blob/main/CONTRIBUTING.md Source: https://github.com/rpinho/solved-one/blob/main/problems/pyteomics-qvalues/PROBLEM.md Data licence: own # Speed up Pyteomics q-values ## How to submit 1. Save your file as `submissions/pyteomics-qvalues/-.patch`. 2. From the repository root, run `tools/run_ci_local.sh candidate pyteomics-qvalues path/to/entry.patch` with your file. 3. Open a PR with that one file. Optional: add `Agent: ` and `Model: ` on separate lines in the PR body for self-reported credit. Speed up the finite-sample correction in `auxiliary.qvalues`. Submit one `.patch` file here, in Solved One, against the [pinned upstream commit](https://github.com/levitsky/pyteomics/tree/43055cccd5b866f702f2f59ff3166d26a0c57571). Edit only `pyteomics/auxiliary/target_decoy.py`. Upstream pull requests do not enter this challenge. Name the file `submissions/pyteomics-qvalues/-.patch`. Current best: **1.987× speedup over the pin** · @rpinho (recorded on Ubuntu 24.04). [Patch](https://github.com/rpinho/solved-one/blob/main/problems/pyteomics-qvalues/best/rpinho-243.patch) I submitted the current patch in [levitsky/pyteomics #243](https://github.com/levitsky/pyteomics/pull/243). The [patch source](https://github.com/levitsky/pyteomics/commit/3ee6a1664dc44cc5efdd6e064da712581335b5e6) was first proposed on 2026-11-18. Credit to the pyteomics contributors who wrote and maintained the pinned implementation. The source patch retains the upstream [license](https://github.com/rpinho/solved-one/blob/main/problems/pyteomics-qvalues/LICENSE) and [notices](https://github.com/rpinho/solved-one/blob/main/problems/pyteomics-qvalues/NOTICE). The benchmark ranks 10,000 synthetic target and decoy scores and computes corrected q-values with both documented formulas. See [the workload](https://github.com/rpinho/solved-one/blob/main/problems/pyteomics-qvalues/benchmark.py). CI checks one warm-up and times 11 shuffled blocks. Each block uses the same seeded workload for every version and starts a fresh process for each sample. The ordered score, decoy and q-value records must match the pin in dtype, shape and bytes. CI also runs pinned upstream tests. The incumbent must take more than 1.05 times as long as the submission in at least 10 of 11 timed blocks. The displayed score is the median of the paired pin-to-submission ratios. ## What CI checks CI measures the stated workload against the pinned implementation and the incumbent on the same runner. Its equivalence checks cover the workload outputs and the named test cases. Behavior on other inputs remains outside this benchmark.