![]() |
ATLAS Offline Software
|
This class is in charge of loading the correct HyPER model based on the Ttbar di-lepton topology. More...
#include <HyPERTtbarDiLeptonModel.h>
Public Member Functions | |
| HyPERTtbarDiLeptonModel (const AthOnnx::IOnnxRuntimeInferenceTool *trainedOnEven, const AthOnnx::IOnnxRuntimeInferenceTool *trainedOnOdd) | |
| std::vector< std::string > | getInputNames () const override |
| Input node names in the order the ONNX graph declares them. | |
| std::vector< HyPEROutputNode > | getModelOutputs () const override |
| Every output node of the ONNX graph, in declaration order. | |
| std::vector< std::string > | getOutputNames () const override |
| Model-specific output names consumed by the parser. | |
| StatusCode | initialize () |
| Resolve the node name -> node index maps. | |
| void | setTopology (HyPERTopology topology)=delete |
| HyPERTopology | getTopology () const |
| template<typename T> | |
| void | setInputs (const std::string &node, std::vector< T > &values, const std::vector< int64_t > &shape) |
| Bind an input by node name. | |
| StatusCode | evaluate (unsigned sessionIndex) |
| Run the model of the requested fold over the bound inputs. | |
| template<typename T> | |
| T * | getOutputs (const std::string &node) |
| Pointer to the buffer of the named output. | |
| void | clearInputs () |
| void | clearOutputs () |
| void | printInputInfo (bool printContent=false) const |
| void | printOutputInfo (bool printContent=false) const |
Protected Attributes | |
| HyPERTopology | m_topology {HyPERTopology::NotSelected} |
Private Types | |
| using | InputData = std::variant<std::vector<float>*, std::vector<int64_t>*> |
Static Private Member Functions | |
| template<typename T> | |
| static std::string | contentToString (const std::vector< T > &values) |
| static std::string | shapeToString (const std::vector< int64_t > &shape) |
Private Attributes | |
| const AthOnnx::IOnnxRuntimeInferenceTool * | m_toolTrainedOnEven {nullptr} |
| const AthOnnx::IOnnxRuntimeInferenceTool * | m_toolTrainedOnOdd {nullptr} |
| std::map< std::string, std::size_t > | m_inputIndex {} |
| std::vector< BoundInput > | m_boundInputs {} |
| std::vector< HyPEROutputNode > | m_outputNodes {} |
| std::map< std::string, std::size_t > | m_outputIndex {} |
| std::vector< std::vector< float > > | m_outputsFloat {} |
| std::vector< std::vector< int64_t > > | m_outputsInt64 {} |
Static Private Attributes | |
| static constexpr const char * | s_edgeIndexName = "edge_index" |
| Input nodes whose shapes carry the graph's dynamic dimensions. | |
| static constexpr const char * | s_hyperEdgeIndexName = "edge_index_h" |
This class is in charge of loading the correct HyPER model based on the Ttbar di-lepton topology.
Definition at line 20 of file HyPERTtbarDiLeptonModel.h.
|
privateinherited |
Definition at line 289 of file HyPERModel.h.
|
inline |
Definition at line 22 of file HyPERTtbarDiLeptonModel.h.
|
inlineinherited |
Definition at line 240 of file HyPERModel.h.
|
inlineinherited |
Definition at line 244 of file HyPERModel.h.
|
inlinestaticprivateinherited |
Definition at line 297 of file HyPERModel.h.
|
inlineinherited |
Run the model of the requested fold over the bound inputs.
| sessionIndex | 0 for the model trained on even events, 1 for odd. |
Definition at line 158 of file HyPERModel.h.
|
inlineoverridevirtual |
Input node names in the order the ONNX graph declares them.
The order matters: ONNX Runtime is handed the tensors positionally.
Implements EventReco::HyPERModel.
Definition at line 28 of file HyPERTtbarDiLeptonModel.h.
|
inlineoverridevirtual |
Every output node of the ONNX graph, in declaration order.
Implements EventReco::HyPERModel.
Definition at line 38 of file HyPERTtbarDiLeptonModel.h.
|
inlineoverridevirtual |
Model-specific output names consumed by the parser.
Output names vary according to the number of message-passing layers etc. This must be defined for each and every topology.
Implements EventReco::HyPERModel.
Definition at line 46 of file HyPERTtbarDiLeptonModel.h.
|
inlineinherited |
Pointer to the buffer of the named output.
Valid until the next clearOutputs() or evaluate().
Definition at line 224 of file HyPERModel.h.
|
inlineinherited |
Definition at line 112 of file HyPERModel.h.
|
inlineinherited |
Resolve the node name -> node index maps.
Must be called once before the first evaluate(). This cannot live in the constructor because it relies on the topology-specific virtual methods below.
Definition at line 76 of file HyPERModel.h.
|
inlineinherited |
Definition at line 249 of file HyPERModel.h.
|
inlineinherited |
Definition at line 267 of file HyPERModel.h.
|
inlineinherited |
Bind an input by node name.
The tensor aliases values, so the caller must keep it alive and unmodified until after evaluate().
Definition at line 138 of file HyPERModel.h.
|
deleteinherited |
|
inlinestaticprivateinherited |
Definition at line 303 of file HyPERModel.h.
|
privateinherited |
Definition at line 313 of file HyPERModel.h.
|
privateinherited |
Definition at line 312 of file HyPERModel.h.
|
privateinherited |
Definition at line 316 of file HyPERModel.h.
|
privateinherited |
Definition at line 315 of file HyPERModel.h.
|
privateinherited |
Definition at line 317 of file HyPERModel.h.
|
privateinherited |
Definition at line 318 of file HyPERModel.h.
|
privateinherited |
Definition at line 309 of file HyPERModel.h.
|
privateinherited |
Definition at line 310 of file HyPERModel.h.
|
protectedinherited |
Definition at line 281 of file HyPERModel.h.
|
staticconstexprprivateinherited |
Input nodes whose shapes carry the graph's dynamic dimensions.
These are named identically in every HyPER topology.
Definition at line 286 of file HyPERModel.h.
|
staticconstexprprivateinherited |
Definition at line 287 of file HyPERModel.h.