Skip to content

metrics: split package + stacking decisions hardening#122

Open
FIrgolitsch wants to merge 5 commits into
pr-r-allen-followupsfrom
pr-s-metrics-stacking
Open

metrics: split package + stacking decisions hardening#122
FIrgolitsch wants to merge 5 commits into
pr-r-allen-followupsfrom
pr-s-metrics-stacking

Conversation

@FIrgolitsch

@FIrgolitsch FIrgolitsch commented May 20, 2026

Copy link
Copy Markdown
Contributor

Stacked PR 19/22 — review order: #115#97#98#99#100#101#108#106#107#87#116#110#111#40#112#113#117#118#120#121#122#123#124#125

Base: pr-r-allen-followups. Retargets to main as upstream PRs merge.


Metrics package split + stacking decisions hardening

Stacked on pr-r-allen-followups. Refactors the metrics package and tightens the stacking-decisions CSV.

Commits

  • metrics collectors silent — collectors no longer print to stdout; output is structured.
  • split metrics package — splits linumpy.metrics into core / aggregate / collectors submodules.
  • report sticky nav — sticky nav header in the diagnostics HTML report.
  • metrics add_params helpers — reduces collector boilerplate via add_params and finalize helpers.
  • stack Z-overlap fallback (2c37fce0) — preserve the measured Z-overlap correlation when falling back on min_corr; surface it via a new correlation_fallback value in the overlap_source column and a dedicated correlation_fallback_used flag (instead of zeroing the correlation, which was indistinguishable from a real zero-NCC match).

Docs gaps

correlation_fallback is not yet documented in docs/PIPELINE_OVERVIEW.md / docs/NEXTFLOW_WORKFLOWS.md; follow-up.

Previously the correlation-fallback branch overwrote the measured NCC
with 0.0, making it indistinguishable from a true zero-correlation match
and impossible to derive a sensible `z_overlap_min_corr` from
stacking_decisions.csv -- every fallback row reported 0.0 regardless of
how close the actual measurement was to the threshold.

The fallback now keeps the measured correlation and reports
`overlap_source = 'correlation_fallback'` (plus a new
`correlation_fallback_used` z-match flag) so QC can tell which pairs
were trusted vs. demoted to the slicing-interval estimate while still
seeing the real NCC distribution.  Manually aligned slices are already
trusted via the registration branch and do not enter this code path.
This was referenced May 20, 2026
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