#include "FWCore/Framework/interface/ESHandle.h"
#include "FWCore/Framework/interface/EventSetup.h"
#include "Calibration/HcalAlCaRecoProducers/interface/AlCaIsoTracksProducer.h"
#include "FWCore/MessageLogger/interface/MessageLogger.h"
#include "Geometry/Records/interface/CaloGeometryRecord.h"
#include "Geometry/CaloGeometry/interface/CaloGeometry.h"
#include "Geometry/CaloGeometry/interface/CaloSubdetectorGeometry.h"
#include "Geometry/CaloGeometry/interface/CaloCellGeometry.h"
#include "DataFormats/EcalDetId/interface/EcalSubdetector.h"
#include "DataFormats/HcalDetId/interface/HcalSubdetector.h"
#include "DataFormats/GeometrySurface/interface/Cylinder.h"
#include "DataFormats/GeometrySurface/interface/Plane.h"
#include "Geometry/CommonDetUnit/interface/GeomDetUnit.h"
#include "MagneticField/Engine/interface/MagneticField.h"
#include "MagneticField/Records/interface/IdealMagneticFieldRecord.h"
#include "TrackPropagation/SteppingHelixPropagator/interface/SteppingHelixPropagator.h"
#include "DataFormats/HcalRecHit/interface/HcalRecHitCollections.h"
#include "DataFormats/EcalRecHit/interface/EcalRecHitCollections.h"
#include "FWCore/Utilities/interface/Exception.h"
#include "Geometry/CaloTopology/interface/EcalPreshowerTopology.h"
#include "DataFormats/TrackReco/interface/TrackExtra.h"
#include "DataFormats/TrackReco/interface/TrackExtraFwd.h"
#include "RecoTracker/TrackProducer/interface/TrackProducerBase.h"
#include "DataFormats/HcalIsolatedTrack/interface/IsolatedPixelTrackCandidate.h"
#include "DataFormats/HcalIsolatedTrack/interface/IsolatedPixelTrackCandidateFwd.h"
#include "DataFormats/HLTReco/interface/TriggerEvent.h"
#include "DataFormats/EcalDetId/interface/EBDetId.h"
#include "DataFormats/EcalDetId/interface/EEDetId.h"
#include "Math/GenVector/VectorUtil.h"
#include "Math/GenVector/PxPyPzE4D.h"
#include "DataFormats/L1Trigger/interface/L1JetParticleFwd.h"
#include "DataFormats/L1Trigger/interface/L1JetParticle.h"
#include "DataFormats/Provenance/interface/ProductID.h"
#include <boost/regex.hpp>
Go to the source code of this file.
Functions | |
bool | checkHLTMatch (edm::Event &iEvent, edm::InputTag hltEventTag_, edm::InputTag hltFilterTag_, double eta, double phi) |
double | getDist (double eta1, double phi1, double eta2, double phi2) |
double | getDistInCM (double eta1, double phi1, double eta2, double phi2) |
bool checkHLTMatch | ( | edm::Event & | iEvent, | |
edm::InputTag | hltEventTag_, | |||
edm::InputTag | hltFilterTag_, | |||
double | eta, | |||
double | phi | |||
) |
Definition at line 66 of file AlCaIsoTracksProducer.cc.
References trigger::TriggerObject::eta(), edm::Event::getByLabel(), getDist(), edm::match(), and trigger::TriggerObject::phi().
Referenced by AlCaIsoTracksProducer::produce().
00067 { 00068 bool match =false; 00069 double minDDD=1000; 00070 00071 edm::Handle<trigger::TriggerEvent> trEv; 00072 iEvent.getByLabel(hltEventTag_,trEv); 00073 const trigger::TriggerObjectCollection& TOCol(trEv->getObjects()); 00074 00075 trigger::Keys KEYS; 00076 const trigger::size_type nFilt(trEv->sizeFilters()); 00077 for (trigger::size_type iFilt=0; iFilt!=nFilt; iFilt++) 00078 { 00079 if (trEv->filterTag(iFilt)==hltFilterTag_) KEYS=trEv->filterKeys(iFilt); 00080 } 00081 trigger::size_type nReg=KEYS.size(); 00082 for (trigger::size_type iReg=0; iReg<nReg; iReg++) 00083 { 00084 const trigger::TriggerObject& TObj(TOCol[KEYS[iReg]]); 00085 double dHit=getDist(TObj.eta(),TObj.phi(),eta,phi); 00086 if (dHit<minDDD) minDDD=dHit; 00087 } 00088 if (minDDD>0.4) match=false; 00089 else match=true; 00090 00091 return match; 00092 00093 00094 }
double getDist | ( | double | eta1, | |
double | phi1, | |||
double | eta2, | |||
double | phi2 | |||
) |
Definition at line 58 of file AlCaIsoTracksProducer.cc.
References funct::pow(), and funct::sqrt().
Referenced by checkHLTMatch(), and AlCaIsoTracksProducer::produce().
00059 { 00060 double dphi = fabs(phi1 - phi2); 00061 if(dphi>acos(-1)) dphi = 2*acos(-1)-dphi; 00062 double dr = sqrt(dphi*dphi + pow(eta1-eta2,2)); 00063 return dr; 00064 }
double getDistInCM | ( | double | eta1, | |
double | phi1, | |||
double | eta2, | |||
double | phi2 | |||
) |
Definition at line 46 of file AlCaIsoTracksProducer.cc.
References funct::cos(), funct::exp(), funct::sin(), and funct::tan().
Referenced by AlCaIsoTracksProducer::produce().
00047 { 00048 double dR, Rec; 00049 double theta1=2*atan(exp(-eta1)); 00050 double theta2=2*atan(exp(-eta2)); 00051 if (fabs(eta1)<1.479) Rec=129; 00052 else Rec=275; 00053 //|vect| times tg of acos(scalar product) 00054 dR=fabs((Rec/sin(theta1))*tan(acos(sin(theta1)*sin(theta2)*(sin(phi1)*sin(phi2)+cos(phi1)*cos(phi2))+cos(theta1)*cos(theta2)))); 00055 return dR; 00056 }