13 inputTrackJetTag_(iConfig.getParameter< edm::InputTag > (
"inputTrackJetTag")),
14 inputCaloJetTag_(iConfig.getParameter< edm::InputTag > (
"inputCaloJetTag")),
15 inputTrackTag_(iConfig.getParameter< edm::InputTag > (
"inputTrackTag")),
16 ptMinCaloJet_(iConfig.getParameter< double > (
"ptMinCaloJet")),
17 etaMinCaloJet_(iConfig.getParameter< double > (
"etaMinCaloJet")),
18 etaMaxCaloJet_(iConfig.getParameter< double > (
"etaMaxCaloJet")),
19 tauConeSize_(iConfig.getParameter< double > (
"tauConeSize")),
20 isolationConeSize_(iConfig.getParameter< double > (
"isolationConeSize")),
21 fractionMinCaloInTauCone_(iConfig.getParameter< double > (
"fractionMinCaloInTauCone")),
22 fractionMaxChargedPUInCaloCone_(iConfig.getParameter< double > (
"fractionMaxChargedPUInCaloCone")),
23 ptTrkMaxInCaloCone_(iConfig.getParameter< double > (
"ptTrkMaxInCaloCone")),
24 nTrkMaxInCaloCone_(iConfig.getParameter< int > (
"nTrkMaxInCaloCone"))
27 produces<reco::TrackJetCollection>();
53 for (reco::TrackJetCollection::const_iterator trackjet = trackjets->begin();
54 trackjet != trackjets->end(); trackjet++) {
55 augmentedTrackJets->push_back(*trackjet);
67 for (reco::CaloJetCollection::const_iterator calojet = calojets->begin();
68 calojet != calojets->end(); calojet++) {
71 double etaJet = calojet->eta();
72 double phiJet = calojet->phi();
76 std::vector <CaloTowerPtr>
const & theTowers = calojet->getCaloConstituents();
79 for (
unsigned int itwr = 0; itwr < theTowers.size(); ++itwr ) {
80 double etaTwr = theTowers[itwr]->eta() - etaJet;
81 double phiTwr =
deltaPhi(theTowers[itwr]->
phi(), phiJet);
82 double deltaR2 = etaTwr*etaTwr + phiTwr*phiTwr;
84 if ( deltaR2 < tauConeSize2 ) {
85 ptIn += theTowers[itwr]->pt();
86 }
else if ( deltaR2 < isolationConeSize2 ) {
87 ptOut += theTowers[itwr]->pt();
90 double ptTot = ptIn+ptOut;
91 double fracIn = ptIn/ptTot;
99 for (reco::TrackJetCollection::const_iterator trackjet = trackjets->begin();
100 trackjet != trackjets->end(); trackjet++) {
101 for (
unsigned itr=0; itr<trackjet->numberOfTracks(); ++itr) {
103 double trackEta = track->eta() - etaJet;
106 if ( deltaR2 < isolationConeSize2 ) {
108 ptTrk += track->pt();
119 for (reco::TrackCollection::const_iterator track = tracks->begin();
120 track != tracks->end(); track++) {
121 double trackEta = track->eta() - etaJet;
124 if ( deltaR2 < isolationConeSize2 ) {
126 ptTrk2 += track->pt();
130 double fractionChargedPU = ptTrk2/calojet->pt();
144 iEvent.
put(augmentedTrackJets);
const edm::InputTag inputCaloJetTag_
virtual void produce(edm::Event &, const edm::EventSetup &)
TauJetSelectorForHLTTrackSeeding(const edm::ParameterSet &)
const double isolationConeSize_
const edm::InputTag inputTrackTag_
const double etaMinCaloJet_
XYZTLorentzVectorD XYZTLorentzVector
Lorentz vector with cylindrical internal representation using pseudorapidity.
const double tauConeSize_
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
const double fractionMinCaloInTauCone_
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
const double fractionMaxChargedPUInCaloCone_
double deltaR2(const Vector1 &v1, const Vector2 &v2)
const double etaMaxCaloJet_
~TauJetSelectorForHLTTrackSeeding()
XYZPointD XYZPoint
point in space with cartesian internal representation
virtual void beginRun(edm::Run &, edm::EventSetup const &)
const double ptMinCaloJet_
std::vector< TrackJet > TrackJetCollection
collection of TrackJet objects
const int nTrkMaxInCaloCone_
const edm::InputTag inputTrackJetTag_
virtual void endRun(edm::Run &, edm::EventSetup const &)
const double ptTrkMaxInCaloCone_