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

bsunanda:Run2 alca14 Get rid of unused variables and avoid explicit names #9062

Merged
merged 5 commits into from May 19, 2015

Conversation

bsunanda
Copy link
Contributor

Remove some of the unused variables. Avoid using explicit names in the name of the products. Correct the selection function to avoid assumptions in warning. Change some getByLabel with getByToken. Use LogDebug in the DQM code.

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @bsunanda for CMSSW_7_5_X.

bsunanda:Run2 alca13 Get rid of unused variables and avoid explicit names

It involves the following packages:

Calibration/HcalAlCaRecoProducers
Calibration/IsolatedParticles
DQMOffline/CalibCalo

@diguida, @danduggan, @cerminar, @cmsbuild, @nclopezo, @deguio, @mmusich can you please review it and eventually sign? Thanks.
@rociovilar this is something you requested to watch as well.
You can sign-off by replying to this message having '+1' in the first line of your reply.
You can reject by replying to this message having '-1' in the first line of your reply.
If you are a L2 or a release manager you can ask for tests by saying 'please test' in the first line of a comment.
@nclopezo you are the release manager for this.
You can merge this pull request by typing 'merge' in the first line of your comment.

@diguida
Copy link
Contributor

diguida commented May 12, 2015

@cmsbuild please test

1 similar comment
@mmusich
Copy link
Contributor

mmusich commented May 12, 2015

@cmsbuild please test

@cmsbuild
Copy link
Contributor

The tests are being triggered in jenkins.

itr!=ph.end(); ++itr) {
if (itr->pt() >= minPtPhoton_) return ok;
}
return false;
}
Copy link
Contributor

Choose a reason for hiding this comment

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

@bsunanda IIUC the tests you perform are:

  1. Test if the Photon collection is empty: return false if so;
  2. Check the requirement for minimum pT: at least one PFJet should have pt larger than the threshold, otherwise return false;
  3. Check the requirement for minimum pT: at least one Photon should have pt larger than the threshold. If so, return true, otherwise false.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes - we need events with at least one high pt jet and one high pt photon. The assumption of ordering was found to be incorrect - so the code is optimized this way.


From: Salvatore Di Guida [notifications@github.com]
Sent: 13 May 2015 10:17
To: cms-sw/cmssw
Cc: Sunanda Banerjee
Subject: Re: [cmssw] bsunanda:Run2 alca13 Get rid of unused variables and avoid explicit names (#9062)

In Calibration/HcalAlCaRecoProducers/src/AlCaGammaJetProducer.cchttps://github.com//pull/9062#discussion_r30210248:

  • // Check the requirement for minimum pT
  • if (ph.size() == 0) return false;
  • bool ok(false);
  • for (reco::PFJetCollection::const_iterator itr=jt.begin();
  •   itr!=jt.end(); ++itr) {
    
  • if (itr->pt() >= minPtJet_) {
  •  ok = true;
    
  •  break;
    
  • }
  • }
  • if (!ok) return ok;
  • for (reco::PhotonCollection::const_iterator itr=ph.begin();
  •   itr!=ph.end(); ++itr) {
    
  • if (itr->pt() >= minPtPhoton_) return ok;
  • }
  • return false;
    }

@bsunandahttps://github.com/bsunanda IIUC the tests you perform are:

  1. Test if the Photon collection is empty: return false if so;
  2. Check the requirement for minimum pT: at least one PFJet should have pt larger than the threshold, otherwise return false;
  3. Check the requirement for minimum pT: at least one Photon should have pt larger than the threshold. If so, return true, otherwise false.


Reply to this email directly or view it on GitHubhttps://github.com//pull/9062/files#r30210248.

@cmsbuild
Copy link
Contributor

@cmsbuild
Copy link
Contributor

This pull request is fully signed and it will be integrated in one of the next CMSSW_7_5_X IBs unless changes (tests are also fine). This pull request requires discussion in the ORP meeting before it's merged. @davidlange6, @nclopezo, @smuzaffar

@davidlange6
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

7 participants