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

New package DataFormats/L1TCalorimeterPhase2 for Phase2 L1T #29348

Conversation

rekovic
Copy link
Contributor

@rekovic rekovic commented Mar 31, 2020

PR description:

New package DataFormats/L1TCalorimeterPhase2 for Phase2 L1Trigger.

These classes are intended to hold L1T objects reconstructed basic stand-alone Calorimeter objects using full granularity of Phase2 calorimeters available to the Leve1 trigger in Phase2.

These objects can then be used downstream to reconstruct more complex objects, either through matching to L1TTTracks or in ParticleFlow algorithms.

To distinguish these objects from Phase-1 L1T objects, this package name contains string Phase2

There are existing DataFormats/L1TCalorimeter which hold Phase1-like calorimeter L1T objects reconstructed with 5x5 granularity available to the Level trigger in Phase1.

@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-29348/14439

  • This PR adds an extra 20KB to repository

@rekovic
Copy link
Contributor Author

rekovic commented Mar 31, 2020

please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 31, 2020

The tests are being triggered in jenkins.
https://cmssdt.cern.ch/jenkins/job/ib-run-pr-tests/5452/console Started: 2020/03/31 02:07

@cmsbuild
Copy link
Contributor

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

It involves the following packages:

DataFormats/L1TCalorimeterPhase2

The following packages do not have a category, yet:

DataFormats/L1TCalorimeterPhase2
Please create a PR for https://github.com/cms-sw/cms-bot/blob/master/categories_map.py to assign category

@cmsbuild can you please review it and eventually sign? Thanks.
@rovere this is something you requested to watch as well.
@davidlange6, @silviodonato, @fabiocos you are the release manager for this.

cms-bot commands are listed here

@rekovic
Copy link
Contributor Author

rekovic commented Mar 31, 2020

please test

@cmsbuild
Copy link
Contributor

-1

Tested at: 8b8eeb4

CMSSW: CMSSW_11_1_X_2020-03-30-1100
SCRAM_ARCH: slc7_amd64_gcc820
You can see the results of the tests here:
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-5286f8/5452/summary.html

I found follow errors while testing this PR

Failed tests: HeaderConsistency

@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-5286f8/5452/summary.html

Comparison Summary:

  • No significant changes to the logs found
  • Reco comparison results: 0 differences found in the comparisons
  • DQMHistoTests: Total files compared: 34
  • DQMHistoTests: Total histograms compared: 2692110
  • DQMHistoTests: Total failures: 35
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 2691756
  • DQMHistoTests: Total skipped: 319
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 33 files compared)
  • Checked 147 log files, 16 edm output root files, 34 DQM output files

@rekovic rekovic changed the title Pr 111x L1T Phase2 DataFormats/L1TCalorimeterPhase2 Pr 111x New package DataFormats/L1TCalorimeterPhase2 for Phase2 L1T Apr 2, 2020
<use name="rootrflx"/>
<use name="hepmc"/>
<use name="clhep"/>
<use name="SimDataFormats/GeneratorProducts"/>
Copy link
Contributor

Choose a reason for hiding this comment

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

By quick look boost, hepmc, clhep, and SimDataFormats/GeneratorProducts are not used. Can they be removed?

@@ -0,0 +1,17 @@
<flags GENREFLEX_ARGS="--"/>
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this flag needed? I don't see such a flag anywhere in CMSSW.

: l1t::L1Candidate(p4), calibratedPt_(calibratedPt), hovere_(hovere), iso_(iso), PUcorrPt_(PUcorrPt){};

// For decay mode related checks with CaloTaus
std::vector<std::vector<float> > associated_l1EGs;
Copy link
Contributor

Choose a reason for hiding this comment

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

Member variables should be private.

// For decay mode related checks with CaloTaus
std::vector<std::vector<float> > associated_l1EGs;

virtual ~L1CaloJet(){};
Copy link
Contributor

Choose a reason for hiding this comment

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

I wonder how this passed clang-tidy, I would have expected

Suggested change
virtual ~L1CaloJet(){};
~L1CaloJet() override {};

Actually the destructor can be removed (i.e. left for compiler to generate)

inline float isolation() const { return iso_; };
inline float PUcorrPt() const { return PUcorrPt_; };
void SetExperimentalParams(const std::map<std::string, float>& params) { experimentalParams_ = params; };
const std::map<std::string, float> GetExperimentalParams() const { return experimentalParams_; };
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
const std::map<std::string, float> GetExperimentalParams() const { return experimentalParams_; };
const std::map<std::string, float>& experimentalParams() const { return experimentalParams_; };

to avoid a copy, and to remove get prefix of a getter (2.11 in http://cms-sw.github.io/cms_coding_rules.html)

try {
return experimentalParams_.at(name);
} catch (...) {
std::cout << "Error: no mapping for ExperimentalParam: " << name << std::endl;
Copy link
Contributor

Choose a reason for hiding this comment

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

cout is not thread safe.


// The index range depends on the algorithm eta,phi window, currently 3x5
// The pt should always be ordered.
inline float GetCrystalPt(unsigned int index) const {
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
inline float GetCrystalPt(unsigned int index) const {
inline float crystalPt(unsigned int index) const {

Comment on lines 15 to 34
namespace {
namespace {

l1slhc::L1EGCrystalCluster egcrystalcluster;
std::vector<l1slhc::L1EGCrystalCluster> l1egcrystalclustervec;
l1slhc::L1EGCrystalClusterCollection l1egcrystalclustercoll;
edm::Wrapper<l1slhc::L1EGCrystalClusterCollection> wl1egcrystalclustercoll;

L1CaloTower l1CaloTower;
std::vector<L1CaloTower> l1CaloTowervec;
L1CaloTowerCollection l1CaloTowercoll;
edm::Wrapper<L1CaloTowerCollection> wl1CaloTowercoll;

l1slhc::L1CaloJet l1calojet;
std::vector<l1slhc::L1CaloJet> l1calojetvec;
l1slhc::L1CaloJetsCollection l1calojetcoll;
edm::Wrapper<l1slhc::L1CaloJetsCollection> wl1calojetcoll;

} // namespace
} // namespace
Copy link
Contributor

Choose a reason for hiding this comment

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

Not needed anymore

Suggested change
namespace {
namespace {
l1slhc::L1EGCrystalCluster egcrystalcluster;
std::vector<l1slhc::L1EGCrystalCluster> l1egcrystalclustervec;
l1slhc::L1EGCrystalClusterCollection l1egcrystalclustercoll;
edm::Wrapper<l1slhc::L1EGCrystalClusterCollection> wl1egcrystalclustercoll;
L1CaloTower l1CaloTower;
std::vector<L1CaloTower> l1CaloTowervec;
L1CaloTowerCollection l1CaloTowercoll;
edm::Wrapper<L1CaloTowerCollection> wl1CaloTowercoll;
l1slhc::L1CaloJet l1calojet;
std::vector<l1slhc::L1CaloJet> l1calojetvec;
l1slhc::L1CaloJetsCollection l1calojetcoll;
edm::Wrapper<l1slhc::L1CaloJetsCollection> wl1calojetcoll;
} // namespace
} // namespace


<lcgdict>

<class name="l1slhc::L1EGCrystalCluster" />
Copy link
Contributor

Choose a reason for hiding this comment

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

Should these be versioned (for future schema evolution)?

int l1eg_standaloneSS = 0;
int l1eg_standaloneIso = 0;

bool isBarrel = false;
Copy link
Contributor

Choose a reason for hiding this comment

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

Please encapsulate the data properly (private members, access via member functions).

@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-29348/14672

@cmsbuild
Copy link
Contributor

Pull request #29348 was updated. @cmsbuild, @rekovic, @benkrikler, @kpedro88 can you please check and sign again.

@rekovic
Copy link
Contributor Author

rekovic commented Apr 13, 2020

please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 13, 2020

The tests are being triggered in jenkins.
https://cmssdt.cern.ch/jenkins/job/ib-run-pr-tests/5682/console Started: 2020/04/13 22:57

@cmsbuild
Copy link
Contributor

+1
Tested at: 3e683bf
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-5286f8/5682/summary.html
CMSSW: CMSSW_11_1_X_2020-04-13-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-5286f8/5682/summary.html

Comparison Summary:

  • No significant changes to the logs found
  • Reco comparison results: 4 differences found in the comparisons
  • DQMHistoTests: Total files compared: 34
  • DQMHistoTests: Total histograms compared: 2695166
  • DQMHistoTests: Total failures: 36
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 2694811
  • DQMHistoTests: Total skipped: 319
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 33 files compared)
  • Checked 147 log files, 16 edm output root files, 34 DQM output files

@rekovic
Copy link
Contributor Author

rekovic commented Apr 14, 2020

+1

@kpedro88
Copy link
Contributor

+upgrade

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

@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