16 #include "../IO/GenericTOBArray.h"
17 #include "../IO/Decision.h"
24 unsigned int InputWidth,
27 const std::vector<unsigned int>& MinSumET) :
29 m_InputWidth{InputWidth},
32 m_MinSumET{MinSumET} {
37 std::vector<GenericTOBArray>&
output,
42 auto numberOutputBits = m_MinSumET.size();
44 output.reserve(numberOutputBits);
45 for (std::size_t
i = 0;
i != numberOutputBits; ++
i) {
47 ss <<
"SimpleCone bit " <<
i;
51 decision.setNBits(numberOutputBits);
53 unsigned int leadingET = 0;
60 if((*itr0)->Et() <= m_MinET )
continue;
62 unsigned int tmp_SumET = (*itr0)->Et();
71 if((*itr1)->Et() <= m_MinET)
continue;
79 tmp_SumET += (*itr1)->Et();
82 if (tmp_SumET > leadingET) {
83 leadingET = tmp_SumET;
87 for(
unsigned int i=0;
i< numberOutputBits; ++
i) {
89 bool accept = leadingET > m_MinSumET[
i];
94 m_ETPassByBit[
i].push_back(leadingET);
96 m_ETFailByBit[
i].push_back(leadingET);
100 return StatusCode::SUCCESS;
103 const std::vector<double>& SimpleCone::ETPassByBit(std::size_t
i)
const {
104 return m_ETPassByBit.at(
i);
107 const std::vector<double>& SimpleCone::ETFailByBit(std::size_t
i)
const {
108 return m_ETFailByBit.at(
i);
112 std::stringstream
ss;
113 ss <<
"SimpleCone. name: " << m_name <<
'\n'
114 <<
" InputWidth: " << m_InputWidth
115 <<
" MaxRSqr " << m_MaxRSqr
116 <<
" MinET " << m_MinET
117 <<
" MinSumET [" << m_MinSumET.size() <<
"]: ";
120 for (
const auto&
et : m_MinSumET) {