 |
ATLAS Offline Software
|
#include <Run2ToRun3TrigNavConverterV2.h>
|
| Run2ToRun3TrigNavConverterV2 (const std::string &name, ISvcLocator *pSvcLocator) |
|
virtual | ~Run2ToRun3TrigNavConverterV2 () override |
|
virtual StatusCode | initialize () override |
|
virtual StatusCode | execute (const EventContext &context) const override |
|
virtual StatusCode | finalize () override |
|
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 |
|
|
StatusCode | extractTECtoChainMapping (TEIdToChainsMap_t &allTES, TEIdToChainsMap_t &finalTEs) const |
|
StatusCode | mirrorTEsStructure (ConvProxySet_t &, const HLT::TrigNavStructure &run2Nav) const |
|
StatusCode | associateChainsToProxies (ConvProxySet_t &, const TEIdToChainsMap_t &) const |
|
StatusCode | cureUnassociatedProxies (ConvProxySet_t &) const |
|
StatusCode | removeUnassociatedProxies (ConvProxySet_t &) const |
|
StatusCode | doCompression (ConvProxySet_t &convProxies, const HLT::TrigNavStructure &run2Nav) const |
|
StatusCode | collapseFeaturesProxies (ConvProxySet_t &convProxies, const HLT::TrigNavStructure &run2Nav) const |
|
StatusCode | collapseFeaturelessProxies (ConvProxySet_t &) const |
|
StatusCode | removeTopologicalProxies (ConvProxySet_t &) const |
|
template<typename MAP > |
StatusCode | collapseProxies (ConvProxySet_t &, MAP &) const |
|
StatusCode | fillRelevantFeatures (ConvProxySet_t &convProxies, const HLT::TrigNavStructure &run2Nav) const |
|
StatusCode | fillRelevantTracks (ConvProxySet_t &convProxies) const |
|
StatusCode | fillRelevantRois (ConvProxySet_t &convProxies, const HLT::TrigNavStructure &run2Nav) const |
|
StatusCode | createIMHNodes (ConvProxySet_t &, xAOD::TrigCompositeContainer &, const EventContext &) const |
|
StatusCode | createL1Nodes (const ConvProxySet_t &convProxies, xAOD::TrigCompositeContainer &decisions, const EventContext &context) const |
|
StatusCode | createSFNodes (const ConvProxySet_t &, xAOD::TrigCompositeContainer &, const TEIdToChainsMap_t &finalTEs, const EventContext &context) const |
|
StatusCode | updateTerminusNode (xAOD::TrigCompositeContainer &, const EventContext &context) const |
|
StatusCode | linkFeaNode (ConvProxySet_t &convProxies, xAOD::TrigCompositeContainer &, const HLT::TrigNavStructure &run2Nav, const EventContext &context) const |
|
StatusCode | linkRoiNode (ConvProxySet_t &convProxies, const HLT::TrigNavStructure &run2Nav) const |
|
StatusCode | linkTrkNode (ConvProxySet_t &convProxies, const HLT::TrigNavStructure &run2Nav) const |
|
std::vector< HLT::TriggerElement::FeatureAccessHelper > | filterFEAs (const std::vector< HLT::TriggerElement::FeatureAccessHelper > &feaVector, const HLT::TrigNavStructure &navigationDecoder) const |
| < both method skip TrigPassBits More...
|
|
uint64_t | feaToHash (const std::vector< HLT::TriggerElement::FeatureAccessHelper > &feaVector, const HLT::TriggerElement *te_ptr, const HLT::TrigNavStructure &navigationDecoder) const |
| returns true if this particular feature is to be saved (linked) More...
|
|
bool | feaToSave (const HLT::TriggerElement::FeatureAccessHelper &fea, const std::string &sgName) const |
|
bool | roiToSave (const HLT::TrigNavStructure &run2Nav, const HLT::TriggerElement::FeatureAccessHelper &fea) const |
|
void | printProxies (const ConvProxySet_t &proxies, std::function< bool(const ConvProxy *)> selector=[](const ConvProxy *){return true;}, const std::vector< std::function< void(const ConvProxy *)>> &printers={}) const |
|
size_t | is2LegTopoChain (const TrigConf::HLTChain *ptrChain) const |
|
std::size_t | getFeaSize (const ConvProxy &) const |
|
std::pair< std::size_t, std::size_t > | getHighestPtObject (const ConvProxy &, const HLT::TrigNavStructure &) const |
| Return pair of indices (feature index in proxy->features vector, object index) identifying the highest pT object attached to the proxy. More...
|
|
StatusCode | allProxiesHaveChain (const ConvProxySet_t &) const |
|
StatusCode | allProxiesConnected (const ConvProxySet_t &) const |
|
StatusCode | numberOfHNodesPerProxyNotExcessive (const ConvProxySet_t &) const |
|
StatusCode | noUnconnectedHNodes (const xAOD::TrigCompositeContainer &) const |
|
std::tuple< uint32_t, CLID, std::string > | getSgKey (const HLT::TrigNavStructure &navigationDecoder, const HLT::TriggerElement::FeatureAccessHelper &helper) const |
|
StatusCode | bjetMuChainConfigDecoder (TEIdToChainsMap_t &allTES, TEIdToChainsMap_t &finalTEs, const TrigConf::HLTChain *ptrChain) 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...
|
|
|
SG::ReadHandleKey< xAOD::TrigNavigation > | m_trigNavKey {this, "TrigNavReadKey", "TrigNavigation"} |
|
PublicToolHandle< Trig::TrigDecisionTool > | m_tdt {this, "TrigDecisionTool", "", "When enabled read navigation from TDT/off by default"} |
|
ServiceHandle< TrigConf::IHLTConfigSvc > | m_configSvc {this, "TrigConfigSvc", "TrigConf::xAODConfigSvc/xAODConfigSvc", "Trigger configuration service"} |
|
ServiceHandle< IClassIDSvc > | m_clidSvc {this, "ClassIDSvc", "ClassIDSvc", "Service to translate CLID to class name"} |
|
Gaudi::Property< bool > | m_doSelfValidation {this, "doSelfValidation", false, "Run consistency checks after stages of conversion (slows down the alg)"} |
|
Gaudi::Property< bool > | m_doCompression {this, "doCompression", false, "Collapse navigation elements to save ouput space"} |
|
Gaudi::Property< bool > | m_doLinkFeatures {this, "doLinkFeatures", true, "Add links to objects, setting it false makes sense when running tests"} |
|
Gaudi::Property< bool > | m_includeTauTrackFeatures {this, "addTauTracks", false, "Add Tau Track collection as feature element"} |
|
Gaudi::Property< size_t > | m_hNodesPerProxyThreshold {this, "hNodesPerProxyThreshhold", 15, "Limit number of H nodes per TE (if exceeded conversion results in an error)"} |
|
Gaudi::Property< std::vector< std::string > > | m_chainsToSave {this, "Chains", {}, "If not specified, all chains are handled"} |
|
Gaudi::Property< std::vector< std::string > > | m_collectionsToSave {this, "Collections", {}} |
|
Gaudi::Property< std::vector< std::string > > | m_roisToSave {this, "Rois", {}} |
|
SG::WriteHandleKey< xAOD::TrigCompositeContainer > | m_trigOutputNavKey {this, "OutputNavKey", "HLTNav_R2ToR3Summary"} |
|
std::mutex | m_configUpdateMutex |
|
TEIdToChainsMap_t | m_allTEIdsToChains |
|
TEIdToChainsMap_t | m_finalTEIdsToChains |
|
std::function< void(const ConvProxy *)> | m_chainIdsPrinter = [&](const ConvProxy* p){ for (auto id: p->passChains ) ATH_MSG_DEBUG("chain id " << id); } |
|
std::function< void(const ConvProxy *)> | m_teIDPrinter = [&](const ConvProxy* p){ ATH_MSG_DEBUG("TE id " << TrigConf::HLTUtils::hash2string(p->te->getId())); } |
|
std::map< CLID, std::set< std::string > > | m_collectionsToSaveDecoded |
|
std::vector< std::string > | m_setRoiName |
|
CLID | m_roIDescriptorCLID {0} |
|
CLID | m_roIDescriptorCollectionCLID {0} |
|
CLID | m_TrigRingerRingsCLID {0} |
|
CLID | m_TrigRingerRingsContainerCLID {0} |
|
CLID | m_TrigEMClusterCLID {0} |
|
CLID | m_TrigEMClusterContainerCLID {0} |
|
CLID | m_CaloClusterCLID {0} |
|
CLID | m_CaloClusterContainerCLID {0} |
|
CLID | m_TrackParticleContainerCLID {0} |
|
CLID | m_TauTrackContainerCLID {0} |
|
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
◆ Run2ToRun3TrigNavConverterV2()
Run2ToRun3TrigNavConverterV2::Run2ToRun3TrigNavConverterV2 |
( |
const std::string & |
name, |
|
|
ISvcLocator * |
pSvcLocator |
|
) |
| |
◆ ~Run2ToRun3TrigNavConverterV2()
Run2ToRun3TrigNavConverterV2::~Run2ToRun3TrigNavConverterV2 |
( |
| ) |
|
|
overridevirtual |
◆ allProxiesConnected()
StatusCode Run2ToRun3TrigNavConverterV2::allProxiesConnected |
( |
const ConvProxySet_t & |
proxies | ) |
const |
|
private |
Definition at line 1478 of file Run2ToRun3TrigNavConverterV2.cxx.
1480 for (
auto p : proxies)
1482 if (
p->children.empty() and
p->parents.empty() and not
p->runChains.empty())
1484 ATH_MSG_ERROR(
"Orphanted proxy N chains run:" <<
p->runChains.size());
1485 return StatusCode::FAILURE;
1489 return StatusCode::SUCCESS;
◆ allProxiesHaveChain()
StatusCode Run2ToRun3TrigNavConverterV2::allProxiesHaveChain |
( |
const ConvProxySet_t & |
proxies | ) |
const |
|
private |
Definition at line 1464 of file Run2ToRun3TrigNavConverterV2.cxx.
1466 for (
auto p : proxies)
1468 if (
p->runChains.empty())
1471 return StatusCode::FAILURE;
1475 return StatusCode::SUCCESS;
◆ associateChainsToProxies()
Definition at line 665 of file Run2ToRun3TrigNavConverterV2.cxx.
668 for (
auto &ptrConvProxy : convProxies)
670 auto teId = ptrConvProxy->te->getId();
671 bool teActive = ptrConvProxy->te->getActiveState();
673 if (
iter != allTEs.end())
675 ptrConvProxy->runChains.insert(
iter->second.begin(),
iter->second.end());
678 ptrConvProxy->passChains.insert(
iter->second.begin(),
iter->second.end());
682 for (
auto &objTeIdToChain : allTEs)
684 if (
teId == objTeIdToChain.first)
686 for (
auto &chainId : objTeIdToChain.second)
688 (ptrConvProxy->runChains).insert(chainId);
694 return StatusCode::SUCCESS;
◆ bjetMuChainConfigDecoder()
Definition at line 544 of file Run2ToRun3TrigNavConverterV2.cxx.
547 std::vector<unsigned int> muons;
548 std::vector<unsigned int>
jets;
549 bool switchedTojets =
false;
550 for (
auto ptrHLTSignature : ptrChain->
signatures()) {
551 for (
auto ptrHLTTE : ptrHLTSignature->outputTEs()) {
552 if ( ptrHLTTE->name().find(
"_mu") == std::string::npos ) {
553 switchedTojets =
true;
557 jets.push_back(ptrHLTTE->id());
559 muons.push_back(ptrHLTTE->id());
567 finalTEs[muons[0]].insert(chainId);
569 finalTEs[
jets[0]].insert(chainId);
574 allTEs[muons[
index]].insert(chainId);
578 return StatusCode::SUCCESS;
◆ 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.
◆ collapseFeaturelessProxies()
StatusCode Run2ToRun3TrigNavConverterV2::collapseFeaturelessProxies |
( |
ConvProxySet_t & |
convProxies | ) |
const |
|
private |
Definition at line 852 of file Run2ToRun3TrigNavConverterV2.cxx.
855 struct ParentChildCharacteristics
859 size_t distanceFromParent = 0;
860 bool operator<(
const ParentChildCharacteristics &rhs)
const
863 return parent < rhs.parent;
864 if (child != rhs.child)
865 return child < rhs.child;
866 return distanceFromParent < rhs.distanceFromParent;
869 const size_t beforeCount = convProxies.size();
870 std::map<ParentChildCharacteristics, ConvProxySet_t> groupedProxies;
871 for (
auto proxy : convProxies)
884 if (
proxy->children.size() == 1 and
885 std::all_of(
proxy->children.begin(),
proxy->children.end(), hasSomeFeatures ) and
886 proxy->parents.size() == 1 and
887 std::all_of(
proxy->parents.begin(),
proxy->parents.end(), hasSomeFeatures )
891 groupedProxies[{*(
proxy->parents.begin()), *(
proxy->children.begin()), 0}].insert(
proxy);
898 for (
auto pp :
proxy->parents)
903 for (
auto cp :
proxy->children)
912 ATH_MSG_DEBUG(
"Proxies without features collapsing reduces size from " << beforeCount <<
" to " << convProxies.size());
913 return StatusCode::SUCCESS;
◆ collapseFeaturesProxies()
Definition at line 804 of file Run2ToRun3TrigNavConverterV2.cxx.
807 const size_t beforeCount = convProxies.size();
808 std::map<uint64_t, ConvProxySet_t> feaToProxyMap;
809 for (
auto proxy : convProxies)
822 for (
auto [feaHash, proxies] : feaToProxyMap)
824 auto first = *proxies.begin();
825 for (
auto p : proxies)
828 filterFEAs(
p->te->getFeatureAccessHelpers(), run2Nav))
830 ATH_MSG_ERROR(
"Proxies grouped by FEA hash have actually distinct features (specific FEAs are different)");
831 for (
auto id:
p->passChains )
ATH_MSG_ERROR(
"... chain id for this proxy " <<
id);
833 for (
auto fea:
first->te->getFeatureAccessHelpers() ) {
836 for (
auto fea:
p->te->getFeatureAccessHelpers() ) {
840 return StatusCode::FAILURE;
847 ATH_MSG_DEBUG(
"Proxies with features collapsing reduces size from " << beforeCount <<
" to " << convProxies.size());
849 return StatusCode::SUCCESS;
◆ collapseProxies()
template<typename MAP >
StatusCode Run2ToRun3TrigNavConverterV2::collapseProxies |
( |
ConvProxySet_t & |
convProxies, |
|
|
MAP & |
keyToProxyMap |
|
) |
| const |
|
private |
Definition at line 775 of file Run2ToRun3TrigNavConverterV2.cxx.
778 std::vector<ConvProxy *> todelete;
779 for (
auto &[
key, proxies] : keyToProxyMap)
781 if (proxies.size() > 1)
783 ATH_MSG_DEBUG(
"Merging " << proxies.size() <<
" similar proxies");
784 for (
auto p : proxies)
786 if (
p->mergeAllowed(*proxies.begin()))
788 (*proxies.begin())->
merge(
p);
789 todelete.push_back(
p);
795 for (
auto proxy : todelete)
797 convProxies.erase(
proxy);
801 return StatusCode::SUCCESS;
◆ createIMHNodes()
Definition at line 1049 of file Run2ToRun3TrigNavConverterV2.cxx.
1051 for (
auto &
proxy : convProxies)
1054 for (
auto chainId :
proxy->runChains)
1059 for (
auto chainId :
proxy->passChains)
1067 for (
auto &
proxy : convProxies)
1069 for (
auto &parentProxy :
proxy->parents)
1075 return StatusCode::SUCCESS;
◆ createL1Nodes()
Definition at line 1194 of file Run2ToRun3TrigNavConverterV2.cxx.
1198 auto makeL1Node = [&
decisions, &context](
auto firstDecisionNode,
auto chainIds)
1202 for (
auto chainId : chainIds)
1211 for (
auto &
proxy : convProxies)
1214 if (
proxy->parents.empty())
1221 return StatusCode::SUCCESS;
◆ createSFNodes()
Definition at line 1078 of file Run2ToRun3TrigNavConverterV2.cxx.
1085 sfNode->setName(
"SF");
1088 for (
auto chainId : chainIds)
1095 else if (chainId.numeric() == idStore)
1105 if (
proxy->hNode.empty())
1108 makeSingleSFNode(
proxy->imNode,
proxy->runChains, idToStore);
1113 for (
auto &hNode :
proxy->hNode)
1115 makeSingleSFNode(hNode,
proxy->passChains, idToStore);
1120 for (
auto proxy : convProxies)
1123 if (
proxy->children.empty())
1131 std::vector<TCU::DecisionID> toRetain;
1134 auto whereInMap = terminalIds.find(
teId);
1135 if (whereInMap != terminalIds.end())
1137 toRetain.insert(toRetain.end(), whereInMap->second.begin(), whereInMap->second.end());
1140 for (
auto chainIdstore : toRetain)
1142 makeSFNodes(
proxy, chainIdstore);
1149 return StatusCode::SUCCESS;
◆ cureUnassociatedProxies()
StatusCode Run2ToRun3TrigNavConverterV2::cureUnassociatedProxies |
( |
ConvProxySet_t & |
convProxies | ) |
const |
|
private |
Definition at line 697 of file Run2ToRun3TrigNavConverterV2.cxx.
705 size_t numberOfUpdates = 0;
706 for (
auto p : convProxies)
708 for (
auto child :
p->children)
710 size_t startSize =
p->runChains.size();
713 if (startSize !=
p->runChains.size())
721 ATH_MSG_DEBUG(
"Needed to propagate chains from " << numberOfUpdates <<
" child(ren)");
722 if (numberOfUpdates == 0)
727 return StatusCode::SUCCESS;
◆ 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()
◆ doCompression()
◆ evtStore() [1/2]
◆ evtStore() [2/2]
◆ execute()
StatusCode Run2ToRun3TrigNavConverterV2::execute |
( |
const EventContext & |
context | ) |
const |
|
overridevirtual |
Definition at line 249 of file Run2ToRun3TrigNavConverterV2.cxx.
266 standaloneNav.
deserialize(navReadHandle->serialized());
267 run2NavigationPtr = &standaloneNav;
271 run2NavigationPtr =
m_tdt->ExperimentalAndExpertMethods().getNavigation();
295 ATH_MSG_DEBUG(
"Removed proxies to chains that are not converted, remaining number of elements " << convProxies.size());
310 auto decisionOutput = outputNavigation.
ptr();
333 ATH_MSG_DEBUG(
"Conversion done, from " << convProxies.size() <<
" elements to " << decisionOutput->size() <<
" elements");
339 for (
auto o: *decisionOutput) {
345 for (
auto proxy : convProxies)
350 return StatusCode::SUCCESS;
◆ extractTECtoChainMapping()
Definition at line 397 of file Run2ToRun3TrigNavConverterV2.cxx.
405 std::string
chainName = ptrChain->name();
424 std::map<HLT::te_id_type, HLT::te_id_type> etcutReplacementTEs;
425 auto etcutReplacement = [&etcutReplacementTEs](
HLT::te_id_type in) {
auto out = etcutReplacementTEs.find(in);
return (
out == etcutReplacementTEs.end() ? in :
out->second ); };
426 if (
chainName.find(
"etcut") != std::string::npos ) {
427 std::set<size_t> positionsOfEtCutLegs;
430 ATH_MSG_DEBUG(
"EtCut chains hack, chain with two etcut legs ");
431 positionsOfEtCutLegs.insert({0, 1});
433 ATH_MSG_DEBUG(
"EtCut chains hack, egamma chain with second etcut leg ");
434 positionsOfEtCutLegs.insert({1});
437 positionsOfEtCutLegs.insert({0});
441 std::map<size_t, HLT::te_id_type> positionToDesiredIDmap;
442 for (
auto ptrHLTSignature : ptrChain->signatures()) {
444 for (
auto ptrHLTTE : ptrHLTSignature->outputTEs()) {
445 if (positionsOfEtCutLegs.count(position) and positionToDesiredIDmap.find(position) != positionToDesiredIDmap.end() ) {
446 etcutReplacementTEs[ptrHLTTE->id()] = positionToDesiredIDmap[position];
449 if ( ptrHLTTE->name().find(
"calocalib") != std::string::npos and positionsOfEtCutLegs.count(position) ) {
450 positionToDesiredIDmap[position] = ptrHLTTE->id();
461 for (
auto ptrHLTSignature : ptrChain->signatures()) {
462 for (
auto ptrHLTTE : ptrHLTSignature->outputTEs()) {
463 unsigned int teId = etcutReplacement(ptrHLTTE->id());
464 allTEs[
teId].insert(chainId);
465 if (ptrHLTSignature == ptrChain->signatures().back()) {
466 finalTEs[
teId].insert(chainId);
467 ATH_MSG_DEBUG(
"TE will be used to mark final chain decision " << ptrHLTTE->name() <<
" chain " <<
chainName );
486 std::vector<size_t> mult_hack;
489 ptrChain->set_leg_multiplicities(mult_hack);
494 std::vector<size_t> mult_hack;
497 ptrChain->set_leg_multiplicities(mult_hack);
501 std::vector<unsigned int> teIdsLastHealthyStepIds;
503 for (
auto ptrHLTSignature : ptrChain->signatures())
505 std::vector<int> teCounts;
506 std::vector<unsigned int> teIds;
507 unsigned int lastSeenId = 0;
508 for (
auto ptrHLTTE : ptrHLTSignature->outputTEs())
510 if ( lastSeenId != ptrHLTTE->id()) {
511 teCounts.push_back(1);
512 teIds.push_back(ptrHLTTE->id());
516 lastSeenId = ptrHLTTE->id();
519 ATH_MSG_DEBUG(
"TE multiplicities seen in this step " << teCounts);
523 if ( multiplicityCounts ) {
524 teIdsLastHealthyStepIds = teIds;
525 ATH_MSG_DEBUG(
"There is a match, will assign chain leg IDs to TEs " << teCounts <<
" " << teIds);
526 for (
size_t legNumber = 0; legNumber < teIds.size(); ++ legNumber){
528 allTEs[etcutReplacement(teIds[legNumber])].insert(chainLegId);
532 for (
size_t legNumber = 0; legNumber < teIdsLastHealthyStepIds.size(); ++ legNumber ) {
535 ATH_MSG_DEBUG(
"created leg id " << chainLegId <<
" that will replace TE ID " << etcutReplacement(teIdsLastHealthyStepIds[legNumber]));
536 finalTEs[etcutReplacement(teIdsLastHealthyStepIds[legNumber])].insert(chainLegId);
540 ATH_MSG_DEBUG(
"Recognised " << allTEs.size() <<
" kinds of TEs and among them " << finalTEs.size() <<
" final types");
541 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.
◆ feaToHash()
returns true if this particular feature is to be saved (linked)
Definition at line 1413 of file Run2ToRun3TrigNavConverterV2.cxx.
1418 for (
auto fea :
filterFEAs(feaVector, navigationDecoder))
1420 ATH_MSG_VERBOSE(
"Including FEA in hash CLID: " << fea.getCLID() <<
" te Id: " << te_ptr->
getId());
1421 boost::hash_combine(
hash, fea.getCLID());
1422 boost::hash_combine(
hash, fea.getIndex().subTypeIndex());
1423 boost::hash_combine(
hash, fea.getIndex().objectsBegin());
1424 boost::hash_combine(
hash, fea.getIndex().objectsEnd());
1431 boost::hash_combine(
hash, te_ptr->
getId());
1432 boost::hash_combine(
hash,
reinterpret_cast<std::uintptr_t
>(te_ptr));
◆ feaToSave()
◆ fillRelevantFeatures()
◆ fillRelevantRois()
Definition at line 968 of file Run2ToRun3TrigNavConverterV2.cxx.
972 auto ordered_sorter = [&setRoiName = std::as_const(
m_setRoiName)](
const std::string &left,
const std::string &right) ->
bool
974 return std::find(cbegin(setRoiName), cend(setRoiName), left) <
std::find(cbegin(setRoiName), cend(setRoiName), right);
979 for (
auto &
proxy : convProxies)
983 ATH_MSG_DEBUG(
"Several RoIs pointing to a proxy, taking latest one for now");
999 [](
const std::map<std::string, HLT::TriggerElement::FeatureAccessHelper>::value_type &
p)
1000 { return p.second; });
1004 std::set<const ConvProxy*> visited;
1005 std::function<void(std::set<ConvProxy *> &,
const std::vector<HLT::TriggerElement::FeatureAccessHelper> &)>
1006 roiPropagator = [&](std::set<ConvProxy *> &convProxyChildren,
const std::vector<HLT::TriggerElement::FeatureAccessHelper> &roiParent)
1008 for (
auto &proxyChild : convProxyChildren)
1010 if ( visited.count(proxyChild) == 1 ) {
1013 visited.insert(proxyChild);
1014 if (proxyChild->rois.empty())
1016 proxyChild->rois = roiParent;
1017 if (proxyChild->children.empty() ==
false)
1019 roiPropagator(proxyChild->children, roiParent);
1025 for (
auto &
proxy : convProxies)
1030 return StatusCode::SUCCESS;
◆ fillRelevantTracks()
StatusCode Run2ToRun3TrigNavConverterV2::fillRelevantTracks |
( |
ConvProxySet_t & |
convProxies | ) |
const |
|
private |
◆ filterFEAs()
< both method skip TrigPassBits
Definition at line 1391 of file Run2ToRun3TrigNavConverterV2.cxx.
1392 std::vector<HLT::TriggerElement::FeatureAccessHelper>
out;
1393 for (
auto fea : feaVector)
1401 auto [sgKey, sgCLID, sgName] =
getSgKey(navigationDecoder, fea);
1405 ATH_MSG_VERBOSE(
"Skipping unrecorded (missing in SG) FEA hash calculation - name in SG: " << sgName <<
" FEA " << fea);
◆ filterPassed()
◆ finalize()
StatusCode Run2ToRun3TrigNavConverterV2::finalize |
( |
| ) |
|
|
overridevirtual |
◆ getFeaSize()
std::size_t Run2ToRun3TrigNavConverterV2::getFeaSize |
( |
const ConvProxy & |
proxy | ) |
const |
|
private |
Definition at line 1224 of file Run2ToRun3TrigNavConverterV2.cxx.
1227 if (
proxy.features.empty())
1231 for (
const auto &fea :
proxy.features)
1233 if (fea.getIndex().objectsBegin() == fea.getIndex().objectsEnd())
1237 for (
auto n = fea.getIndex().objectsBegin();
n < fea.getIndex().objectsEnd(); ++
n)
◆ getHighestPtObject()
Return pair of indices (feature index in proxy->features vector, object index) identifying the highest pT object attached to the proxy.
If retrieval fails returns {std::numeric_limits<size_t>::max(), 0}.
Definition at line 1560 of file Run2ToRun3TrigNavConverterV2.cxx.
1564 std::size_t bestObj = 0;
1565 float bestPt = -1.0;
1567 for (std::size_t
i = 0;
i <
proxy.features.size(); ++
i) {
1568 const auto& fea =
proxy.features[
i];
1569 auto [sgKey, sgCLID, sgName] =
getSgKey(run2Nav, fea);
1573 if (sgKey == 0)
continue;
1574 const std::string* keyStr =
evtStore()->keyToString(sgKey, sgCLID);
1575 if (!keyStr)
continue;
1578 for (
auto n = fea.getIndex().objectsBegin();
n < fea.getIndex().objectsEnd(); ++
n) {
1579 if (
n >= cont->
size())
continue;
1582 if (
p->pt() > bestPt) {
1590 for (std::size_t
i = 0;
i <
proxy.features.size(); ++
i) {
1591 auto [sgKey, sgCLID, sgName] =
getSgKey(run2Nav,
proxy.features[
i]);
1594 bestObj =
proxy.features[
i].getIndex().objectsBegin();
1598 return {bestFea, bestObj};
◆ getSgKey()
Definition at line 1528 of file Run2ToRun3TrigNavConverterV2.cxx.
1530 const std::string hltLabel = navigationDecoder.
label(
helper.getCLID(),
helper.getIndex().subTypeIndex());
1532 const CLID saveCLID = [&](
const CLID &clid)
1543 std::string type_name;
1544 if (
m_clidSvc->getTypeNameOfID(saveCLID, type_name).isFailure())
1554 return {0, saveCLID,
""};
1557 return {
evtStore()->stringToKey(sgStringKey, saveCLID), saveCLID, hltLabel};
◆ initialize()
StatusCode Run2ToRun3TrigNavConverterV2::initialize |
( |
| ) |
|
|
overridevirtual |
Definition at line 154 of file Run2ToRun3TrigNavConverterV2.cxx.
161 ATH_MSG_INFO(
"Will use Trigger Navigation from TrigDecisionTool");
166 ATH_MSG_INFO(
"Will use Trigger Navigation decoded from TrigNavigation object");
183 std::string collName;
184 size_t delimeterIndex =
name.find(
'#');
185 if (delimeterIndex != std::string::npos)
188 collName =
name.substr(delimeterIndex + 1);
193 if ( collName.empty() )
207 if (keysSet.size() > 1 and keysSet.count(
"") != 0)
209 ATH_MSG_ERROR(
"Bad configuration for CLID " << clid <<
" requested saving of all (empty coll name configures) collections, yet there are also specific keys");
210 return StatusCode::FAILURE;
215 bool anyChainBad=
false;
217 if (
chain.find(
'*') != std::string::npos or
chain.find(
'|') != std::string::npos ) {
218 ATH_MSG_ERROR(
"Supplied chain name: " <<
chain <<
" contains wildcard characters, this is not supported by the conversion tool");
223 ATH_MSG_ERROR(
"Supplied chain names contain wildcard characters, this is not supported by the conversion tool");
224 return StatusCode::FAILURE;
227 ATH_MSG_INFO(
"No chains list supplied, the conversion will occur for all chains");
241 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.
◆ is2LegTopoChain()
Definition at line 353 of file Run2ToRun3TrigNavConverterV2.cxx.
364 size_t stepToConsider = 0;
365 const size_t sigsSize = ptrChain->
signatures().size();
366 if ( sigsSize < 2 )
return 0;
369 stepToConsider =
step;
373 if ( stepToConsider == 0 )
return 0;
376 auto finalTE = (ptrChain->
signatures()[stepToConsider])->outputTEs()[0];
377 auto preFinalTEs = (ptrChain->
signatures()[stepToConsider-1])->outputTEs();
379 auto finalSeq =
m_configSvc->sequences().getSequence(finalTE->id());
380 std::set<HLT::te_id_type> tesInSeq;
381 std::set<HLT::te_id_type> tesInChain;
383 for (
auto te: finalSeq->inputTEs()) {
384 tesInSeq.insert(te->id());
387 for (
auto te: preFinalTEs) {
388 tesInChain.insert(te->id());
391 if (tesInSeq == tesInChain) {
392 return stepToConsider;
◆ isClonable()
◆ linkFeaNode()
Definition at line 1246 of file Run2ToRun3TrigNavConverterV2.cxx.
1249 for (
const auto &
proxy : convProxies)
1259 for (
auto chainId :
proxy->passChains)
1266 for (
auto &childProxy :
proxy->children)
1273 if (
proxy->features.empty())
1279 auto hNodeIter =
proxy->hNode.begin();
1280 for (std::size_t feaIdx = 0; feaIdx <
proxy->features.size(); ++feaIdx)
1282 auto &fea =
proxy->features[feaIdx];
1283 auto [sgKey, sgCLID, sgName] =
getSgKey(run2Nav, fea);
1285 if (fea.getIndex().objectsBegin() == fea.getIndex().objectsEnd())
1291 for (
auto n = fea.getIndex().objectsBegin();
n < fea.getIndex().objectsEnd(); ++
n)
1294 const std::string& linkName = (feaIdx == bestFeaIdx &&
n == bestObjIdx) ?
1296 (*hNodeIter)->typelessSetObjectLink(linkName, sgKey, sgCLID,
n,
n + 1);
1302 return StatusCode::SUCCESS;
◆ linkRoiNode()
◆ linkTrkNode()
Definition at line 1327 of file Run2ToRun3TrigNavConverterV2.cxx.
1329 for (
auto &
proxy : convProxies)
1331 for (
auto &trk :
proxy->tracks)
1341 auto [sgKey, sgCLID, sgName] =
getSgKey(run2Nav, trk);
1345 auto d = std::make_unique<TrigCompositeUtils::Decision>();
1346 d->makePrivateStore();
1347 d->typelessSetObjectLink(tName, sgKey, sgCLID, trk.getIndex().objectsBegin());
1352 if (
track.isValid())
1355 viewBookkeeper(*
t) = ROIElementLink;
1363 if (
track.isValid())
1366 viewBookkeeper(*
t) = ROIElementLink;
1373 ATH_MSG_WARNING(
"Unable to create an ElementLink into a container with no entries");
1379 return StatusCode::SUCCESS;
◆ mirrorTEsStructure()
Definition at line 583 of file Run2ToRun3TrigNavConverterV2.cxx.
587 std::map<const HLT::TriggerElement *, ConvProxy *> teToProxy;
595 convProxies.insert(
proxy);
596 teToProxy[te] =
proxy;
600 ConvProxy *predecessorProxy = teToProxy[predecessor];
601 if (predecessorProxy !=
nullptr)
603 proxy->parents.insert(predecessorProxy);
612 for (
auto proxy : convProxies)
616 for (
auto p :
proxy->children)
618 for (
auto p :
proxy->parents)
621 for (
auto p :
proxy->parents)
623 for (
auto pp :
p->parents)
631 for (
auto c :
proxy->children)
633 for (
auto cc :
c->children)
644 ATH_MSG_DEBUG(
"Created " << convProxies.size() <<
" proxy objects");
645 return StatusCode::SUCCESS;
◆ msg() [1/2]
◆ msg() [2/2]
◆ msgLvl()
◆ noUnconnectedHNodes()
Definition at line 1498 of file Run2ToRun3TrigNavConverterV2.cxx.
1501 std::set<const TrigCompositeUtils::Decision *> linkedHNodes;
1504 if (
d->name() ==
"IM" or
d->name() ==
"FS")
1508 linkedHNodes.insert(*
el);
1514 if (
d->name() ==
"H")
1516 if (linkedHNodes.count(
d) == 0)
1519 return StatusCode::FAILURE;
1525 return StatusCode::SUCCESS;
◆ numberOfHNodesPerProxyNotExcessive()
StatusCode Run2ToRun3TrigNavConverterV2::numberOfHNodesPerProxyNotExcessive |
( |
const ConvProxySet_t & |
| ) |
const |
|
private |
◆ 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.
◆ printProxies()
◆ removeTopologicalProxies()
StatusCode Run2ToRun3TrigNavConverterV2::removeTopologicalProxies |
( |
ConvProxySet_t & |
convProxies | ) |
const |
|
private |
Definition at line 916 of file Run2ToRun3TrigNavConverterV2.cxx.
920 if ((*i)->parents.size() > 1)
926 parent->children.erase(toDel);
930 child->parents.erase(toDel);
933 i = convProxies.erase(
i);
940 return StatusCode::SUCCESS;
◆ removeUnassociatedProxies()
StatusCode Run2ToRun3TrigNavConverterV2::removeUnassociatedProxies |
( |
ConvProxySet_t & |
convProxies | ) |
const |
|
private |
Definition at line 730 of file Run2ToRun3TrigNavConverterV2.cxx.
735 if ((*i)->runChains.empty())
741 parent->children.erase(toDel);
745 child->parents.erase(toDel);
748 i = convProxies.erase(
i);
755 ATH_MSG_DEBUG(
"After eliminating proxies not associated to chainsof intereset left with " << convProxies.size());
756 return StatusCode::SUCCESS;
◆ renounce()
◆ renounceArray()
◆ roiToSave()
◆ 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.
◆ updateTerminusNode()
Definition at line 1152 of file Run2ToRun3TrigNavConverterV2.cxx.
1172 return StatusCode::FAILURE;
1177 filteredIDs.insert(idToCheck);
1180 terminus->
setDecisions( std::vector<TCU::DecisionID>() );
1183 "the terminus node goes from " << currentIDs.size() <<
" to " << filteredIDs.size() <<
" chain IDs.");
1191 return StatusCode::SUCCESS;
◆ updateVHKA()
◆ m_allTEIdsToChains
◆ m_CaloClusterCLID
CLID Run2ToRun3TrigNavConverterV2::m_CaloClusterCLID {0} |
|
private |
◆ m_CaloClusterContainerCLID
CLID Run2ToRun3TrigNavConverterV2::m_CaloClusterContainerCLID {0} |
|
private |
◆ m_chainIdsPrinter
◆ m_chainsToSave
Gaudi::Property<std::vector<std::string> > Run2ToRun3TrigNavConverterV2::m_chainsToSave {this, "Chains", {}, "If not specified, all chains are handled"} |
|
private |
◆ m_clidSvc
◆ m_collectionsToSave
Gaudi::Property<std::vector<std::string> > Run2ToRun3TrigNavConverterV2::m_collectionsToSave {this, "Collections", {}} |
|
private |
◆ m_collectionsToSaveDecoded
std::map<CLID, std::set<std::string> > Run2ToRun3TrigNavConverterV2::m_collectionsToSaveDecoded |
|
private |
◆ m_configSvc
◆ m_configUpdateMutex
std::mutex Run2ToRun3TrigNavConverterV2::m_configUpdateMutex |
|
mutableprivate |
◆ m_detStore
◆ m_doCompression
Gaudi::Property<bool> Run2ToRun3TrigNavConverterV2::m_doCompression {this, "doCompression", false, "Collapse navigation elements to save ouput space"} |
|
private |
◆ m_doLinkFeatures
Gaudi::Property<bool> Run2ToRun3TrigNavConverterV2::m_doLinkFeatures {this, "doLinkFeatures", true, "Add links to objects, setting it false makes sense when running tests"} |
|
private |
◆ m_doSelfValidation
Gaudi::Property<bool> Run2ToRun3TrigNavConverterV2::m_doSelfValidation {this, "doSelfValidation", false, "Run consistency checks after stages of conversion (slows down the alg)"} |
|
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_finalTEIdsToChains
◆ m_hNodesPerProxyThreshold
Gaudi::Property<size_t> Run2ToRun3TrigNavConverterV2::m_hNodesPerProxyThreshold {this, "hNodesPerProxyThreshhold", 15, "Limit number of H nodes per TE (if exceeded conversion results in an error)"} |
|
private |
◆ m_includeTauTrackFeatures
Gaudi::Property<bool> Run2ToRun3TrigNavConverterV2::m_includeTauTrackFeatures {this, "addTauTracks", false, "Add Tau Track collection as feature element"} |
|
private |
◆ m_roIDescriptorCLID
CLID Run2ToRun3TrigNavConverterV2::m_roIDescriptorCLID {0} |
|
private |
◆ m_roIDescriptorCollectionCLID
CLID Run2ToRun3TrigNavConverterV2::m_roIDescriptorCollectionCLID {0} |
|
private |
◆ m_roisToSave
Gaudi::Property<std::vector<std::string> > Run2ToRun3TrigNavConverterV2::m_roisToSave {this, "Rois", {}} |
|
private |
◆ m_setRoiName
std::vector<std::string> Run2ToRun3TrigNavConverterV2::m_setRoiName |
|
private |
◆ m_TauTrackContainerCLID
CLID Run2ToRun3TrigNavConverterV2::m_TauTrackContainerCLID {0} |
|
private |
◆ m_tdt
PublicToolHandle<Trig::TrigDecisionTool> Run2ToRun3TrigNavConverterV2::m_tdt {this, "TrigDecisionTool", "", "When enabled read navigation from TDT/off by default"} |
|
private |
◆ m_teIDPrinter
◆ m_TrackParticleContainerCLID
CLID Run2ToRun3TrigNavConverterV2::m_TrackParticleContainerCLID {0} |
|
private |
◆ m_TrigEMClusterCLID
CLID Run2ToRun3TrigNavConverterV2::m_TrigEMClusterCLID {0} |
|
private |
◆ m_TrigEMClusterContainerCLID
CLID Run2ToRun3TrigNavConverterV2::m_TrigEMClusterContainerCLID {0} |
|
private |
◆ m_trigNavKey
◆ m_trigOutputNavKey
◆ m_TrigRingerRingsCLID
CLID Run2ToRun3TrigNavConverterV2::m_TrigRingerRingsCLID {0} |
|
private |
◆ m_TrigRingerRingsContainerCLID
CLID Run2ToRun3TrigNavConverterV2::m_TrigRingerRingsContainerCLID {0} |
|
private |
◆ m_varHandleArraysDeclared
◆ m_vhka
The documentation for this class was generated from the following files:
StatusCode fillRelevantTracks(ConvProxySet_t &convProxies) const
def retrieve(aClass, aKey=None)
bool operator<(const DataVector< T > &a, const DataVector< T > &b)
Vector ordering relation.
const std::regex mu2MunoL1Special
StatusCode collapseProxies(ConvProxySet_t &, MAP &) const
SG::ReadHandleKey< xAOD::TrigNavigation > m_trigNavKey
const std::string & name() const
StatusCode fillRelevantRois(ConvProxySet_t &convProxies, const HLT::TrigNavStructure &run2Nav) const
StatusCode createL1Nodes(const ConvProxySet_t &convProxies, xAOD::TrigCompositeContainer &decisions, const EventContext &context) const
std::string find(const std::string &s)
return a remapped string
std::string label(class_id_type clid, const index_or_label_type &sti_or_label) const
TrigCompositeUtils::DecisionID numeric() const
numeric ID
const std::string & hltSeedingNodeName()
StatusCode linkRoiNode(ConvProxySet_t &convProxies, const HLT::TrigNavStructure &run2Nav) const
StatusCode updateTerminusNode(xAOD::TrigCompositeContainer &, const EventContext &context) const
Decision * newDecisionIn(DecisionContainer *dc, const std::string &name)
Helper method to create a Decision object, place it in the container and return a pointer to it.
StatusCode allProxiesConnected(const ConvProxySet_t &) const
const std::string & hypoAlgNodeName()
ServiceHandle< TrigConf::IHLTConfigSvc > m_configSvc
std::mutex m_configUpdateMutex
StatusCode removeUnassociatedProxies(ConvProxySet_t &) const
void addDecisionID(DecisionID id, Decision *d)
Appends the decision (given as ID) to the decision object.
std::tuple< uint32_t, CLID, std::string > getSgKey(const HLT::TrigNavStructure &navigationDecoder, const HLT::TriggerElement::FeatureAccessHelper &helper) const
static const uint64_t MissingFEA
const std::regex bjetMuChain
std::pair< std::size_t, std::size_t > getHighestPtObject(const ConvProxy &, const HLT::TrigNavStructure &) const
Return pair of indices (feature index in proxy->features vector, object index) identifying the highes...
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)
Gaudi::Property< std::vector< std::string > > m_collectionsToSave
te_id_type getId() const
reset internals.
SG::WriteHandleKey< xAOD::TrigCompositeContainer > m_trigOutputNavKey
StatusCode bjetMuChainConfigDecoder(TEIdToChainsMap_t &allTES, TEIdToChainsMap_t &finalTEs, const TrigConf::HLTChain *ptrChain) const
class_id_type getCLID() const
Class ID of object.
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
void insertDecisionIDs(const Decision *src, Decision *dest)
Appends the decision IDs of src to the dest decision object.
Gaudi::Property< std::vector< std::string > > m_roisToSave
bool msgLvl(const MSG::Level lvl) const
CLID m_TrigRingerRingsCLID
std::vector< std::string > m_setRoiName
const std::vector< HLTSignature * > & signatures() const
void setDecisions(const std::vector< TrigCompositeUtils::DecisionID > &decisions)
Set positive HLT chain decisions associated with this TrigComposite. Navigation use.
std::map< CLID, std::set< std::string > > m_collectionsToSaveDecoded
std::string formatSGkey(const std::string &prefix, const std::string &containername, const std::string &label)
declaration of formatting function.
CLID m_TauTrackContainerCLID
PublicToolHandle< Trig::TrigDecisionTool > m_tdt
#define ATH_MSG_VERBOSE(x)
std::function< void(const ConvProxy *)> m_chainIdsPrinter
Class providing the definition of the 4-vector interface.
TEIdToChainsMap_t m_allTEIdsToChains
SG::WriteHandle< DecisionContainer > createAndStore(const SG::WriteHandleKey< DecisionContainer > &key, const EventContext &ctx)
Creates and right away records the DecisionContainer with the key.
bool isValid() const
Test to see if the link can be dereferenced.
const std::regex egammaDiEtcut
const std::regex gammaXeChain
std::set< ConvProxy * > children
virtual void setOwner(IDataHandleHolder *o)=0
An algorithm that can be simultaneously executed in multiple threads.
uint64_t feaToHash(const std::vector< HLT::TriggerElement::FeatureAccessHelper > &feaVector, const HLT::TriggerElement *te_ptr, const HLT::TrigNavStructure &navigationDecoder) const
returns true if this particular feature is to be saved (linked)
CLID m_roIDescriptorCollectionCLID
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 const DataObjIDColl & extraOutputDeps() const override
Return the list of extra output dependencies.
StatusCode createSFNodes(const ConvProxySet_t &, xAOD::TrigCompositeContainer &, const TEIdToChainsMap_t &finalTEs, const EventContext &context) const
Exception — ForwardIndexingPolicy: internal link state is invalid.
std::vector< HLT::TriggerElement::FeatureAccessHelper > filterFEAs(const std::vector< HLT::TriggerElement::FeatureAccessHelper > &feaVector, const HLT::TrigNavStructure &navigationDecoder) const
< both method skip TrigPassBits
StatusCode extractTECtoChainMapping(TEIdToChainsMap_t &allTES, TEIdToChainsMap_t &finalTEs) const
static const std::vector< TriggerElement * > & getDirectPredecessors(const TriggerElement *te)
returns list of direct predecessors (nodes seeding me)
Helper class to provide type-safe access to aux data.
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
const std::string & initialRoIString()
const std::vector< ElementLink< DecisionContainer > > getLinkToPrevious(const Decision *d)
returns links to previous decision object 'seed'
::StatusCode StatusCode
StatusCode definition for legacy code.
pointer_type ptr()
Dereference the pointer.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
virtual StatusCode sysExecute(const EventContext &ctx) override
Execute an algorithm.
StatusCode linkTrkNode(ConvProxySet_t &convProxies, const HLT::TrigNavStructure &run2Nav) const
StatusCode createIMHNodes(ConvProxySet_t &, xAOD::TrigCompositeContainer &, const EventContext &) const
Amg::Vector3D transform(Amg::Vector3D &v, Amg::Transform3D &tr)
Transform a point from a Trasformation3D.
Gaudi::Property< bool > m_includeTauTrackFeatures
CLID m_TrigEMClusterContainerCLID
std::map< HLT::te_id_type, std::set< HLT::Identifier > > TEIdToChainsMap_t
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Class used to describe composite objects in the HLT.
uint32_t CLID
The Class ID type.
StatusCode removeTopologicalProxies(ConvProxySet_t &) const
const std::regex egammaEtcut
virtual void renounce()=0
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
ElementLink implementation for ROOT usage.
const std::string & featureString()
bool isAvailable(ObjectId< CI, CM > id) const noexcept
std::vector< int > multiplicities(const std::string &chain)
StatusCode collapseFeaturesProxies(ConvProxySet_t &convProxies, const HLT::TrigNavStructure &run2Nav) const
TEIdToChainsMap_t m_finalTEIdsToChains
Gaudi::Property< bool > m_doCompression
std::set< ConvProxy * > ConvProxySet_t
StatusCode associateChainsToProxies(ConvProxySet_t &, const TEIdToChainsMap_t &) const
static const std::string hash2string(HLTHash, const std::string &category="TE")
hash function translating identifiers into names (via internal dictionary)
const std::string & summaryPassNodeName()
Gaudi::Property< bool > m_doLinkFeatures
std::size_t getFeaSize(const ConvProxy &) const
StatusCode numberOfHNodesPerProxyNotExcessive(const ConvProxySet_t &) const
HLT::Identifier createLegName(const HLT::Identifier &chainIdentifier, size_t counter)
Generate the HLT::Identifier which corresponds to a specific leg of a given chain.
StatusCode allProxiesHaveChain(const ConvProxySet_t &) const
static const std::vector< TriggerElement * > & getRoINodes(const TriggerElement *somenode)
gets all RoI type nodes seeding indirectly this TriggerElement
StatusCode fillRelevantFeatures(ConvProxySet_t &convProxies, const HLT::TrigNavStructure &run2Nav) const
bool feaToSave(const HLT::TriggerElement::FeatureAccessHelper &fea, const std::string &sgName) const
const std::string & name() const
Get a human-readable name for the object.
std::vector< TriggerElement * > & getAllTEs()
access needed by slimming tools.
void linkToPrevious(Decision *d, const std::string &previousCollectionKey, size_t previousIndex)
Links to the previous object, location of previous 'seed' decision supplied by hand.
StatusCode collapseFeaturelessProxies(ConvProxySet_t &) const
static bool isInitialNode(const TriggerElement *te)
queries if node is an initial one
std::set< DecisionID > DecisionIDContainer
the FeatureAccessHelper is a class used to keep track of features attached to this TE.
#define ATH_MSG_WARNING(x)
virtual bool deserialize(const std::vector< uint32_t > &input)
size_t is2LegTopoChain(const TrigConf::HLTChain *ptrChain) const
StatusCode mirrorTEsStructure(ConvProxySet_t &, const HLT::TrigNavStructure &run2Nav) const
ServiceHandle< IClassIDSvc > m_clidSvc
void decisionIDs(const Decision *d, DecisionIDContainer &destination)
Extracts DecisionIDs stored in the Decision object.
StatusCode doCompression(ConvProxySet_t &convProxies, const HLT::TrigNavStructure &run2Nav) const
def merge(input_file_pattern, output_file)
Merge many input LHE files into a single output file.
std::string name() const
reports human redable name
CLID m_CaloClusterContainerCLID
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
bool feaToSkip(const HLT::TriggerElement::FeatureAccessHelper &fea)
virtual StatusCode sysInitialize() override
Override sysInitialize.
const std::regex tauXeChain
void printProxies(const ConvProxySet_t &proxies, std::function< bool(const ConvProxy *)> selector=[](const ConvProxy *){return true;}, const std::vector< std::function< void(const ConvProxy *)>> &printers={}) const
const std::string & roiString()
StatusCode linkFeaNode(ConvProxySet_t &convProxies, xAOD::TrigCompositeContainer &, const HLT::TrigNavStructure &run2Nav, const EventContext &context) const
CLID m_TrigRingerRingsContainerCLID
StatusCode cureUnassociatedProxies(ConvProxySet_t &) const
HLT::Identifier getIDFromLeg(const HLT::Identifier &legIdentifier)
Generate the HLT::Identifier which corresponds to the chain name from the leg name.
Class describing a TrackParticle.
std::function< void(const ConvProxy *)> m_teIDPrinter
std::set< ConvProxy * > parents
DataObjIDColl m_extendedExtraObjects
Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.
size_type size() const noexcept
Returns the number of elements in the collection.
Gaudi::Property< std::vector< std::string > > m_chainsToSave
CLID m_TrackParticleContainerCLID
const std::regex egammaCombinedWithEtcut
const std::string & inputMakerNodeName()
Gaudi::Property< bool > m_doSelfValidation
ElementLink< DecisionContainer > decisionToElementLink(const Decision *d, const EventContext &ctx)
Takes a raw pointer to a Decision and returns an ElementLink to the Decision.