6 : verbose_(iConfig.getParameter<
int>(
"verbose")), sector_(sector), wheel_(
wheel) {
10 }
else if (sector == 0) {
55 for (
const auto& stub : stubsAll) {
56 if (stub->bxNum() !=
bx)
59 if ((stub->scNum() ==
nextSector_ && stub->phi() >= -112) ||
64 seeds.push_back(stub);
65 stubs.push_back(stub);
67 stubs.push_back(stub);
70 stubs.push_back(stub);
77 if (
seeds.size() > 1) {
82 std::pair<bool, L1MuKBMTrack> trackInfo = trackMaker->
chain(
seed, stubs);
88 if (trackInfo.first) {
89 if (
seed->stNum() == 2)
90 pretracks2.push_back(trackInfo.second);
91 if (
seed->stNum() == 3)
92 pretracks3.push_back(trackInfo.second);
93 if (
seed->stNum() == 4)
94 pretracks4.push_back(trackInfo.second);
96 if (
seed->stNum() == 2)
97 pretracks2.push_back(nullTrack);
98 if (
seed->stNum() == 3)
99 pretracks3.push_back(nullTrack);
100 if (
seed->stNum() == 4)
101 pretracks4.push_back(nullTrack);
109 if (pretracks2.size() < 2) {
110 if (pretracks2.empty()) {
111 pretracks2.push_back(nullTrack);
112 pretracks2.push_back(nullTrack);
114 if (pretracks2[0].stubs()[0]->
tag() == 0)
115 pretracks2.push_back(nullTrack);
117 pretracks2.insert(pretracks2.begin(), nullTrack);
122 if (pretracks3.size() < 2) {
123 if (pretracks3.empty()) {
124 pretracks3.push_back(nullTrack);
125 pretracks3.push_back(nullTrack);
127 if (pretracks3[0].stubs()[0]->
tag() == 0)
128 pretracks3.push_back(nullTrack);
130 pretracks3.insert(pretracks3.begin(), nullTrack);
135 if (pretracks4.size() < 2) {
136 if (pretracks4.empty()) {
137 pretracks4.push_back(nullTrack);
138 pretracks4.push_back(nullTrack);
140 if (pretracks4[0].stubs()[0]->
tag() == 0)
141 pretracks4.push_back(nullTrack);
143 pretracks4.insert(pretracks4.begin(), nullTrack);
164 printf(
" -----Sector Processor Kalman Tracks-----\n");
165 for (
const auto& track1 :
out)
166 printf(
"Kalman Track charge=%d pt=%f eta=%f phi=%f curvature=%d curvature STA =%d stubs=%d chi2=%d pts=%f %f\n",
171 track1.curvatureAtVertex(),
172 track1.curvatureAtMuon(),
173 int(track1.stubs().size()),
176 track1.ptUnconstrained());
195 temp.setPtEtaPhi(0, 0, 0);
200 temp.setPtEtaPhi(0, 0, 0);
218 for (
uint i = 0;
i < tracks1.size(); ++
i) {
221 for (
uint j = 0;
j < tracks2.size(); ++
j) {
222 if (tracks1[
i].overlapTrack(tracks2[
j])) {
223 if (tracks1[
i].rank() <= tracks2[
j].rank()) {
225 temp.setPtEtaPhi(0, 0, 0);
242 for (
uint i = 0;
i < tracks1.size(); ++
i) {
245 for (
uint j = 0;
j < tracks2.size(); ++
j) {
246 if (tracks1[
i].overlapTrack(tracks2[
j])) {
247 if (tracks1[
i].rank() < tracks2[
j].rank()) {
249 temp.setPtEtaPhi(0, 0, 0);
268 else if (
in.size() == 3) {
272 if (
in[2].
pt() >=
in[0].pt()) {
286 if (s2_3.
pt() >= s2_2.
pt()) {
324 if (s2_4.
pt() >= s2_1.
pt()) {
332 if (s2_3.
pt() >= s2_2.
pt()) {
357 if (!cleaned23.empty())
358 step1.insert(step1.end(), cleaned23.begin(), cleaned23.end());
359 if (!cleaned32.empty())
360 step1.insert(step1.end(), cleaned32.begin(), cleaned32.end());
377 if (!cleanedSorted4.empty())
378 step2.insert(step2.end(), cleanedSorted4.begin(), cleanedSorted4.end());
379 if (!cleanedSorted23.empty())
380 step2.insert(step2.end(), cleanedSorted23.begin(), cleanedSorted23.end());
L1MuKBMTrackCollection cleanLower(const L1MuKBMTrackCollection &tracks1, const L1MuKBMTrackCollection &tracks2)
double pt() const final
transverse momentum
std::vector< edm::Ref< L1MuKBMTCombinedStubCollection > > L1MuKBMTCombinedStubRefVector
void setPtEtaPhi(double, double, double)
L1MuKBMTrackCollection cleanHigher(const L1MuKBMTrackCollection &tracks1, const L1MuKBMTrackCollection &tracks2)
~L1TMuonBarrelKalmanRegionModule()
void swap(edm::DataFrameContainer &lhs, edm::DataFrameContainer &rhs)
L1MuKBMTrackCollection process(L1TMuonBarrelKalmanAlgo *, const L1MuKBMTCombinedStubRefVector &stubs, int bx)
L1MuKBMTrackCollection cleanRegion(const L1MuKBMTrackCollection &, const L1MuKBMTrackCollection &, const L1MuKBMTrackCollection &)
auto const & tracks
cannot be loose
std::pair< bool, L1MuKBMTrack > chain(const L1MuKBMTCombinedStubRef &, const L1MuKBMTCombinedStubRefVector &)
L1MuKBMTrackCollection sort4(const L1MuKBMTrackCollection &in)
std::vector< L1MuKBMTrack > L1MuKBMTrackCollection
L1MuKBMTrackCollection selfClean(const L1MuKBMTrackCollection &tracks)
L1TMuonBarrelKalmanRegionModule(const edm::ParameterSet &, int wheel, int sector)