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 DT vdrift calibration code to allow using "new" DB format #31808

Merged
merged 7 commits into from Oct 21, 2020

Conversation

namapane
Copy link
Contributor

PR description:

New DT payload formats were introduced with #5977, but so far have been adopted only for uncertainties (#9883).
This PR includes some updates to DT vdrift calibration code/scripts to enable to optionally read/write constants in the new format.
The default behaviour is unchanged (ie use the legacy format); it is one step towards enabling a complete migration.

PR validation:

Code changes tested by @saghosh :

  • running the calibration with the default configuration (ie legacy format) produces identical results as before;
  • enabling the writing in the new fomat produces identical constants as in the previous step.

@cmsbuild
Copy link
Contributor

The code-checks are being triggered in jenkins.

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-31808/19104

  • This PR adds an extra 28KB to repository

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @namapane (Nicola Amapane) for master.

It involves the following packages:

CalibMuon/DTCalibration

@yuanchao, @christopheralanwest, @tocheng, @cmsbuild, @tlampen, @pohsun can you please review it and eventually sign? Thanks.
@mmusich, @tocheng, @battibass 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

@christopheralanwest
Copy link
Contributor

please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Oct 18, 2020

The tests are being triggered in jenkins.

@cmsbuild
Copy link
Contributor

+1
Tested at: 2750f94
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-5e5b70/10059/summary.html
CMSSW: CMSSW_11_2_X_2020-10-17-1100
SCRAM_ARCH: slc7_amd64_gcc820

@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-5e5b70/10059/summary.html

Comparison Summary:

  • No significant changes to the logs found
  • Reco comparison results: 4 differences found in the comparisons
  • DQMHistoTests: Total files compared: 35
  • DQMHistoTests: Total histograms compared: 2543752
  • DQMHistoTests: Total failures: 10
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 2543720
  • DQMHistoTests: Total skipped: 22
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 34 files compared)
  • Checked 149 log files, 22 edm output root files, 35 DQM output files

@yuanchao
Copy link
Contributor

+1

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

Copy link
Contributor

@silviodonato silviodonato left a comment

Choose a reason for hiding this comment

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

I've added some comments about the migration to the event setup token https://twiki.cern.ch/twiki/bin/view/CMSPublic/SWGuideHowToGetDataFromES#Getting_data_from_EventSetup_wit .

mTimeMap_ = &*mTime;
if (readLegacyVDriftDB) {
ESHandle<DTMtime> mTime;
setup.get<DTMtimeRcd>().get(mTime);
Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Contributor Author

Choose a reason for hiding this comment

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

OK, but this migration has to be done on these classes anyhow, it is not needed as a consequence of this PR.
Therefore it would make more sense to make it in its own PR, after this one is merged.
I can make a new PR for the migration right away after this one is merged; this is my preference given that this PR is by now tested and fully signed.

mTimeMap_ = &*mTime;
} else {
ESHandle<DTRecoConditions> hVdrift;
setup.get<DTRecoConditionsVdriftRcd>().get(hVdrift);
Copy link
Contributor

Choose a reason for hiding this comment

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

same here

// Get the map of vdrift from the Setup
if (readLegacyVDriftDB) {
ESHandle<DTMtime> mTime;
setup.get<DTMtimeRcd>().get(mTime);
Copy link
Contributor

Choose a reason for hiding this comment

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

here

mTimeMap_ = &*mTime;
} else {
ESHandle<DTRecoConditions> hVdrift;
setup.get<DTRecoConditionsVdriftRcd>().get(hVdrift);
Copy link
Contributor

Choose a reason for hiding this comment

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

here

if (version != 1) {
throw cms::Exception("Configuration") << "only version 1 is presently supported for VDriftDB";
}
}

// Get geometry from Event Setup
setup.get<MuonGeometryRecord>().get(dtGeom_);
Copy link
Contributor

Choose a reason for hiding this comment

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

here

Copy link
Contributor Author

@namapane namapane Oct 21, 2020

Choose a reason for hiding this comment

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

Besides, the same migration would have to be done everywhere in the package; for example. also in
https://github.com/cms-sw/cmssw/blob/master/CalibMuon/DTCalibration/plugins/DTTTrigCorrection.cc#L49
an generally in each and every cc under plugins, not just in those interested by this PR.
IMO this is another reason why that migration deserves its own, separate PR.
@silviodonato can you please let me know if you agree.

@silviodonato
Copy link
Contributor

+1

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

5 participants