  | 
  
    ATLAS Offline Software
    
   | 
 
 
 
 
#include <PFChargedFlowElementCreatorAlgorithm.h>
 | 
| StatusCode  | initialize () | 
|   | 
| StatusCode  | execute (const EventContext &) const | 
|   | 
| virtual StatusCode  | sysInitialize () override | 
|   | Override sysInitialize.  More...
  | 
|   | 
| virtual bool  | isClonable () const override | 
|   | Specify if the algorithm is clonable.  More...
  | 
|   | 
| virtual unsigned int  | cardinality () const override | 
|   | Cardinality (Maximum number of clones that can exist) special value 0 means that algorithm is reentrant.  More...
  | 
|   | 
| virtual StatusCode  | sysExecute (const EventContext &ctx) override | 
|   | Execute an algorithm.  More...
  | 
|   | 
| virtual const DataObjIDColl &  | extraOutputDeps () const override | 
|   | Return the list of extra output dependencies.  More...
  | 
|   | 
| virtual bool  | filterPassed (const EventContext &ctx) const | 
|   | 
| virtual void  | setFilterPassed (bool state, const EventContext &ctx) const | 
|   | 
| ServiceHandle< StoreGateSvc > &  | evtStore () | 
|   | The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.  More...
  | 
|   | 
| const ServiceHandle< StoreGateSvc > &  | evtStore () const | 
|   | The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.  More...
  | 
|   | 
| const ServiceHandle< StoreGateSvc > &  | detStore () const | 
|   | The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.  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 | 
|   | 
 | 
| void  | createChargedFlowElements (const eflowCaloObject &energyFlowCaloObject, bool addClusters, SG::WriteHandle< xAOD::FlowElementContainer > &chargedFlowElementContainerWriteHandle) const | 
|   | Create the charged PFO.  More...
  | 
|   | 
| 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...
  | 
|   | 
 | 
| Gaudi::Property< bool >  | m_eOverPMode {this,"EOverPMode",false,"Toggle EOverP algorithm mode, whereby no charged shower subtraction is performed"} | 
|   | Toggle EOverP algorithm mode, whereby no charged shower subtraction is performed.  More...
  | 
|   | 
| Gaudi::Property< bool >  | m_addCPData {this,"addCPData",false,"Toggle whether to decorate FlowElements with addutional data for Combined Performance studies "} | 
|   | Toggle whether to decorate FlowElements with addutional data for Combined Performance studies.  More...
  | 
|   | 
| SG::ReadHandleKey< eflowCaloObjectContainer >  | m_eflowCaloObjectContainerReadHandleKey {this,"eflowCaloObjectContainerName","eflowCaloObjects","ReadHandleKey for eflowCaloObjectContainer"} | 
|   | ReadHandleKey for eflowCaloObjectContainer.  More...
  | 
|   | 
| SG::WriteHandleKey< xAOD::FlowElementContainer >  | m_chargedFlowElementContainerWriteHandleKey {this,"FlowElementOutputName","JetETMissChargedParticleFlowObjects","WriteHandleKey for charged FlowElements"} | 
|   | WriteHandleKey for charged PFO.  More...
  | 
|   | 
| DataObjIDColl  | m_extendedExtraObjects | 
|   | Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.  More...
  | 
|   | 
| StoreGateSvc_t  | m_evtStore | 
|   | Pointer to StoreGate (event store by default)  More...
  | 
|   | 
| StoreGateSvc_t  | m_detStore | 
|   | Pointer to StoreGate (detector store by default)  More...
  | 
|   | 
| std::vector< SG::VarHandleKeyArray * >  | m_vhka | 
|   | 
| bool  | m_varHandleArraysDeclared | 
|   | 
◆ StoreGateSvc_t
◆ cardinality()
Cardinality (Maximum number of clones that can exist) special value 0 means that algorithm is reentrant. 
Override this to return 0 for reentrant algorithms. 
Override this to return 0 for reentrant algorithms. 
Definition at line 75 of file AthCommonReentrantAlgorithm.cxx.
 
 
◆ createChargedFlowElements()
Create the charged PFO. 
Each eflowCaloObject has a list of clusters for all the tracks it represents. We only want the subset of the clusters matched to this track, and collect these in thisTracks_trackClusterLinksSubtracted.
Definition at line 40 of file PFChargedFlowElementCreatorAlgorithm.cxx.
   43   for (
unsigned int iTrack = 0; iTrack < energyFlowCaloObject.
nTracks(); ++iTrack) {
 
   52     chargedFlowElementContainerWriteHandle->
push_back(thisFE);
 
   53     thisFE->
setSignalType(xAOD::FlowElement::SignalType::ChargedPFlow);
 
   59     std::vector<ElementLink<xAOD::IParticleContainer> > vecIParticleTrackLinkContainer;
 
   60     vecIParticleTrackLinkContainer.push_back(theIParticleTrackLink);
 
   67     std::pair<double,double> etaPhi(0.0,0.0);
 
   95     ATH_MSG_DEBUG(
"Created charged PFO with E, pt, eta and phi of " << thisFE->
e() << 
", " << thisFE->
pt() << 
", " << thisFE->
eta() << 
" and " << thisFE->
phi());
 
   99     accTracksExpectedEnergyDeposit(*thisFE) = efRecTrack->
getEExpect();
 
  110       std::vector<std::pair<eflowTrackClusterLink*,std::pair<float,float> > > trackClusterLinkPairs = energyFlowCaloObject.
efRecLink();
 
  112       ATH_MSG_DEBUG(
"Have got " << trackClusterLinkPairs.size() << 
" trackClusterLinkPairs");
 
  114       std::vector<eflowTrackClusterLink*> thisTracks_trackClusterLinks = efRecTrack->
getClusterMatches();
 
  116       ATH_MSG_DEBUG(
"Have got " << thisTracks_trackClusterLinks.size() << 
" cluster matches");
 
  122       std::vector<eflowTrackClusterLink*> thisTracks_trackClusterLinksSubtracted;
 
  125       std::vector<std::pair<ElementLink<xAOD::CaloClusterContainer>, 
double> > vectorClusterToSubtractedEnergies;
 
  127       for (
auto& trackClusterLink : thisTracks_trackClusterLinks){  
 
  128         for (
auto& trackClusterLinkPair : trackClusterLinkPairs){
 
  131           if (!
m_eOverPMode && trackClusterLinkPair.first == trackClusterLink && !std::isnan(trackClusterLinkPair.second.first)) {
 
  132             thisTracks_trackClusterLinksSubtracted.push_back(trackClusterLink);
 
  136               ATH_MSG_DEBUG(
"Will add cluster with E, ratio and absolute subtracted energy " << (*theOriginalClusterLink)->e() << 
", " << trackClusterLinkPair.second.first << 
", " << trackClusterLinkPair.second.second);
 
  137             if (theSisterClusterLink.
isValid()) vectorClusterToSubtractedEnergies.emplace_back(std::pair(theSisterClusterLink,trackClusterLinkPair.second.second));
 
  138             else vectorClusterToSubtractedEnergies.emplace_back(std::pair(theOriginalClusterLink,trackClusterLinkPair.second.second));
 
  140           else if (
m_eOverPMode && trackClusterLinkPair.first == trackClusterLink){
 
  141             thisTracks_trackClusterLinksSubtracted.push_back(trackClusterLink);
 
  145             ATH_MSG_DEBUG(
"Will add cluster with E, ratio and absolute subtracted energy " << (*theOriginalClusterLink)->e() << 
", " << 1.0 << 
", " << 0.0);
 
  146             if (theSisterClusterLink.
isValid()) vectorClusterToSubtractedEnergies.emplace_back(theSisterClusterLink,0.0);
 
  147             else vectorClusterToSubtractedEnergies.emplace_back(theOriginalClusterLink,0.0);
 
  153       std::sort(vectorClusterToSubtractedEnergies.begin(),vectorClusterToSubtractedEnergies.end(), [](
auto const& 
a, 
auto const&
b){return a.second > b.second;});
 
  155       std::vector<ElementLink<xAOD::IParticleContainer> > theClusters;
 
  156       std::vector<float> theClusterWeights;
 
  157       for (
auto thePair : vectorClusterToSubtractedEnergies){
 
  159         theClusters.push_back(theIParticleTrackLink);
 
  160         theClusterWeights.push_back(thePair.second);
 
  177       accIsRecovered(*thisFE) = efRecTrack->
isRecovered();
 
  186       accPull15(*thisFE) = efRecTrack->
getpull15();
 
 
 
 
◆ 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);
 
 
 
 
◆ 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.
 
 
◆ 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.
 
 
◆ 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 PFChargedFlowElementCreatorAlgorithm::execute  | 
          ( | 
          const EventContext &  | 
          ctx | ) | 
           const | 
        
      
 
Definition at line 23 of file PFChargedFlowElementCreatorAlgorithm.cxx.
   25   ATH_MSG_DEBUG(
"Starting PFOChargedCreatorAlgorithm::execute");
 
   28   ATH_CHECK(chargedFlowElementContainerWriteHandle.record(std::make_unique<xAOD::FlowElementContainer>(),std::make_unique<xAOD::FlowElementAuxContainer>()));
 
   32   for (
const auto *
const thisEflowCaloObject : *eflowCaloObjectContainerReadHandle) 
createChargedFlowElements(*thisEflowCaloObject,
true,chargedFlowElementContainerWriteHandle);
 
   34   std::sort(chargedFlowElementContainerWriteHandle->begin(), chargedFlowElementContainerWriteHandle->end(), [] (
const xAOD::FlowElement* flowElement1, 
const xAOD::FlowElement* flowElement2) {return flowElement1->pt()>flowElement2->pt();});
 
   36   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()
Return the list of extra output dependencies. 
This list is extended to include symlinks implied by inheritance relations. 
Definition at line 94 of file AthCommonReentrantAlgorithm.cxx.
 
 
◆ filterPassed()
◆ initialize()
      
        
          | StatusCode PFChargedFlowElementCreatorAlgorithm::initialize  | 
          ( | 
           | ) | 
           | 
        
      
 
 
◆ 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. 
 
 
◆ isClonable()
◆ 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()
◆ setFilterPassed()
◆ sysExecute()
Execute an algorithm. 
We override this in order to work around an issue with the Algorithm base class storing the event context in a member variable that can cause crashes in MT jobs. 
Definition at line 85 of file AthCommonReentrantAlgorithm.cxx.
 
 
◆ sysInitialize()
Override sysInitialize. 
Override sysInitialize from the base class.
Loop through all output handles, and if they're WriteCondHandles, automatically register them and this Algorithm with the CondSvc
Scan through all outputHandles, and if they're WriteCondHandles, register them with the CondSvc 
Reimplemented from AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >.
Reimplemented in InputMakerBase, and HypoBase.
Definition at line 61 of file AthCommonReentrantAlgorithm.cxx.
  110   if (
sc.isFailure()) {
 
  118       if ( cs.retrieve().isFailure() ) {
 
  120         return StatusCode::SUCCESS;
 
  122       if (cs->regHandle(
this,*
h).isFailure()) {
 
  123         sc = StatusCode::FAILURE;
 
  124         ATH_MSG_ERROR(
"unable to register WriteCondHandle " << 
h->fullKey()
 
 
 
 
◆ 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_addCPData
  
  
      
        
          | Gaudi::Property<bool> PFChargedFlowElementCreatorAlgorithm::m_addCPData {this,"addCPData",false,"Toggle whether to decorate FlowElements with addutional data for Combined Performance studies "} | 
         
       
   | 
  
private   | 
  
 
 
◆ m_chargedFlowElementContainerWriteHandleKey
  
  
      
        
          | SG::WriteHandleKey<xAOD::FlowElementContainer> PFChargedFlowElementCreatorAlgorithm::m_chargedFlowElementContainerWriteHandleKey {this,"FlowElementOutputName","JetETMissChargedParticleFlowObjects","WriteHandleKey for charged FlowElements"} | 
         
       
   | 
  
private   | 
  
 
 
◆ m_detStore
◆ m_eflowCaloObjectContainerReadHandleKey
◆ m_eOverPMode
  
  
      
        
          | Gaudi::Property<bool> PFChargedFlowElementCreatorAlgorithm::m_eOverPMode {this,"EOverPMode",false,"Toggle EOverP algorithm mode, whereby no charged shower subtraction is performed"} | 
         
       
   | 
  
private   | 
  
 
 
◆ m_evtStore
◆ m_extendedExtraObjects
Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks. 
Empty if no symlinks were found. 
Definition at line 114 of file AthCommonReentrantAlgorithm.h.
 
 
◆ m_varHandleArraysDeclared
◆ m_vhka
The documentation for this class was generated from the following files:
 
This class extends the information about a xAOD::CaloCluster.
 
virtual double pt() const override final
The transverse momentum ( ) of the particle.
 
virtual double m() const override final
The invariant mass of the particle..
 
const std::vector< std::pair< eflowTrackClusterLink *, std::pair< float, float > > > & efRecLink() const
 
const std::vector< float > & getRadiusCellOrderVector() const
 
Helper class to provide type-safe access to aux data.
 
bool isInDenseEnvironment() const
 
float charge() const
Returns the charge.
 
virtual double eta() const override final
The pseudorapidity ( ) of the particle.
 
void setSignalType(signal_t t)
 
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce(T &h)
 
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
ElementLink< xAOD::TrackParticleContainer > getTrackElemLink() const
 
virtual double phi() const override
The azimuthal angle ( ) of the particle.
 
virtual double pt() const override
 
SG::WriteHandleKey< xAOD::FlowElementContainer > m_chargedFlowElementContainerWriteHandleKey
WriteHandleKey for charged PFO.
 
void setOtherObjectLinks(const std::vector< ElementLink< IParticleContainer >> &elV)
 
bool isValid() const
Test to see if the link can be dereferenced.
 
const std::vector< float > & getDRPrimes() const
 
SG::ReadHandleKey< eflowCaloObjectContainer > m_eflowCaloObjectContainerReadHandleKey
ReadHandleKey for eflowCaloObjectContainer.
 
virtual void setOwner(IDataHandleHolder *o)=0
 
This class extends the information about a xAOD::Track.
 
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
 
const std::vector< eflowTrackClusterLink * > & getClusterMatches() const
 
virtual const DataObjIDColl & extraOutputDeps() const override
Return the list of extra output dependencies.
 
Gaudi::Property< bool > m_addCPData
Toggle whether to decorate FlowElements with addutional data for Combined Performance studies.
 
const eflowRecTrack * efRecTrack(int i) const
 
void createChargedFlowElements(const eflowCaloObject &energyFlowCaloObject, bool addClusters, SG::WriteHandle< xAOD::FlowElementContainer > &chargedFlowElementContainerWriteHandle) const
Create the charged PFO.
 
const std::vector< float > & getAvgEDensityCellOrderVector() const
 
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
 
::StatusCode StatusCode
StatusCode definition for legacy code.
 
bool isSubtracted() const
 
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
 
FlowElement_v1 FlowElement
Definition of the current "pfo version".
 
virtual StatusCode sysExecute(const EventContext &ctx) override
Execute an algorithm.
 
double getEExpect() const
 
xAOD::CaloCluster * getCluster()
 
ElementLink< xAOD::CaloClusterContainer > getOriginalClusElementLink() const
 
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
 
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
 
const std::vector< std::pair< ElementLink< CaloCellContainer >, double > > & getSubtractedCaloCells() const
 
virtual void renounce()=0
 
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
 
const xAOD::TrackParticle * getTrack() const
 
void setChargedObjectLinks(const std::vector< ElementLink< IParticleContainer >> &elV)
 
const std::pair< float, float > getEM2etaPhi() const
 
virtual double e() const override
The total energy of the particle.
 
Gaudi::Property< bool > m_eOverPMode
Toggle EOverP algorithm mode, whereby no charged shower subtraction is performed.
 
value_type push_back(value_type pElem)
Add an element to the end of the collection.
 
const eflowTrackCaloPoints & getTrackCaloPoints() const
 
virtual double eta() const override
The pseudorapidity ( ) of the particle.
 
void sort(typename std::reverse_iterator< DataModel_detail::iterator< DVL > > beg, typename std::reverse_iterator< DataModel_detail::iterator< DVL > > end, const Compare &comp)
Specialization of sort for DataVector/List.
 
#define ATH_MSG_WARNING(x)
 
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
 
void setP4(float pt, float eta, float phi, float m)
 
virtual StatusCode sysInitialize() override
Override sysInitialize.
 
DataObjIDColl m_extendedExtraObjects
Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.
 
const std::vector< int > & getLayerCellOrderVector() const
 
virtual double phi() const override final
The azimuthal angle ( ) of the particle (has range  to .)
 
A detector object made of other lower level object(s)