17 const std::string& name,
18 const IInterface* parent )
19 : base_class(
type, name, parent ),
31 ATH_MSG_ERROR(
" There are no cuts set (EtaBins property is an empty list)" );
32 return StatusCode::FAILURE;
35 unsigned int nEtaBin =
m_etabin.size();
37#define CHECK_SIZE( __n) if ( m_##__n.size() != (nEtaBin - 1) ) \
38 { ATH_MSG_DEBUG(" __n size is " << m_##__n.size() << " but needs to be " << (nEtaBin - 1) ); return StatusCode::FAILURE; }
51 return StatusCode::SUCCESS;
67 etaBin, monEta,monPhi,PassedCuts );
69 PassedCuts = PassedCuts + 1;
71 auto roiDescriptor = input.roi;
74 if ( std::abs( roiDescriptor->eta() ) > 2.6 ) {
75 ATH_MSG_DEBUG(
"REJECT The cluster had eta coordinates beyond the EM fiducial volume : " << roiDescriptor->eta() <<
"; stop the chain now" );
81 <<
": Eta = " << roiDescriptor->eta()
82 <<
", Phi = " << roiDescriptor->phi() );
85 double etaRef = roiDescriptor->eta();
86 double phiRef = roiDescriptor->phi();
88 if ( std::abs( phiRef ) >
M_PI ) phiRef -= 2*
M_PI;
91 auto pClus = input.cluster;
93 float absEta = std::abs( pClus->eta() );
98 dEta = pClus->eta() - etaRef;
100 dPhi = std::abs( pClus->phi() - phiRef );
101 dPhi = ( dPhi <
M_PI ? dPhi : 2*
M_PI - dPhi );
102 eT_Cluster = pClus->et();
105 <<
" roi eta=" << etaRef <<
" DeltaEta=" << dEta
112 PassedCuts = PassedCuts + 1;
116 <<
" roi phi="<< phiRef <<
" DeltaPhi="<< dPhi
123 PassedCuts = PassedCuts + 1;
126 if ( cutIndex == -1 ) {
132 PassedCuts = PassedCuts + 1;
136 if ( eT_Cluster <
m_eTthr[cutIndex] ) {
140 PassedCuts = PassedCuts + 1;
153 const float absEta = std::abs(
eta);
155 auto binIterator = std::adjacent_find(
m_etabin.begin(),
m_etabin.end(), [=](
float left,
float right){ return left < absEta and absEta < right; } );
156 if ( binIterator ==
m_etabin.end() ) {
159 return binIterator -
m_etabin.begin();
163StatusCode TrigEgammaForwardPrecisionCaloHypoTool::decide( std::vector<ClusterInfo>& input )
const {
164 for (
auto& i: input ) {
171 return StatusCode::SUCCESS;
Scalar eta() const
pseudorapidity method
#define CHECK(...)
Evaluate an expression and check for errors.
Header file to be included by clients of the Monitored infrastructure.
TrigCompositeUtils::DecisionID numeric() const
numeric ID
Group of local monitoring quantities and retain correlation when filling histograms
Declare a monitored scalar variable.
It used to be useful piece of code for replacing actual SG with other store of similar functionality ...
bool passed(DecisionID id, const DecisionIDContainer &idSet)
checks if required decision ID is in the set of IDs in the container
void addDecisionID(DecisionID id, Decision *d)
Appends the decision (given as ID) to the decision object.