|  | ATLAS Offline Software
    | 
 
 
 
Algorithm to filter CaloCellContainer.  
 More...
#include <CaloCellFilterAlg.h>
|  | 
|  | CaloCellFilterAlg (const std::string &name, ISvcLocator *pSvcLocator) | 
|  | Regular Gaudi Algorithm constructor.  More... 
 | 
|  | 
| virtual StatusCode | initialize () | 
|  | Function executed before the event loop starts.  More... 
 | 
|  | 
| virtual StatusCode | execute () | 
|  | Function executed for each event.  More... 
 | 
|  | 
| virtual StatusCode | sysInitialize () override | 
|  | Override sysInitialize.  More... 
 | 
|  | 
| virtual const DataObjIDColl & | extraOutputDeps () const override | 
|  | Return the list of extra output dependencies.  More... 
 | 
|  | 
| ServiceHandle< StoreGateSvc > & | evtStore () | 
|  | The standard StoreGateSvc(event store) Returns (kind of) a pointer to theStoreGateSvc.  More...
 | 
|  | 
| const ServiceHandle< StoreGateSvc > & | evtStore () const | 
|  | The standard StoreGateSvc(event store) Returns (kind of) a pointer to theStoreGateSvc.  More...
 | 
|  | 
| const ServiceHandle< StoreGateSvc > & | detStore () const | 
|  | The standard StoreGateSvc/DetectorStoreReturns (kind of) a pointer to theStoreGateSvc.  More...
 | 
|  | 
| virtual StatusCode | sysStart () override | 
|  | Handle START transition.  More... 
 | 
|  | 
| virtual std::vector< Gaudi::DataHandle * > | inputHandles () const override | 
|  | Return this algorithm's input handles.  More... 
 | 
|  | 
| virtual std::vector< Gaudi::DataHandle * > | outputHandles () const override | 
|  | Return this algorithm's output handles.  More... 
 | 
|  | 
| Gaudi::Details::PropertyBase & | declareProperty (Gaudi::Property< T, V, H > &t) | 
|  | 
| Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &) | 
|  | Declare a new Gaudi property.  More... 
 | 
|  | 
| Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &) | 
|  | Declare a new Gaudi property.  More... 
 | 
|  | 
| Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &) | 
|  | 
| Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &) | 
|  | Declare a new Gaudi property.  More... 
 | 
|  | 
| Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc="none") | 
|  | Declare a new Gaudi property.  More... 
 | 
|  | 
| void | updateVHKA (Gaudi::Details::PropertyBase &) | 
|  | 
| MsgStream & | msg () const | 
|  | 
| MsgStream & | msg (const MSG::Level lvl) const | 
|  | 
| bool | msgLvl (const MSG::Level lvl) const | 
|  | 
|  | 
| Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &) | 
|  | specialization for handling Gaudi::Property<SG::VarHandleKey>  More... 
 | 
|  | 
| Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyArrayType &) | 
|  | specialization for handling Gaudi::Property<SG::VarHandleKeyArray>  More... 
 | 
|  | 
| Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleType &) | 
|  | specialization for handling Gaudi::Property<SG::VarHandleBase>  More... 
 | 
|  | 
| Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &t, const SG::NotHandleType &) | 
|  | specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>  More... 
 | 
|  | 
Algorithm to filter CaloCellContainer. 
- Author
- Hong Ma March 2010
$Revision$ $Date$ 
Definition at line 35 of file CaloCellFilterAlg.h.
◆ StoreGateSvc_t
◆ CaloCellFilterAlg()
      
        
          | CaloCellFilterAlg::CaloCellFilterAlg | ( | const std::string & | name, | 
        
          |  |  | ISvcLocator * | pSvcLocator | 
        
          |  | ) |  |  | 
      
 
 
◆ declareGaudiProperty() [1/4]
specialization for handling Gaudi::Property<SG::VarHandleKeyArray> 
Definition at line 170 of file AthCommonDataStore.h.
  175                                                        hndl.documentation());
 
 
 
 
◆ declareGaudiProperty() [2/4]
specialization for handling Gaudi::Property<SG::VarHandleKey> 
Definition at line 156 of file AthCommonDataStore.h.
  161                                                        hndl.documentation());
 
 
 
 
◆ declareGaudiProperty() [3/4]
specialization for handling Gaudi::Property<SG::VarHandleBase> 
Definition at line 184 of file AthCommonDataStore.h.
  189                                                        hndl.documentation());
 
 
 
 
◆ declareGaudiProperty() [4/4]
◆ declareProperty() [1/6]
Declare a new Gaudi property. 
- Parameters
- 
  
    | name | Name of the property. |  | hndl | Object holding the property value. |  | doc | Documentation string for the property. |  
 
This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class. 
Definition at line 245 of file AthCommonDataStore.h.
  250     this->declare(hndl.
vhKey());
 
  251     hndl.
vhKey().setOwner(
this);
 
  253     return PBASE::declareProperty(
name,hndl,
doc);
 
 
 
 
◆ declareProperty() [2/6]
Declare a new Gaudi property. 
- Parameters
- 
  
    | name | Name of the property. |  | hndl | Object holding the property value. |  | doc | Documentation string for the property. |  
 
This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class. 
Definition at line 221 of file AthCommonDataStore.h.
  229     return PBASE::declareProperty(
name,hndl,
doc);
 
 
 
 
◆ declareProperty() [3/6]
◆ declareProperty() [4/6]
Declare a new Gaudi property. 
- Parameters
- 
  
    | name | Name of the property. |  | property | Object holding the property value. |  | doc | Documentation string for the property. |  
 
This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty. 
Definition at line 333 of file AthCommonDataStore.h.
  338     return PBASE::declareProperty(
name, property, 
doc);
 
 
 
 
◆ declareProperty() [5/6]
Declare a new Gaudi property. 
- Parameters
- 
  
    | name | Name of the property. |  | property | Object holding the property value. |  | doc | Documentation string for the property. |  
 
This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray. 
Definition at line 352 of file AthCommonDataStore.h.
 
 
◆ declareProperty() [6/6]
◆ detStore()
◆ evtStore() [1/2]
◆ evtStore() [2/2]
◆ execute()
  
  | 
        
          | StatusCode CaloCellFilterAlg::execute | ( |  | ) |  |  | virtual | 
 
Function executed for each event. 
Definition at line 134 of file CaloCellFilterAlg.cxx.
  141    const CONTAINER* cellcoll = 
nullptr;
 
  149    CONTAINER::const_iterator f_cell = cellcoll->begin();
 
  150    CONTAINER::const_iterator l_cell = cellcoll->end();
 
  154    bool useNoiseCut = 
false;
 
  157    for( ; f_cell != l_cell; ++f_cell ) {
 
  163          const unsigned int iCaloNum =
 
  164             static_cast< unsigned int >( 
cell->caloDDE()->getSubCalo() );
 
  165          std::vector< unsigned int >::const_iterator theFound =
 
  172          const unsigned int iCaloSampling =
 
  173             static_cast< unsigned int >( 
cell->caloDDE()->getSampling() );
 
  174          std::vector< unsigned int >::const_iterator theFound =
 
  179       const float e = 
cell->energy(); 
 
  187             static const double epsilon = 0.001;
 
  191                   if( ! ( 
e > 
th ) ) 
continue;
 
  192                } 
else if( 
th < 0. ) {
 
  193                   if( ! ( std::abs( 
e ) > std::abs( 
th ) ) ) 
continue;
 
  199                float sigma = caloNoise->getNoise( 
cell->ID(), 
cell->gain() );
 
  217    return StatusCode::SUCCESS;
 
 
 
 
◆ extraDeps_update_handler()
Add StoreName to extra input/output deps as needed. 
use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given 
 
 
◆ extraOutputDeps()
  
  | 
        
          | const DataObjIDColl & AthAlgorithm::extraOutputDeps | ( |  | ) | const |  | overridevirtualinherited | 
 
Return the list of extra output dependencies. 
This list is extended to include symlinks implied by inheritance relations. 
Definition at line 50 of file AthAlgorithm.cxx.
   57   return Algorithm::extraOutputDeps();
 
 
 
 
◆ initialize()
  
  | 
        
          | StatusCode CaloCellFilterAlg::initialize | ( |  | ) |  |  | virtual | 
 
Function executed before the event loop starts. 
Definition at line 51 of file CaloCellFilterAlg.cxx.
   59                        "number of cells you want" );
 
   82       return StatusCode::SUCCESS;
 
   85          << 
" More than " << nSubCalo << 
" calo specified. " 
   86          << 
"Must be wrong. Stop.";
 
   87       return StatusCode::FAILURE;
 
   94                << 
"Invalid calo specification:"  
   96             return StatusCode::FAILURE;
 
  109       return StatusCode::SUCCESS;
 
  112          << 
" More than " << nCaloSamplings << 
" calo samplings specified. " 
  113          << 
"Must be wrong. Stop.";
 
  114       return StatusCode::FAILURE;
 
  121                << 
"Invalid calo sampling specification:"  
  123             return StatusCode::FAILURE;
 
  130    return StatusCode::SUCCESS;
 
 
 
 
◆ inputHandles()
Return this algorithm's input handles. 
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA. 
 
 
◆ msg() [1/2]
◆ msg() [2/2]
◆ msgLvl()
◆ outputHandles()
Return this algorithm's output handles. 
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA. 
 
 
◆ renounce()
◆ renounceArray()
◆ sysInitialize()
  
  | 
        
          | StatusCode AthAlgorithm::sysInitialize | ( |  | ) |  |  | overridevirtualinherited | 
 
 
◆ sysStart()
Handle START transition. 
We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container. 
 
 
◆ updateVHKA()
◆ m_caloNoiseKey
Initial value:{this,
        "CaloNoise", "", "Calo noise object name"}
Key of the CaloNoise Conditions data object. 
Typical values are '"electronicNoise', 'pileupNoise', or '"totalNoise' 
Definition at line 66 of file CaloCellFilterAlg.h.
 
 
◆ m_caloNums
  
  | 
        
          | std::vector< unsigned int > CaloCellFilterAlg::m_caloNums |  | private | 
 
 
◆ m_caloSamplings
  
  | 
        
          | std::vector< unsigned int > CaloCellFilterAlg::m_caloSamplings |  | private | 
 
 
◆ m_caloSamplingSelection
  
  | 
        
          | bool CaloCellFilterAlg::m_caloSamplingSelection |  | private | 
 
 
◆ m_caloSelection
  
  | 
        
          | bool CaloCellFilterAlg::m_caloSelection |  | private | 
 
 
◆ m_cellEnergyThreshold
  
  | 
        
          | float CaloCellFilterAlg::m_cellEnergyThreshold |  | private | 
 
 
◆ m_cellsName
  
  | 
        
          | std::string CaloCellFilterAlg::m_cellsName |  | private | 
 
 
◆ m_detStore
◆ m_emid
◆ m_evtStore
◆ m_extendedExtraObjects
  
  | 
        
          | DataObjIDColl AthAlgorithm::m_extendedExtraObjects |  | privateinherited | 
 
 
◆ m_fcalid
◆ m_hecid
◆ m_maxNCells
  
  | 
        
          | int CaloCellFilterAlg::m_maxNCells |  | private | 
 
 
◆ m_outputCellsName
  
  | 
        
          | std::string CaloCellFilterAlg::m_outputCellsName |  | private | 
 
 
◆ m_sigmaCut
  
  | 
        
          | float CaloCellFilterAlg::m_sigmaCut |  | private | 
 
 
◆ m_tileid
◆ m_varHandleArraysDeclared
◆ m_vhka
The documentation for this class was generated from the following files:
 
int m_maxNCells
Maximum number of cells to accept.
def retrieve(aClass, aKey=None)
std::string find(const std::string &s)
return a remapped string
float m_cellEnergyThreshold
threshold on cell energy for ntuple
@ VIEW_ELEMENTS
this data object is a view, it does not own its elmts
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
const LArFCAL_ID * m_fcalid
std::string m_outputCellsName
output Cell container
bool empty() const
Test if the key is blank.
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
virtual void setOwner(IDataHandleHolder *o)=0
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
virtual StatusCode sysInitialize() override
Override sysInitialize.
SG::ReadCondHandleKey< CaloNoise > m_caloNoiseKey
Key of the CaloNoise Conditions data object.
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
::StatusCode StatusCode
StatusCode definition for legacy code.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
float m_sigmaCut
cut on abs(E)/sigmaNoise (no cut if <0 )
#define CHECK(...)
Evaluate an expression and check for errors.
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
virtual void renounce()=0
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
value_type push_back(value_type pElem)
Add an element to the end of the collection.
StatusCode initialize(bool used=true)
Container class for CaloCell.
#define REPORT_MESSAGE(LVL)
Report a message.
DataObjIDColl m_extendedExtraObjects
Data object for each calorimeter readout cell.
const LArHEC_ID * m_hecid
#define ATH_MSG_WARNING(x)
DataVector adapter that acts like it holds const pointers.
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
AthAlgorithm()
Default constructor:
std::string m_cellsName
Cell container.
std::vector< unsigned int > m_caloNums
which calo to treat
bool m_caloSamplingSelection
std::vector< unsigned int > m_caloSamplings
which calo samplings to treat