96 m_gtEnergySumTemplate = eSumTempl;
116 bool condResult =
false;
123 (combinationsInCond()).
clear();
126 objectsInComb.clear();
131 int useBx = bxEval + m_gtEnergySumTemplate->condRelativeBx();
133 int numberObjects = candVec->
size(useBx);
134 if (numberObjects < 1) {
139 if( ( useBx < candVec->getFirstBX() ) ||
146 bool MissingEnergy =
false;
147 switch( (m_gtEnergySumTemplate->objectType())[0] ){
150 MissingEnergy =
true;
154 MissingEnergy =
false;
158 MissingEnergy =
true;
162 MissingEnergy =
false;
166 MissingEnergy =
true;
169 type = l1t::EtSum::EtSumType::kMinBiasHFP0;
170 MissingEnergy =
false;
173 type = l1t::EtSum::EtSumType::kMinBiasHFM0;
174 MissingEnergy =
false;
177 type = l1t::EtSum::EtSumType::kMinBiasHFP1;
178 MissingEnergy =
false;
181 type = l1t::EtSum::EtSumType::kMinBiasHFM1;
182 MissingEnergy =
false;
187 <<
"Unmatched object type from template to EtSumType, (m_gtEnergySumTemplate->objectType())[0] = "
188 << (m_gtEnergySumTemplate->objectType())[0]
196 unsigned int candEt = 0;
197 unsigned int candPhi = 0;
198 bool candOverflow =
false;
199 for(
int iEtSum = 0; iEtSum < numberObjects; ++iEtSum ){
202 candEt = cand.
hwPt();
203 candPhi = cand.
hwPhi();
208 ( *(m_gtEnergySumTemplate->objectParameter()) )[iCondition];
220 bool condGEqVal = m_gtEnergySumTemplate->condGEq();
224 LogDebug(
"L1TGlobal") <<
"\t\t l1t::EtSum failed checkThreshold" << std::endl;
228 if( !condGEqVal && candOverflow )
return false;
235 LogDebug(
"L1TGlobal") <<
"\t\t l1t::EtSum failed checkRange(phi)" << std::endl;
244 objectsInComb.push_back(indexObj);
245 (combinationsInCond()).push_back(objectsInComb);
257 m_gtEnergySumTemplate->print(myCout);
unsigned size(int bx) const
CombinationsInCond const & getCombinationsInCond() const
get all the object combinations evaluated to true in the condition
const GlobalBoard * getuGtB() const
get / set the pointer to uGt GlobalBoard
unsigned int etLowThreshold
const bool evaluateCondition(const int bxEval) const
the core function to check if the condition matches
unsigned int phiWindow1Lower
virtual void print(std::ostream &myCout) const
print condition
std::vector< int > SingleCombInCond
typedefs
void setuGtB(const GlobalBoard *)
set the pointer to uGT GlobalBoard
unsigned int etHighThreshold
bool condLastResult() const
get the latest result for the condition
const EnergySumTemplate * gtEnergySumTemplate() const
get / set the pointer to a L1GtCondition
unsigned int phiWindow2Lower
EnergySumCondition & operator=(const EnergySumCondition &)
void clear(CLHEP::HepGenMatrix &m)
Helper function: Reset all elements of a matrix to 0.
virtual ~EnergySumCondition()
typedef for a single object template
void print(std::ostream &myCout) const
print condition
int m_verbosity
verbosity level
int condMaxNumberObjects() const
unsigned int phiWindow1Upper
unsigned int phiWindow2Upper
int m_condMaxNumberObjects
EtSumType getType() const
void setGtEnergySumTemplate(const EnergySumTemplate *)
void copy(const EnergySumCondition &cp)
copy function for copy constructor and operator=
const T & at(int bx, unsigned i) const