54 maxPt_(iConfig.getParameter<double>(
"maxPt")),
55 highPtTracks_(iConfig.getParameter<
int>(
"highPtTracks")),
56 debug_(iConfig.getParameter<
bool>(
"debug")) {
71 if (!L1TTTrackHandle.
isValid()) {
72 LogError(
"L1TrackerEtMissProducer") <<
"\nWarning: L1TTTrackCollection not found in the event. Exit\n";
76 if (!L1TTTrackAssociatedHandle.
isValid()) {
77 LogError(
"L1TrackerEtMissProducer") <<
"\nWarning: L1TTTrackAssociatedCollection not found in the event. Exit\n";
84 int numqualitytracks = 0;
85 int numassoctracks = 0;
87 for (
const auto&
track : *L1TTTrackHandle) {
88 float pt =
track->momentum().perp();
100 if (
std::find(L1TTTrackAssociatedHandle->begin(), L1TTTrackAssociatedHandle->end(),
track) !=
101 L1TTTrackAssociatedHandle->end()) {
108 float et =
sqrt(sumPx * sumPx + sumPy * sumPy);
109 double etphi = atan2(sumPy, sumPx);
116 <<
"Px: " << sumPx <<
"| Py: " << sumPy <<
"\n" 119 <<
"MET: " <<
et <<
"| Phi: " << etphi <<
"\n" 121 <<
"# Tracks after quality cuts: " << L1TTTrackHandle->size() <<
"\n" 122 <<
"# Tacks after additional highPt Cuts: " << numqualitytracks <<
"\n" 123 <<
"# Tracks associated to vertex: " << numassoctracks <<
"\n" 124 <<
"========================================================" edm::RefVector< L1TTTrackCollectionType > L1TTTrackRefCollectionType
std::vector< TkEtMiss > TkEtMissCollection
Log< level::Info, true > LogVerbatim
std::vector< L1TTTrackType > L1TTTrackCollectionType
const edm::EDGetTokenT< L1TTTrackRefCollectionType > trackToken_
Sin< T >::type sin(const T &t)
const std::string L1MetCollectionName
Log< level::Error, false > LogError
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
std::vector< reco::MET > METCollection
collection of MET objects
XYZTLorentzVectorD XYZTLorentzVector
Lorentz vector with cylindrical internal representation using pseudorapidity.
TTTrack< Ref_Phase2TrackerDigi_ > L1TTTrackType
Cos< T >::type cos(const T &t)
#define DEFINE_FWK_MODULE(type)
void produce(edm::StreamID, edm::Event &, const edm::EventSetup &) const override
const edm::EDGetTokenT< L1TTTrackRefCollectionType > vtxAssocTrackToken_
Class to store the L1 Track Trigger tracks.
L1TrackerEtMissProducer(const edm::ParameterSet &)