112 produces<std::vector<reco::CaloJet> >();
113 produces<std::vector<reco::CaloJet> >(
"PUjets");
114 produces<reco::JetTagCollection>();
124 desc.
add<
double>(
"MinGoodJetTrackPtRatio", 0.045);
125 desc.
add<
double>(
"MinGoodJetTrackPt", 1.8);
126 desc.
add<
double>(
"MaxTrackDistanceToJet", 0.04);
127 desc.
add<
double>(
"MinTrackPt", 0.6);
128 desc.
add<
double>(
"MaxTrackChi2", 20.);
129 desc.
add<
bool>(
"UseForwardJetsAsNoPU",
true);
130 desc.
add<
double>(
"MinEtaForwardJets", 2.4);
131 desc.
add<
double>(
"MinEtForwardJets", 40.);
132 descriptions.
add(
"pixelJetPuId", desc);
142 std::unique_ptr<std::vector<reco::CaloJet> > pOut(
new std::vector<reco::CaloJet>);
143 std::unique_ptr<std::vector<reco::CaloJet> > pOut_PUjets(
new std::vector<reco::CaloJet>);
149 unsigned int tsize =
tracks->size();
150 float teta[tsize], tphi[tsize];
152 for (
auto const& tr : *
tracks) {
174 if (!generaljets.
product()->empty()) {
185 GlobalVector direction(jetMomentum.x(), jetMomentum.y(), jetMomentum.z());
191 pOut->push_back(*itJet);
194 auto itTrack =
tracks->begin();
195 for (
unsigned int i = 0;
i < tsize; ++
i) {
204 trMomentum += itTrack->momentum();
211 pOut->push_back(*itJet);
214 pOut_PUjets->push_back(*itJet);
218 (*pOut_jetTagCollection)[jRef] = trMomentum.rho();