11 WTAParameters(IntOrFloat const_et_cut = 2000, IntOrFloat seed_et_cut = 5000, IntOrFloat jet_dr2 = R2PAR,
12 unsigned int max_const_n = 250,
unsigned int max_seed_sorting_n = 50,
unsigned int max_seed_n = 10,
unsigned int max_const_per_jet_n = 99,
13 bool add_const_first =
true) :
75 std::vector<WTATrigObj>
LoadInputs(
const std::vector<IntOrFloat>& ptVec,
const std::vector<IntOrFloat>& etaVec,
const std::vector<IntOrFloat>& phiVec,
const std::vector<IntOrFloat>& mVec);
76 virtual void FillLists(
const std::vector<WTATrigObj>& InputTowers);
77 void InitiateInputs(
const std::vector<IntOrFloat>& ptVec,
const std::vector<IntOrFloat>& etaVec,
const std::vector<IntOrFloat>& phiVec,
const std::vector<IntOrFloat>& mVec);
101 inline std::vector<WTATrigObj>
WTAConeMaker::LoadInputs(
const std::vector<IntOrFloat>& ptVec,
const std::vector<IntOrFloat>& etaVec,
const std::vector<IntOrFloat>& phiVec,
const std::vector<IntOrFloat>& mVec)
103 std::vector<WTATrigObj> input_towers;
104 unsigned int tower_n = ptVec.size();
105 for(
unsigned int t = 0;
t < tower_n;
t++)
107 WTATrigObj this_tower(ptVec.at(
t), etaVec.at(
t), phiVec.at(
t), mVec.at(
t));
108 input_towers.push_back(this_tower);
120 if(
m_DEBUG) std::cout <<
"MaxTowersToReadPerEvent = " << MaxTowersToReadPerEvent <<
", Size of event = " << InputTowers.size() << std::endl;
122 for(
auto tower: InputTowers)
130 if(nTowers>MaxTowersToReadPerEvent)
break;
136 inline void WTAConeMaker::InitiateInputs(
const std::vector<IntOrFloat>& ptVec,
const std::vector<IntOrFloat>& etaVec,
const std::vector<IntOrFloat>& phiVec,
const std::vector<IntOrFloat>& mVec)
138 std::vector<WTATrigObj> InputTowers =
LoadInputs(ptVec, etaVec, phiVec, mVec);
151 int AllJetConstN = 0;
154 AllJetConstN +=
jet.GetConstituentCount();
155 std::cout <<
"Jet pT, eta, phi, constN = " <<
jet.pt() <<
" , " <<
jet.eta() <<
" , " <<
jet.phi() <<
" , " <<
jet.GetConstituentCount() << std::endl;
157 std::cout <<
"PrintSeedList..." <<
" , SeedN, AllJetConstN, ConstN = " <<
m_SeedList.size() <<
" , " << AllJetConstN <<
" , " <<
m_ConstituentList.size() << std::endl;
158 std::cout <<
"+++++++++++++++++++++++++" << std::endl;
182 while(
jet.GetConstituentCount() > MaxConstPerJetN)
184 jet.PopOutLastConstituent();
213 std::vector<int> associate_bit(jet_N, 0);
214 IntOrFloat
MaxPt = tower.
pt(); MaxPtIndex = -1;
215 for(
int j = 0; j < jet_N; j++)
220 associate_bit.at(j) = 1;
228 return associate_bit;
234 if(
m_DEBUG)std::cout <<
"Baseline Seed Cleaning......" << std::endl;
246 if(
std::find(associate_bit.begin(), associate_bit.end(), 1) != associate_bit.end())
251 for(
int j = jet_N - 1; j >= 0; j--)
253 if(associate_bit.at(j) == 1)
278 std::cout <<
"Baseline Seed Cleaning Done......" << std::endl;
286 for(
unsigned int j = 0; j <
m_SeedList.size(); j++)
288 IntOrFloat dR2 = constituent.dR2(
m_SeedList.at(j));
291 m_SeedList.at(j).MergeConstituent(constituent);