62 void endStream()
override;
104 : trkZMax_((
float)iConfig.getParameter<double>(
"trk_zMax")),
105 trkPtMax_((
float)iConfig.getParameter<double>(
"trk_ptMax")),
106 trkPtMin_((
float)iConfig.getParameter<double>(
"trk_ptMin")),
107 trkEtaMax_((
float)iConfig.getParameter<double>(
"trk_etaMax")),
108 nStubs4PromptChi2_((
float)iConfig.getParameter<double>(
"nStubs4PromptChi2")),
109 nStubs5PromptChi2_((
float)iConfig.getParameter<double>(
"nStubs5PromptChi2")),
110 nStubs4PromptBend_((
float)iConfig.getParameter<double>(
"nStubs4PromptBend")),
111 nStubs5PromptBend_((
float)iConfig.getParameter<double>(
"nStubs5PromptBend")),
112 trkNPSStubMin_((
int)iConfig.getParameter<
int>(
"trk_nPSStubMin")),
113 lowpTJetMinTrackMultiplicity_((
int)iConfig.getParameter<
int>(
"lowpTJetMinTrackMultiplicity")),
114 lowpTJetThreshold_((
float)iConfig.getParameter<double>(
"lowpTJetThreshold")),
115 highpTJetMinTrackMultiplicity_((
int)iConfig.getParameter<
int>(
"highpTJetMinTrackMultiplicity")),
116 highpTJetThreshold_((
float)iConfig.getParameter<double>(
"highpTJetThreshold")),
117 zBins_((
int)iConfig.getParameter<
int>(
"zBins")),
118 etaBins_((
int)iConfig.getParameter<
int>(
"etaBins")),
119 phiBins_((
int)iConfig.getParameter<
int>(
"phiBins")),
120 minTrkJetpT_(iConfig.getParameter<double>(
"minTrkJetpT")),
121 displaced_(iConfig.getParameter<
bool>(
"displaced")),
122 d0CutNStubs4_((
float)iConfig.getParameter<double>(
"d0_cutNStubs4")),
123 d0CutNStubs5_((
float)iConfig.getParameter<double>(
"d0_cutNStubs5")),
124 nStubs4DisplacedChi2_((
float)iConfig.getParameter<double>(
"nStubs4DisplacedChi2")),
125 nStubs5DisplacedChi2_((
float)iConfig.getParameter<double>(
"nStubs5DisplacedChi2")),
126 nStubs4DisplacedBend_((
float)iConfig.getParameter<double>(
"nStubs4DisplacedBend")),
127 nStubs5DisplacedBend_((
float)iConfig.getParameter<double>(
"nStubs5DisplacedBend")),
128 nDisplacedTracks_((
int)iConfig.getParameter<
int>(
"nDisplacedTracks")),
129 dzPVTrk_((
float)iConfig.getParameter<double>(
"MaxDzTrackPV")),
138 produces<TkJetCollection>(
"L1TrackJetsExtended");
140 produces<TkJetCollection>(
"L1TrackJets");
156 float PVz = (PVtx->at(0)).
z0();
161 for (
unsigned int this_l1track = 0; this_l1track < TTTrackHandle->size(); this_l1track++) {
165 float trk_chi2dof = trkPtr->
chi2Red();
166 float trk_d0 = trkPtr->
d0();
168 float trk_z0 = trkPtr->
z0();
171 for (
int istub = 0; istub < trk_nstubs; istub++) {
219 std::vector<float> zmins, zmaxs;
220 for (
int zbin = 0; zbin <
zBins_; zbin++) {
226 std::vector<std::vector<EtaPhiBin>> L1clusters;
228 std::vector<EtaPhiBin> L2clusters;
230 for (
unsigned int zbin = 0; zbin < zmins.size(); ++zbin) {
232 float zmin = zmins[zbin];
233 float zmax = zmaxs[zbin];
248 if (zbin == 0 &&
zmin == trkZ)
260 if ((trketa <
eta_min) || (trketa >
eta_max) || (trkphi < phi_min) || (trkphi > phi_max))
275 for (
int phibin = 0; phibin <
phiBins_; ++phibin) {
284 for (
unsigned int k = 0;
k < L2clusters.size(); ++
k) {
290 sum_pt += L2clusters[
k].pTtot;
299 mzb.
nclust = L2clusters.size();
303 vector<Ptr<L1TTTrackType>> L1TrackAssocJet;
304 for (
unsigned int j = 0;
j < mzb.
clusters.size(); ++
j) {
312 int totalDisptrk = mzb.
clusters[
j].numtdtrks;
316 L1TrackAssocJet.clear();
317 for (
unsigned int itrk = 0; itrk < mzb.
clusters[
j].trackidx.size(); itrk++)
322 if (!L1TrackAssocJet.empty())
323 L1L1TrackJetProducer->push_back(trkJet);
338 bool PassQuality =
false;
362 desc.add<
double>(
"MaxDzTrackPV", 1.0);
363 desc.add<
double>(
"trk_zMax", 15.0);
364 desc.add<
double>(
"trk_ptMax", 200.0);
365 desc.add<
double>(
"trk_ptMin", 3.0);
366 desc.add<
double>(
"trk_etaMax", 2.4);
367 desc.add<
double>(
"nStubs4PromptChi2", 5.0);
368 desc.add<
double>(
"nStubs4PromptBend", 1.7);
369 desc.add<
double>(
"nStubs5PromptChi2", 2.75);
370 desc.add<
double>(
"nStubs5PromptBend", 3.5);
371 desc.add<
int>(
"trk_nPSStubMin", -1);
372 desc.add<
double>(
"minTrkJetpT", -1.0);
373 desc.add<
int>(
"etaBins", 24);
374 desc.add<
int>(
"phiBins", 27);
375 desc.add<
int>(
"zBins", 1);
376 desc.add<
double>(
"d0_cutNStubs4", -1);
377 desc.add<
double>(
"d0_cutNStubs5", -1);
378 desc.add<
int>(
"lowpTJetMinTrackMultiplicity", 2);
379 desc.add<
double>(
"lowpTJetThreshold", 50.0);
380 desc.add<
int>(
"highpTJetMinTrackMultiplicity", 3);
381 desc.add<
double>(
"highpTJetThreshold", 100.0);
382 desc.add<
bool>(
"displaced",
false);
383 desc.add<
double>(
"nStubs4DisplacedChi2", 5.0);
384 desc.add<
double>(
"nStubs4DisplacedBend", 1.7);
385 desc.add<
double>(
"nStubs5DisplacedChi2", 2.75);
386 desc.add<
double>(
"nStubs5DisplacedBend", 3.5);
387 desc.add<
int>(
"nDisplacedTracks", 2);
388 descriptions.
add(
"l1tTrackJets",
desc);
bool trackQualityCuts(int trk_nstub, float trk_chi2, float trk_bendchi2)
const int highpTJetMinTrackMultiplicity_
unsigned int tobLayer(const DetId &id) const
std::vector< EtaPhiBin > L2_clustering(std::vector< std::vector< EtaPhiBin >> &L1clusters, int phiBins_, float phiStep_, float etaStep_)
const float d0CutNStubs4_
const float lowpTJetThreshold_
T const & getData(const ESGetToken< T, R > &iToken) const noexcept(false)
Sin< T >::type sin(const T &t)
const float nStubs4DisplacedBend_
L1TrackJetProducer(const ParameterSet &)
edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > tTopoToken_
std::vector< unsigned int > trackidx
const float nStubs4DisplacedChi2_
GlobalVector momentum() const
Track momentum.
const float nStubs5PromptChi2_
XYZTLorentzVectorD XYZTLorentzVector
Lorentz vector with cylindrical internal representation using pseudorapidity.
const float d0CutNStubs5_
const float nStubs4PromptChi2_
vector< L1TTTrackType > L1TTTrackCollectionType
static void fillDescriptions(ConfigurationDescriptions &descriptions)
const float highpTJetThreshold_
const float nStubs5DisplacedBend_
vector< Ptr< L1TTTrackType > > L1TrkPtrs_
std::vector< EtaPhiBin > L1_clustering(EtaPhiBin *phislice, int etaBins_, float etaStep_)
Cos< T >::type cos(const T &t)
const float nStubs4PromptBend_
Abs< T >::type abs(const T &t)
#define DEFINE_FWK_MODULE(type)
void endStream() override
static constexpr auto TOB
const float nStubs5PromptBend_
const float nStubs5DisplacedChi2_
std::vector< edm::Ref< edmNew::DetSetVector< TTStub< T > >, TTStub< T > > > getStubRefs() const
Track components.
void beginStream(StreamID) override
const edm::EDGetTokenT< std::vector< l1t::Vertex > > PVtxToken_
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
void produce(Event &, const EventSetup &) override
Class to store the L1 Track Trigger tracks.
double stubPtConsistency() const
StubPtConsistency.
void add(std::string const &label, ParameterSetDescription const &psetDescription)
double d0() const
Track d0.
TTTrack< Ref_Phase2TrackerDigi_ > L1TTTrackType
const int lowpTJetMinTrackMultiplicity_
const int nDisplacedTracks_
const EDGetTokenT< vector< TTTrack< Ref_Phase2TrackerDigi_ > > > trackToken_
double chi2Red() const
Chi2 reduced.
double z0() const
Track z0.
unsigned int tidRing(const DetId &id) const
std::vector< EtaPhiBin > clusters
std::vector< TkJet > TkJetCollection
static constexpr auto TID
~L1TrackJetProducer() override
const double minTrkJetpT_