Skip to content

RecoMTD/TrackExtender: extract MTDHitMatcher standalone class - #51550

Merged
cmsbuild merged 3 commits into
cms-sw:masterfrom
xabiercidvidal:mtd-pr3-hit-matcher
Aug 4, 2026
Merged

RecoMTD/TrackExtender: extract MTDHitMatcher standalone class#51550
cmsbuild merged 3 commits into
cms-sw:masterfrom
xabiercidvidal:mtd-pr3-hit-matcher

Conversation

@xabiercidvidal

Copy link
Copy Markdown
Contributor

PR description:

Continuation of the TrackExtenderWithMTD refactoring started in #51374.

Moves hit-matching logic out of TrackExtenderWithMTD and into a new standalone MTDHitMatcher class (analogous to TrackTransformer), exported as a library from RecoMTD/TrackExtender.

MTDHitMatcher owns the MeasurementEstimator, the TransientTrackingRecHit builder, and all chi²/bsTimeSpread configuration. It exposes:

matchBTL() — delegates to matchLayers() with allBTLLayers()
matchETL() — filters to same z-side, delegates to matchLayers(), sorts output innermost-first
matchLayers() (private) — the shared loop over find_hits_in_dets() and fillMatchingHits(); no logic duplication
The plugin config gains a nested "MTDHitMatcher" PSet (analogous to "TrackTransformer"), grouping: estimatorMaxChi2, estimatorMaxNSigma, btlChi2Cut, btlTimeChi2Cut, etlChi2Cut, etlTimeChi2Cut, bsTimeSpread, MTDRecHitBuilder.

TrackExtenderWithMTD::produce() now calls matcher_.matchBTL()/matchETL() with two lines each, making a planned intermediate BTL refit a one-line insertion between those two calls.

No logic changes.

PR validation:

PU200 RelMon (pr3 vs master+#51374, 827 MTD histograms, b2b KS t=0.99999): 827/827 passing (100%)

RelMon: https://cernbox.cern.ch/s/phGMV79uPHpJ5El
Overlay plots: https://cernbox.cern.ch/s/u96notA0FYngDv3

Move hit-matching logic out of TrackExtenderWithMTD and into a new
standalone MTDHitMatcher class (analogous to TrackTransformer), exported
as a library from RecoMTD/TrackExtender.

MTDHitMatcher owns the MeasurementEstimator, the TransientTrackingRecHit
builder, and all chi2/bsTimeSpread configuration. It exposes:
  matchBTL() -- delegates to matchLayers() with allBTLLayers()
  matchETL() -- filters to same z-side, delegates to matchLayers(),
                sorts output innermost-first
  matchLayers() (private) -- the shared loop over find_hits_in_dets()
                             and fillMatchingHits(); no logic duplication

The plugin config gains a nested "MTDHitMatcher" PSet (analogous to
"TrackTransformer"), grouping: estimatorMaxChi2, estimatorMaxNSigma,
btlChi2Cut, btlTimeChi2Cut, etlChi2Cut, etlTimeChi2Cut, bsTimeSpread,
MTDRecHitBuilder.

TrackExtenderWithMTD.produce() now calls matcher_.matchBTL/matchETL()
with two lines each, making the planned PR5 intermediate BTL refit a
one-line insertion between those two calls.

No logic changes.
@cmsbuild

cmsbuild commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

cms-bot internal usage

@cmsbuild

Copy link
Copy Markdown
Contributor

-code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-51550/50276

Code check has found code style and quality issues which could be resolved by applying following patch(s)

@cmsbuild

Copy link
Copy Markdown
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-51550/50277

@cmsbuild

Copy link
Copy Markdown
Contributor

A new Pull Request was created by @xabiercidvidal for master.

It involves the following packages:

  • RecoMTD/TrackExtender (reconstruction)

@Moanwar, @cmsbuild, @jfernan2, @mandrenguyen, @srimanob can you please review it and eventually sign? Thanks.
@fabiocos, @martinamalberti this is something you requested to watch as well.
@ftenchini, @mandrenguyen, @sextonkennedy you are the release manager for this.

cms-bot commands are listed here

@mmusich

mmusich commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

test parameters:

  • workflows = 34434.7522

@mmusich

mmusich commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

please test

@cmsbuild

Copy link
Copy Markdown
Contributor

-1

Failed Tests: RelVals
Size: This PR adds an extra 32KB to repository
Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-0cdbf4/54888/summary.html
COMMIT: 37960b2
CMSSW: CMSSW_20_1_X_2026-07-23-1100/el9_amd64_gcc13
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week1/cms-sw/cmssw/51550/54888/install.sh to create a dev area with all the needed externals and cmssw changes.

Failed RelVals

----- Begin Fatal Exception 23-Jul-2026 17:25:36 CEST-----------------------
An exception of category 'Configuration' occurred while
   [0] Constructing the EventProcessor
   [1] Validating configuration of module: class=TrackExtenderWithMTD label='hltTrackExtenderWithMTD'
Exception Message:
Illegal parameters found in configuration.  The parameters are named:
 'MTDRecHitBuilder'
 'bsTimeSpread'
 'btlChi2Cut'
 'btlTimeChi2Cut'
 'estimatorMaxChi2'
 'estimatorMaxNSigma'
 'etlChi2Cut'
 'etlTimeChi2Cut'
You could be trying to use parameter names that are not
allowed for this plugin, or they could be misspelled, or these parameters
need to be defined in the fillDescriptions() method of the plugin.
----- End Fatal Exception -------------------------------------------------

…cher PSet

Move estimatorMaxChi2, estimatorMaxNSigma, btlChi2Cut, btlTimeChi2Cut,
etlChi2Cut, etlTimeChi2Cut, bsTimeSpread and MTDRecHitBuilder into
the nested MTDHitMatcher PSet introduced in RecoMTD/TrackExtender.
@cmsbuild

Copy link
Copy Markdown
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-51550/50282

@cmsbuild

Copy link
Copy Markdown
Contributor

Pull request #51550 was updated. @Martin-Grunewald, @Moanwar, @cmsbuild, @jfernan2, @mandrenguyen, @mmusich, @srimanob can you please check and sign again.

@mmusich

mmusich commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

@cmsbuild, please test

@cmsbuild

Copy link
Copy Markdown
Contributor

+1

Size: This PR adds an extra 52KB to repository
Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-0cdbf4/54893/summary.html
COMMIT: dbe77c1
CMSSW: CMSSW_20_1_X_2026-07-23-2300/el9_amd64_gcc13
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week1/cms-sw/cmssw/51550/54893/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

  • No significant changes to the logs found
  • Reco comparison results: 5 differences found in the comparisons
  • DQMHistoTests: Total files compared: 46
  • DQMHistoTests: Total histograms compared: 3596822
  • DQMHistoTests: Total failures: 92
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 3596712
  • DQMHistoTests: Total skipped: 18
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 45 files compared)
  • Checked 198 log files, 165 edm output root files, 46 DQM output files
  • TriggerResults: found differences in 2 / 45 workflows

@mmusich

mmusich commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

@cmsbuild, please test

  • to avoid spurious changes in the trigger results

@cmsbuild

Copy link
Copy Markdown
Contributor

+1

Size: This PR adds an extra 16KB to repository
Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-0cdbf4/54938/summary.html
COMMIT: dbe77c1
CMSSW: CMSSW_20_1_X_2026-07-26-2300/el9_amd64_gcc13
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/51550/54938/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

  • You potentially added 1 lines to the logs
  • ROOTFileChecks: Some differences in event products or their sizes found
  • Reco comparison results: 0 differences found in the comparisons
  • DQMHistoTests: Total files compared: 46
  • DQMHistoTests: Total histograms compared: 3596822
  • DQMHistoTests: Total failures: 21
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 3596783
  • DQMHistoTests: Total skipped: 18
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 45 files compared)
  • Checked 198 log files, 165 edm output root files, 46 DQM output files
  • TriggerResults: no differences found

@mmusich

mmusich commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

+hlt

@Moanwar

Moanwar commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

+1

@cmsbuild

cmsbuild commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

This pull request is fully signed and it will be integrated in one of the next master IBs (tests are also fine). This pull request will now be reviewed by the release team before it's merged. @sextonkennedy, @ftenchini, @mandrenguyen (and backports should be raised in the release meeting by the corresponding L2)

@mandrenguyen

Copy link
Copy Markdown
Contributor

+1

@cmsbuild
cmsbuild merged commit 69f1d99 into cms-sw:master Aug 4, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants