Skip to content

[NGT] add reconstructable sim vertices validation for HLT full vertices#49900

Merged
cmsbuild merged 1 commit intocms-sw:masterfrom
cms-ngt-hlt:mm_reconstructableSimFullVertices
Jan 28, 2026
Merged

[NGT] add reconstructable sim vertices validation for HLT full vertices#49900
cmsbuild merged 1 commit intocms-sw:masterfrom
cms-ngt-hlt:mm_reconstructableSimFullVertices

Conversation

@mmusich
Copy link
Copy Markdown
Contributor

@mmusich mmusich commented Jan 22, 2026

PR description:

Title say it all, this is a follow-up to #49609.
In that PR we introduced the concept of "reconstructable" sim-vertex, allowing the validation module to optionally focus only on sim vertices that meet reconstruction criteria (≥3 associated tracks).
We extend that validation flavor also to the "full" (offline-like, i.e. DA-driven) vertices.

PR validation:

Run the following script:

#!/bin/bash -ex

cmsDriver.py step2 --step L1P2GT,HLT:NGTScouting,VALIDATION:@hltValidation \
 --procModifier phase2LegacyPixelTracks \
 --conditions auto:phase2_realistic_T33 --processName HLTX \
 --datatier DQMIO --eventcontent DQMIO \
 --geometry ExtendedRun4D110 --customise SLHCUpgradeSimulations/Configuration/aging.customise_aging_1000 --era Phase2C17I13M9 \
 --inputCommands='keep *, drop *_hlt*_*_HLT, drop triggerTriggerFilterObjectWithRefs_l1t*_*_HLT' \
 --filein file:/eos/cms/store/relval/CMSSW_16_0_0_pre4/RelValTTbar_14TeV/GEN-SIM-DIGI-RAW/PU_150X_mcRun4_realistic_v1_STD_Run4D110_PU-v2/2580000/037118f1-472e-4647-88fc-b0211e52df6f.root \
 --fileout file:step2.root -n -1 --nThreads 0

cmsDriver.py step3 -s HARVESTING:@hltValidation --filetype DQM \
 --conditions auto:phase2_realistic_T33 --geometry ExtendedRun4D110 \
 --scenario pp --mc --era Phase2C17I13M9 \
 -n -1 --filein file:step2.root

and checked that the output DQM file is sensible.

If this PR is a backport please specify the original PR and why you need to backport that PR. If this PR will be backported please specify to which release cycle the backport is meant for:

Not a backport, we will backport to CMSSW_16_0_X for convenience.

@mmusich
Copy link
Copy Markdown
Contributor Author

mmusich commented Jan 22, 2026

type ngt

@cmsbuild
Copy link
Copy Markdown
Contributor

cmsbuild commented Jan 22, 2026

cms-bot internal usage

@mmusich
Copy link
Copy Markdown
Contributor Author

mmusich commented Jan 22, 2026

test parameters:

  • workflows = ph2_hlt

@mmusich
Copy link
Copy Markdown
Contributor Author

mmusich commented Jan 22, 2026

@cmsbuild, please test

@cmsbuild
Copy link
Copy Markdown
Contributor

@cmsbuild
Copy link
Copy Markdown
Contributor

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

It involves the following packages:

  • Validation/RecoVertex (dqm)

@ctarricone, @gabrielmscampos, @nothingface0, @rseidita can you please review it and eventually sign? Thanks.
@GiacomoSguazzoni, @VinInn, @VourMa, @dgulhan, @elusian, @felicepantaleo, @missirol, @mmasciov, @mmusich, @mtosi, @rovere, @venturia 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

@cmsbuild
Copy link
Copy Markdown
Contributor

+1

Size: This PR adds an extra 20KB to repository
Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-a60eb0/50819/summary.html
COMMIT: 84f5b3b
CMSSW: CMSSW_16_1_X_2026-01-22-1100/el8_amd64_gcc13
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week1/cms-sw/cmssw/49900/50819/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

  • You potentially added 55 lines to the logs
  • ROOTFileChecks: Some differences in event products or their sizes found
  • Reco comparison results: 8 differences found in the comparisons
  • DQMHistoTests: Total files compared: 73
  • DQMHistoTests: Total histograms compared: 4814076
  • DQMHistoTests: Total failures: 363
  • DQMHistoTests: Total nulls: 2
  • DQMHistoTests: Total successes: 4813691
  • DQMHistoTests: Total skipped: 20
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 84949.80799999999 KiB( 72 files compared)
  • DQMHistoSizes: changed ( 18434.0,... ): 2794.853 KiB HLT/Vertexing
  • DQMHistoSizes: changed ( 18434.0,... ): 0.004 KiB MessageLogger/Errors
  • DQMHistoSizes: changed ( 18434.0,... ): 0.004 KiB MessageLogger/Warnings
  • DQMHistoSizes: changed ( 34434.0,... ): 3306.669 KiB HLT/Vertexing
  • Checked 293 log files, 250 edm output root files, 73 DQM output files
  • TriggerResults: found differences in 25 / 71 workflows

@gabrielmscampos
Copy link
Copy Markdown
Member

Just to confirm, since you already mentioned that the output DQM is sensible to this PR, are the differences in the 34434.X workflows due to the changes in ValidationWRTReconstructableSim the ones you expect?

@mmusich
Copy link
Copy Markdown
Contributor Author

mmusich commented Jan 23, 2026

are the differences in the 34434.X workflows due to the changes in ValidationWRTReconstructableSim the ones you expect?

indeed - not entirely. I was expecting only additions (those look good), but no changes to the existing ME-s. There might be some overwriting going on, I'll have to take a look.

@mmusich
Copy link
Copy Markdown
Contributor Author

mmusich commented Jan 23, 2026

There might be some overwriting going on, I'll have to take a look.

I noticed a small issue in the way we use PrimaryVertexAnalyzer4PUSlimmed.
Since the pure GEN histograms are booked directly in the "root folder" (here), when we have multiple instances of the same module using the same root folder (e.g. here, cloned without renaming here and here), they get filled multiple times in the event loop with exactly the same content. As a result, the shape is correct, but the integral is multiplied (e.g. ×2).

Conceptually, it still make sense for these histograms to live under
"HLT/Vertexing/ValidationWRTsim" or "HLT/Vertexing/ValidationWRTReconstructableSim" (for both full and pixel vertices). One option would be to book them inside a "Simulation" subfolder within the reco flavour (full and pixel vertices) directories.
The content would still be duplicated, but I don’t see a clean way to fill them only once without extracting the GEN-only code into a dedicated module.

@cmsbuild
Copy link
Copy Markdown
Contributor

@cmsbuild
Copy link
Copy Markdown
Contributor

Pull request #49900 was updated. @cmsbuild, @ctarricone, @gabrielmscampos, @nothingface0, @rseidita can you please check and sign again.

@mmusich
Copy link
Copy Markdown
Contributor Author

mmusich commented Jan 27, 2026

One option would be to book them inside a "Simulation" subfolder within the reco flavour (full and pixel vertices) directories.
The content would still be duplicated, but I don’t see a clean way to fill them only once without extracting the GEN-only code into a dedicated module.

actually there is an easier (and better) way, which it to profit of the existing flag do_generic_sim_plots which governs if those plots are booked (and filled) here:

i.setCurrentFolder(root_folder_);
if (do_generic_sim_plots_) {
mes_["root_folder"]["GenVtx_vs_BX"] =
i.book2D("GenVtx_vs_BX", "GenVtx_vs_BX", 16, -12.5, 3.5, nPUbins_, 0., double(nPUbins_));

in the last push I switched that parameter off for hltPVanalysisReconstructable such that we only take the ones already filled by hltPixelPVanalysisReconstructable.
In the meanwhile, while running a more thorough validation on Run-3 HLT, using the following script:

#!/bin/bash -ex

cmsDriver.py step2 -s HLT:GRun,VALIDATION::hltMultiTrackValidation+hltMultiPVValidation \
         --conditions auto:phase1_2025_realistic \
         --datatier DQMIO \
         -n 1000 \
         --eventcontent DQMIO \
         --geometry DB:Extended \
         --era Run3_2025 \
         --filein file:/eos/cms/store/relval/CMSSW_16_0_0_pre4/RelValTTbar_14TeV/GEN-SIM-DIGI-RAW/PU_151X_mcRun3_2025_realistic_v4_STD_2025_PU-v1/2580000/3c4ad5b7-7dfb-4f20-a8c6-8c990778728e.root \
         --fileout file:step2.root \
         --nThreads 24 \
         --process HLTX \
         --inputCommands='keep *, drop *_hlt*_*_HLT, drop triggerTriggerFilterObjectWithRefs_l1t*_*_HLT' \
         > step2.log  2>&1

cmsDriver.py step3 -s HARVESTING:postProcessorHLTtrackingSequence+postProcessorHLTvertexing+postProcessorHLTvertexingReconstructableSim \
         --conditions auto:phase1_2025_realistic  \
         --mc \
         --geometry DB:Extended \
         --scenario pp \
         --filetype DQM \
         --era Run3_2025 \
         -n 1000  \
         --filein file:step2.root \
         --fileout file:step3.root > step3.log  2>&1

I spotted a bug which I corrected in the last push, for the record the change was:

diff --git a/Validation/RecoVertex/python/HLTmultiPVvalidator_cff.py b/Validation/RecoVertex/python/HLTmultiPVvalidator_cff.py
index 70a987ace34..9e01248ec76 100644
--- a/Validation/RecoVertex/python/HLTmultiPVvalidator_cff.py
+++ b/Validation/RecoVertex/python/HLTmultiPVvalidator_cff.py
@@ -76,7 +76,7 @@ hltPVanalysisReconstructable = hltMultiPVanalysis.clone(
     use_reconstructable_simvertices = True,
     reco_tracks_for_reconstructable_simvertices = 1, #inclusive, below or equal discard sim vertex.
     root_folder           = "HLT/Vertexing/ValidationWRTReconstructableSim",
-    trackAssociatorMap    = "trackingParticleRecoTrackAsssociation",
+    trackAssociatorMap    = "tpToHLTpfMuonMergingTrackAssociation",
     vertexAssociator      = "vertexAssociatorByPositionAndTracks4pfMuonMergingTracks",
     vertexRecoCollections = (
         "hltVerticesPFFilter",

@mmusich
Copy link
Copy Markdown
Contributor Author

mmusich commented Jan 27, 2026

@cmsbuild, please test

@cmsbuild
Copy link
Copy Markdown
Contributor

+1

Size: This PR adds an extra 20KB to repository
Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-a60eb0/50935/summary.html
COMMIT: 42de667
CMSSW: CMSSW_16_1_X_2026-01-27-1100/el8_amd64_gcc13
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/49900/50935/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

  • You potentially removed 20 lines from the logs
  • Reco comparison results: 2 differences found in the comparisons
  • DQMHistoTests: Total files compared: 73
  • DQMHistoTests: Total histograms compared: 4814076
  • DQMHistoTests: Total failures: 3
  • DQMHistoTests: Total nulls: 3
  • DQMHistoTests: Total successes: 4814050
  • DQMHistoTests: Total skipped: 20
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 84949.808 KiB( 72 files compared)
  • DQMHistoSizes: changed ( 34434.7501,... ): 3306.669 KiB HLT/Vertexing
  • DQMHistoSizes: changed ( 18434.0,... ): 2794.853 KiB HLT/Vertexing
  • DQMHistoSizes: changed ( 18434.0,... ): 0.004 KiB MessageLogger/Errors
  • DQMHistoSizes: changed ( 18434.0,... ): 0.004 KiB MessageLogger/Warnings
  • Checked 293 log files, 250 edm output root files, 73 DQM output files
  • TriggerResults: found differences in 25 / 71 workflows

@mmusich
Copy link
Copy Markdown
Contributor Author

mmusich commented Jan 27, 2026

DQMHistoTests: Total failures: 3

now things should be correct. @cms-sw/dqm-l2 the PR is ready for your review.

@nothingface0
Copy link
Copy Markdown
Contributor

@mmusich regarding:

DQMHistoSizes: Histogram memory added: 84949.808 KiB( 72 files compared)

This won't pose a problem to T0 right? (Is it a different sequence to the one that we had discussed here?)

@mmusich
Copy link
Copy Markdown
Contributor Author

mmusich commented Jan 28, 2026

This won't pose a problem to T0 right?

@nothingface0 this PR concerns Validation (i.e. characterization of the reconstruction w.r.t Simulation quantities) not DQM (that monitors only reconstructed quantities). Thus this sequence will never run at Tier0 (alas we don't have SIM truth in real data :) )

@nothingface0
Copy link
Copy Markdown
Contributor

This won't pose a problem to T0 right?

@nothingface0 this PR concerns Validation (i.e. characterization of the reconstruction w.r.t Simulation quantities) not DQM (that monitors only reconstructed quantities). Thus this sequence will never run at Tier0 (alas we don't have SIM truth in real data :) )

Good to know, I would have never guessed!

@nothingface0
Copy link
Copy Markdown
Contributor

+dqm

@cmsbuild
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. @ftenchini, @mandrenguyen, @sextonkennedy (and backports should be raised in the release meeting by the corresponding L2)

@mandrenguyen
Copy link
Copy Markdown
Contributor

+1

@cmsbuild cmsbuild merged commit 79a3459 into cms-sw:master Jan 28, 2026
11 checks passed
@mmusich mmusich deleted the mm_reconstructableSimFullVertices branch January 28, 2026 10:15
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