Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update SiStripLorentzAnglePCLHarvester to avoid writing useless payloads and more control plots #43962

Merged

Conversation

mmusich
Copy link
Contributor

@mmusich mmusich commented Feb 14, 2024

PR description:

With the restart of the 2024 cosmic data-taking operations, I noticed that the SiStripLorentzAngle PCL workflow is uploading a payload essentially for every run (see conditions uploader logs), even if the Strip Tracker is not joining the data-taking. This happens because, by default, if no new measurement is available the producer inserts in the database a new IoV copying the values of the currently used payload (see payloads in SiStripLorentzAngle_byPCL_v0_prompt).
I change this behavior such that it doesn't write out a new payload if there isn't at least a new measurement from one of the partitions. In addition I add some control plots in the SiStripLorentzAnglePCLHarvester module to display the output Lorentz Angle payload values per layer and module type (if there's a successful measurement) and the diff w.r.t. the one used in input.

PR validation:

Run both with 3.8T run with data from the Strip Tracker via:

cmsDriver.py stepHarvest -s ALCAHARVEST:SiStripLA \
	     --conditions 140X_dataRun3_Express_v2 \
	     --scenario cosmics \
	     --data \
	     --era Run3_2023 \
	     -n -1 \
	     --dasquery='file dataset=/StreamExpressCosmics/Run2023F-PromptCalibProdSiStripLA-Express-v1/ALCAPROMPT run=373245'

and with 0T data without Tracker (from a recent run 376727) via:

cmsDriver.yp stepHarvest2024 -s ALCAHARVEST:SiStripLA \
	     --conditions 140X_dataRun3_Express_v2 \
	     --scenario cosmics \
	     --data \
	     --era Run3 \
	     -n -1 \
	     --dasquery='file dataset=/StreamExpressCosmics/Commissioning2024-PromptCalibProdSiStripLA-Express-v1/ALCAPROMPT run=376727'

and obtained sensible results. In particular the second test doesn't produce an output payload, while in the first the following plot was produced:

Value Diff [%]
Screenshot from 2024-02-14 13-41-33 Screenshot from 2024-02-14 13-44-01

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, but will backport it to CMSSW_14_0_X (possibly 13_3_X) for 2024 data-taking operations.

@cmsbuild
Copy link
Contributor

cmsbuild commented Feb 14, 2024

cms-bot internal usage

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-43962/38855

  • This PR adds an extra 20KB to repository

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @mmusich (Marco Musich) for master.

It involves the following packages:

  • CalibTracker/SiStripLorentzAngle (alca)

@consuegs, @perrotta, @saumyaphor4252, @cmsbuild can you please review it and eventually sign? Thanks.
@rchatter, @argiro, @robervalwalsh, @ReyerBand, @echabert, @thomreis, @mmusich, @yuanchao, @wang0jin, @tocheng, @rsreds, @gbenelli this is something you requested to watch as well.
@rappoccio, @antoniovilela, @sextonkennedy you are the release manager for this.

cms-bot commands are listed here

@mmusich
Copy link
Contributor Author

mmusich commented Feb 14, 2024

type bug-fix

@mmusich
Copy link
Contributor Author

mmusich commented Feb 14, 2024

@cmsbuild, please test

for (const auto& loc : iHists_.moduleLocationType_) {
if (debug_) {
edm::LogInfo(moduleDescription().moduleName()) << "modId: " << loc.first << " " << loc.second;
}

if (!(loc.second).empty()) {
if (!(loc.second).empty() && theMagField_ != 0.f) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

notice that without this we're writing payloads full of nan-s.

@cmsbuild
Copy link
Contributor

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-354e55/37453/summary.html
COMMIT: e9bb0e1
CMSSW: CMSSW_14_1_X_2024-02-13-2300/el8_amd64_gcc12
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/43962/37453/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

@mmusich
Copy link
Contributor Author

mmusich commented Feb 15, 2024

@cms-sw/alca-l2 do you have comments? Would be nice to get this integrated and backported as soon as possible and propagated to Tier0.

@saumyaphor4252
Copy link
Contributor

+alca

  • clean tests
  • Technical PR to remove useless upload of the same payload multiple times
  • Final check of the uploaded payloads in T0 replay

@cmsbuild
Copy link
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, @antoniovilela, @rappoccio (and backports should be raised in the release meeting by the corresponding L2)

// Check if the delta is different from zero
// if none of the locations has a non-zero diff
// will not write out the payload.
if (deltaMuHoverMuH != 0.f) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This works when inputLA == 0.f, when L381 assures that deltaMuHoverMuH == 0.f
Due to rounding approximations, it may not work when inputLA = outputLA and deltaMuHoverMuH is computed from their difference

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

everything is in floating point single precision. I don't think it's a concern.

@antoniovilela
Copy link
Contributor

+1

@cmsbuild cmsbuild merged commit 2aca893 into cms-sw:master Feb 18, 2024
11 checks passed
@mmusich mmusich deleted the mm_dev_updates_SiStripLorentzAnglePCLHarvester branch February 18, 2024 20:54
@mmusich mmusich restored the mm_dev_updates_SiStripLorentzAnglePCLHarvester branch February 19, 2024 09:37
@mmusich mmusich deleted the mm_dev_updates_SiStripLorentzAnglePCLHarvester branch February 20, 2024 15:14
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