|
ATLAS Offline Software
|
Go to the documentation of this file.
12 #include <boost/dynamic_bitset.hpp>
20 ISvcLocator * pSvcLocator) :
56 return StatusCode::FAILURE;
65 for (
const ToolHandle<ITauToolBase>&
tool :
m_tools) {
73 return StatusCode::SUCCESS;
83 ATH_CHECK(tauHandle.
record(std::make_unique<xAOD::TauJetContainer>(), std::make_unique<xAOD::TauJetAuxContainer>()));
87 ATH_CHECK(tauTrackHandle.
record(std::make_unique<xAOD::TauTrackContainer>(), std::make_unique<xAOD::TauTrackAuxContainer>()));
91 ATH_CHECK(tauShotClusHandle.
record(std::make_unique<xAOD::CaloClusterContainer>(), std::make_unique<xAOD::CaloClusterAuxContainer>()));
95 ATH_CHECK(tauShotPFOHandle.
record(std::make_unique<xAOD::PFOContainer>(), std::make_unique<xAOD::PFOAuxContainer>()));
99 boost::dynamic_bitset<> addedCellsMap;
104 Pi0CellContainer = tauPi0CellHandle.
ptr();
109 addedCellsMap.resize(hashMax,
false);
115 ATH_MSG_ERROR (
"Could not retrieve HiveDataObj with key " << jetHandle.
key());
116 return StatusCode::FAILURE;
125 for (
const xAOD::Jet* pSeed : *pSeedContainer) {
126 ATH_MSG_VERBOSE(
"Seeds eta:" << pSeed->eta() <<
", pt:" << pSeed->pt());
128 if (std::abs(pSeed->eta()) >
m_maxEta) {
143 pTau->
setJet(pSeedContainer, pSeed);
149 for (
const ToolHandle<ITauToolBase>&
tool :
m_tools) {
152 if (
tool->type() ==
"TauVertexFinder") {
153 sc =
tool->executeVertexFinder(*pTau);
154 }
else if (
tool->type() ==
"TauTrackFinder") {
155 sc =
tool->executeTrackFinder(*pTau, *pTauTrackCont);
156 }
else if (
tool->type() ==
"tauRecTools::TauTrackRNNClassifier") {
157 sc =
tool->executeTrackClassifier(*pTau, *pTauTrackCont);
163 sc = StatusCode::FAILURE;
166 }
else if (
tool->type() ==
"TauShotFinder") {
167 sc =
tool->executeShotFinder(*pTau, *tauShotClusContainer,
168 *tauShotPFOContainer);
169 }
else if (
tool->type() ==
"TauPi0CreateROI") {
170 sc =
tool->executePi0CreateROI(*pTau, *Pi0CellContainer, addedCellsMap);
172 sc =
tool->execute(*pTau);
178 if (
sc.isSuccess()) {
195 if(Pi0CellContainer) {
209 return StatusCode::SUCCESS;
def retrieve(aClass, aKey=None)
static StatusCode finalizeClusters(SG::WriteHandle< CaloClusterCellLinkContainer > &h, xAOD::CaloClusterContainer *pClusterColl)
Finalize clusters (move CaloClusterCellLink to a separate container).
const_pointer_type cptr()
Dereference the pointer.
size_t nAllTracks() const
@ VIEW_ELEMENTS
this data object is a view, it does not own its elmts
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_SCTDetEleCollKey
size_t nTracks(TauJetParameters::TauTrackFlag flag=TauJetParameters::TauTrackFlag::classifiedCharged) const
virtual StatusCode execute(const EventContext &ctx) const
#define ATH_MSG_VERBOSE(x)
bool empty() const
Test if the key is blank.
const DV * asDataVector() const
Return a pointer to this object, as a const DataVector.
SG::WriteHandleKey< xAOD::TauJetContainer > m_tauOutputContainer
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
An algorithm that can be simultaneously executed in multiple threads.
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
Gaudi::Property< int > m_maxNTracks
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_pixelDetEleCollKey
::StatusCode StatusCode
StatusCode definition for legacy code.
pointer_type ptr()
Dereference the pointer.
const CaloCell_ID * m_cellID
SG::WriteHandleKey< xAOD::PFOContainer > m_tauShotPFOOutputContainer
Class describing a tau jet.
SG::ReadCondHandleKey< InDetDD::TRT_DetElementContainer > m_trtDetEleContKey
SG::WriteHandleKey< xAOD::TauTrackContainer > m_tauTrackOutputContainer
TauJet_v3 TauJet
Definition of the current "tau version".
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
SG::WriteHandleKey< CaloClusterCellLinkContainer > m_tauShotClusLinkContainer
const T * back() const
Access the last element in the collection as an rvalue.
virtual bool isValid() override final
Can the handle be successfully dereferenced?
void setJet(const xAOD::JetContainer *cont, const xAOD::Jet *jet)
TauProcessorAlg(const std::string &name, ISvcLocator *pSvcLocator)
SG::ReadHandleKey< xAOD::JetContainer > m_jetInputContainer
virtual StatusCode initialize()
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.
virtual const std::string & key() const override final
Return the StoreGate ID for the referenced object.
const ToolHandleArray< ITauToolBase > m_tools
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
const ToolHandle< ICaloConstCellMakerTool > m_cellMakerTool
SG::WriteHandleKey< CaloConstCellContainer > m_tauPi0CellOutputContainer
SG::WriteHandleKey< xAOD::CaloClusterContainer > m_tauShotClusOutputContainer
Gaudi::Property< double > m_minPt
StatusCode record(std::unique_ptr< T > data)
Record a const object to the store.
CaloCellContainer that can accept const cell pointers.
void pop_back()
Remove the last element from the collection.
This is a "hash" representation of an Identifier. This encodes a 32 bit index which can be used to lo...
iterator erase(iterator position)
Remove element at a given position.
size_type size() const noexcept
Returns the number of elements in the collection.
Gaudi::Property< double > m_maxEta
size_type calo_cell_hash_max(void) const
cell 'global' hash table max size