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
[Tracker Alignment] Miscellanea graphical fixes for PV-related validations #36236
Conversation
-code-checks Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-36236/26868
Code check has found code style and quality issues which could be resolved by applying following patch(s)
|
9c5b8c0
to
c775a2c
Compare
+code-checks Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-36236/26869
|
A new Pull Request was created by @mmusich (Marco Musich) for master. It involves the following packages:
@cmsbuild, @malbouis, @tvami, @yuanchao, @francescobrivio can you please review it and eventually sign? Thanks. cms-bot commands are listed here |
@cmsbuild, please test |
+1 Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-039795/20741/summary.html Comparison SummarySummary:
|
+alca
|
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. @perrotta, @dpiparo, @qliphy (and backports should be raised in the release meeting by the corresponding L2) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mmusich take the following as comments that you can take into account if you plan to further update/fix the code.
@@ -335,17 +335,17 @@ void FitPVResolution(TString namesandlabels, TString theDate = "", bool isStrict | |||
} | |||
|
|||
// max vertices | |||
const int max_n_vertices = std::min(40, VTXBINS); // take the minimum to avoid overflow | |||
const int max_n_vertices = std::min(60, VTXBINS); // take the minimum to avoid overflow | |||
std::vector<float> myNVtx_bins_; | |||
for (float i = 0; i <= max_n_vertices; i++) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for (float i = 0; i <= max_n_vertices; i++) { | |
for (float i = 0; i < max_n_vertices + 0.5f ; i++) { |
(I wouldn't trust a check of equalities between float's...)
} | ||
|
||
// max track | ||
const int max_n_tracks = std::min(60, TRACKBINS); // take the minimum to avoid overflow | ||
const int max_n_tracks = std::min(120, TRACKBINS); // take the minimum to avoid overflow | ||
std::vector<float> myNTrack_bins_; | ||
for (float i = 0; i <= max_n_tracks; i++) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
@@ -295,12 +296,55 @@ SplitVertexResolution::SplitVertexResolution(const edm::ParameterSet& iConfig) | |||
|
|||
mypT_bins_ = PVValHelper::makeLogBins<float, nPtBins_>(sumpTStartScale_, sumpTEndScale_); | |||
|
|||
std::vector<float> vect = PVValHelper::generateBins(nTrackBins_ + 1, 1., 120.); | |||
// IMPORTANT | |||
// first argument is start, second argument is the range so it's [-0.5;nTracksBins_-0.5] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are three arguments in fact: I guess the comment can be made more clear...
vect = PVValHelper::generateBins(nVtxBins_ + 1, 1., 40.); | ||
|
||
// IMPORTANT | ||
// first argument is start, second argument is the range so it's [-0.5;nVtxBins_-0.5] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
+1 |
Hello @mmusich, Could it be that changes in this PR broke Unit Test Thank you, |
@aandvalenzuela this PR is more than 1 year old.... |
Ups, sorry I completely overlooked the year. I will open a new issue for this failure |
PR description:
Follow-up of PR #36178, fixes an off-by-one bin mistake in the population of the Split Vertex resolution plots.
I profit to fix a couple of other bug in the
FitPVResiduals.C
macro.PR validation:
Private. Tested on 2021 Beam Test data, see e.g. here
if this PR is a backport please specify the original PR and why you need to backport that PR:
Not a backport, but will need to be backported together with #36178