ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
PhysicsAnalysis
JetTagging
FlavorTagInference
FlavorTagInference
NNSharingOnnxSvc.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#ifndef NN_SHARING_ONNX_SVC_H
6
#define NN_SHARING_ONNX_SVC_H
7
8
#include "
FlavorTagInference/INNSharingSvc.h
"
9
#include "
AsgServices/AsgService.h
"
10
#include "
AsgTools/PropertyWrapper.h
"
11
12
namespace
FlavorTagInference
13
{
14
class
NNSharingOnnxSvc
:
public
extends<asg::AsgService, INNSharingSvc>
15
{
16
public
:
17
using
extends::extends;
// base class constructor
18
virtual
std::shared_ptr<const GNN>
get
(
19
const
std::string& nn_name,
20
const
GNNOptions
& opts)
override
;
21
private
:
22
using
val_t
= std::shared_ptr<const GNN>;
23
std::unordered_map<NNHashing::NNKey, val_t, NNHashing::NNHasher>
m_gnns
;
24
std::unordered_map<std::string, val_t>
m_base_gnns
;
25
Gaudi::Property<std::string>
m_executionProvider
{
26
this
,
"executionProvider"
,
"CPU"
,
27
"onnx execution provider to build the sessions on, CPU or CUDA"
};
28
Gaudi::Property<int>
m_deviceId
{
29
this
,
"deviceId"
, 0,
"device the CUDA provider runs on"
};
30
Gaudi::Property<bool>
m_useTF32
{
31
this
,
"useTF32"
,
false
,
32
"let tensor cores evaluate fp32 matmuls in TF32"
};
33
};
34
35
}
36
37
#endif
AsgService.h
INNSharingSvc.h
PropertyWrapper.h
FlavorTagInference::NNSharingOnnxSvc
Definition
NNSharingOnnxSvc.h:15
FlavorTagInference::NNSharingOnnxSvc::m_deviceId
Gaudi::Property< int > m_deviceId
Definition
NNSharingOnnxSvc.h:28
FlavorTagInference::NNSharingOnnxSvc::m_gnns
std::unordered_map< NNHashing::NNKey, val_t, NNHashing::NNHasher > m_gnns
Definition
NNSharingOnnxSvc.h:23
FlavorTagInference::NNSharingOnnxSvc::m_useTF32
Gaudi::Property< bool > m_useTF32
Definition
NNSharingOnnxSvc.h:30
FlavorTagInference::NNSharingOnnxSvc::m_executionProvider
Gaudi::Property< std::string > m_executionProvider
Definition
NNSharingOnnxSvc.h:25
FlavorTagInference::NNSharingOnnxSvc::m_base_gnns
std::unordered_map< std::string, val_t > m_base_gnns
Definition
NNSharingOnnxSvc.h:24
FlavorTagInference::NNSharingOnnxSvc::get
virtual std::shared_ptr< const GNN > get(const std::string &nn_name, const GNNOptions &opts) override
Definition
NNSharingOnnxSvc.cxx:11
FlavorTagInference::NNSharingOnnxSvc::val_t
std::shared_ptr< const GNN > val_t
Definition
NNSharingOnnxSvc.h:22
FlavorTagInference
This file contains "getter" functions used for accessing tagger inputs from the EDM.
Definition
CaloClusterLoader.h:27
FlavorTagInference::GNNOptions
Definition
GNNOptions.h:15
Generated on
for ATLAS Offline Software by
1.17.0