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

removal of TH1::StatOverflows calls in FastTimerService? #32343

Merged

Conversation

missirol
Copy link
Contributor

PR description:

I stumbled upon the fact that the calls to the static member function TH1::StatOverflows in the FastTimerService change some of the global TH1 settings, and can thus affect histograms produced by unrelated modules in the same job.

The PR suggests a change to avoid this, while keeping the outputs of the FastTimerService unchanged.

PR validation:

Verified that the mean/RMS of some of the FastTimerService outputs still include underflows and overflows after these updates (admittedly, a very thorough validation was not done).

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-32343/20173

  • This PR adds an extra 24KB to repository

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @missirol (Marino Missiroli) for master.

It involves the following packages:

HLTrigger/Timer

@Martin-Grunewald, @cmsbuild, @fwyzard can you please review it and eventually sign? Thanks.
@Martin-Grunewald this is something you requested to watch as well.
@silviodonato, @dpiparo, @qliphy you are the release manager for this.

cms-bot commands are listed here

@fwyzard
Copy link
Contributor

fwyzard commented Nov 30, 2020 via email

@fwyzard
Copy link
Contributor

fwyzard commented Nov 30, 2020 via email

@cmsbuild
Copy link
Contributor

cmsbuild commented Nov 30, 2020

The tests are being triggered in jenkins.

@cmsbuild
Copy link
Contributor

+1
Tested at: 8767f28
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-da4659/11184/summary.html
CMSSW: CMSSW_11_3_X_2020-11-30-1100
SCRAM_ARCH: slc7_amd64_gcc900

@cmsbuild
Copy link
Contributor

Comparison job queued.

@cmsbuild
Copy link
Contributor

Comparison is ready
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-da4659/11184/summary.html

Comparison Summary:

  • No significant changes to the logs found
  • Reco comparison results: 13 differences found in the comparisons
  • DQMHistoTests: Total files compared: 35
  • DQMHistoTests: Total histograms compared: 2529593
  • DQMHistoTests: Total failures: 37
  • DQMHistoTests: Total nulls: 1
  • DQMHistoTests: Total successes: 2529533
  • DQMHistoTests: Total skipped: 22
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.004 KiB( 34 files compared)
  • DQMHistoSizes: changed ( 312.0 ): 0.004 KiB MessageLogger/Warnings
  • Checked 148 log files, 34 edm output root files, 35 DQM output files

@Martin-Grunewald
Copy link
Contributor

+1

@cmsbuild
Copy link
Contributor

cmsbuild commented Dec 1, 2020

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. @silviodonato, @dpiparo, @qliphy (and backports should be raised in the release meeting by the corresponding L2)

@cmsbuild
Copy link
Contributor

cmsbuild commented Dec 1, 2020

Comparison is ready
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-da4659/11230/summary.html

Comparison Summary:

  • No significant changes to the logs found
  • Reco comparison results: 8 differences found in the comparisons
  • DQMHistoTests: Total files compared: 35
  • DQMHistoTests: Total histograms compared: 2529593
  • DQMHistoTests: Total failures: 33
  • DQMHistoTests: Total nulls: 1
  • DQMHistoTests: Total successes: 2529537
  • DQMHistoTests: Total skipped: 22
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: -0.004 KiB( 34 files compared)
  • DQMHistoSizes: changed ( 312.0 ): -0.004 KiB MessageLogger/Warnings
  • Checked 148 log files, 37 edm output root files, 35 DQM output files

@missirol
Copy link
Contributor Author

missirol commented Dec 1, 2020

The differences in 23234.0, 23434.999 and 28234.0 might indeed be caused by this update, since the bins of the relevant histograms seem to be filled with mean/RMS values (and the FastTimerService is used in those workflows).

One note: one might wonder why changes don't show up in other wfs as well (assuming FastTimerService is also run in some other wfs). One possibility (but this is speculation) is that such wfs include at least one module in which MonitorElement::setStatOverflows is called; even though that is a "per element" call, it still uses the static function TH1::StatOverflows, which affects other TH1s in the job; something not obvious that I thought was worth mentioning (maybe worth mentioning to DQM?).

@fwyzard
Copy link
Contributor

fwyzard commented Dec 1, 2020

One note: one might wonder why changes don't show up in other wfs as well (assuming FastTimerService is also run in some other wfs). One possibility (but this is speculation) is that such wfs include at least one module in which MonitorElement::setStatOverflows is called; even though that is a "per element" call, it still uses the static function TH1::StatOverflows, which affects other TH1s in the job; something not obvious that I thought was worth mentioning (maybe worth mentioning to DQM?).

setStatOverflows is used by

  • DQM/SiStripMonitorCluster/src/SiStripMonitorCluster.cc
  • DQM/SiStripMonitorTrack/src/SiStripMonitorTrack.cc
  • DQM/SiStripMonitorDigi/src/SiStripMonitorDigi.cc
  • DQMOffline/EGamma/src/ElectronDqmAnalyzerBase.cc

while TH1::StatOverflows is also used by

  • DPGAnalysis/SiStripTools/plugins/APVShotsAnalyzer.cc
  • DQMOffline/EGamma/src/ElectronDqmHarvesterBase.cc

Few enought that it should be simple to make a change in the central DQM code and replace the call to TH1::StatOverflows in the same was as done in this PR everywhere else - and definitely something the DQM people might look into.

@fwyzard
Copy link
Contributor

fwyzard commented Dec 1, 2020

@cms-sw/dqm-l2 FYI

@jfernan2
Copy link
Contributor

jfernan2 commented Dec 2, 2020

Thanks @fwyzard
I will seek for this kind of calls in DQM packages. I see that some error messages and warnings registered in Messagelogger by DQM modules are being reduced with this PR too

@silviodonato
Copy link
Contributor

assign dqm

@cmsbuild
Copy link
Contributor

cmsbuild commented Dec 2, 2020

New categories assigned: dqm

@jfernan2,@andrius-k,@fioriNTU,@kmaeshima,@ErnestaP you have been requested to review this Pull request/Issue and eventually sign? Thanks

@jfernan2
Copy link
Contributor

jfernan2 commented Dec 2, 2020

There are several changes
eg.
https://tinyurl.com/y3mansv3
Muons/Tests/trackResidualsTest/MeanTest_phi
image

I believe the changes are not affecting much the final result in this case, at least with 10 event stats of the workflows, it seems in this case that under/overflows are moving the residual mean closer to 0 in the y-axis
It is difficult to know which one is correct

@silviodonato
Copy link
Contributor

merge
(discussed today at the ORP meeting)

@jfernan2
Copy link
Contributor

+1
For the records

@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 be automatically merged.

@missirol missirol deleted the devel_fastTimerOverflows_1120pre10 branch March 27, 2022 13:41
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.

None yet

6 participants