ATLAS Offline Software
DataScoutingInfo.py
Go to the documentation of this file.
1 # Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
2 
3 from AthenaCommon.Logging import logging
4 log = logging.getLogger( __name__ )
5 
6 '''
7 This file defines the Data Scouting chain identifiers which serve also
8 as EDM target identifiers and their mapping to HLT Result module IDs.
9 
10 When adding new identifiers, please follow the naming convention SomeNameDS,
11 where SomeName is generally camel-case unless it's an acronym like LAr or MET.
12 
13 Possible examples:
14 CostMonDS, PhysicsTLA
15 '''
16 
17 
18 # Data scouting identifiers and the corresponding HLT result ROBFragment module IDs.
19 # If you add new entries also add a corresponding entry to EventBuildingInfo.py.
20 # WARNING: Never change the module IDs during data taking!
21 # WARNING: ID=0 is reserved for full HLT result
22 _DataScoutingIdentifiers = {
23  'CostMonDS': 1,
24  'MuonDS' : 2,
25  'PhysicsTLA': 5,
26  'DarkJetPEBTLA': 6,
27  'FTagPEBTLA' : 7,
28  'EgammaPEBTLA' : 8,
29 }
30 
31 # Each stream should correspond to exactly one event building type
32 _DataScoutingStreams = {
33  'calibration_CostMonitoring': 'CostMonDS',
34  'calibration_MuonDSCalib':'MuonDS',
35  'physics_TLA': 'PhysicsTLA',
36  'physics_DarkJetPEBTLA': 'DarkJetPEBTLA',
37  'physics_FTagPEBTLA': 'FTagPEBTLA',
38  'physics_EgammaPEBTLA': 'EgammaPEBTLA',
39 }
40 
41 # Truncation thresholds (in bytes) for each HLT result type
42 TruncationThresholds = {
43  0: 7*(1024**2), # Main: 7 MB (increased from 5MB after ATR-29142)
44  1: 2*(1024**2), # CostMonDS: 2 MB
45  2: 1*(1024**2), # MuonDS: 1 MB
46  5: 1*(1024**2), # PhysicsTLA: 1 MB
47  6: 1*(1024**2), # DarkJetPEBTLA: 1 MB
48  7: 1*(1024**2), # FTagPEBTLA 1 MB
49  8: 1*(1024**2), # EgammaPEBTLA 1 MB
50 
51 }
52 
53 
55  if name in _DataScoutingIdentifiers:
56  return _DataScoutingIdentifiers[name]
57  else:
58  log.error('Unknown name %s, cannot assign result ID', name)
59 
60 
62  return list(_DataScoutingStreams.keys())
63 
64 
66  if streamname in _DataScoutingStreams:
67  return _DataScoutingStreams[streamname]
68  else:
69  log.error('Unknown name %s, not a data scouting stream', streamname)
70 
71 
73  return _DataScoutingIdentifiers.values()
74 
75 
77  # WARNING: Don't change this, it should always be zero.
78  # It's defined here to avoid using a magic number in other places
79  return 0
80 
81 
83  return list(_DataScoutingIdentifiers.keys())
python.DataScoutingInfo.getFullHLTResultID
def getFullHLTResultID()
Definition: DataScoutingInfo.py:76
python.DataScoutingInfo.getDataScoutingResultID
def getDataScoutingResultID(name)
Definition: DataScoutingInfo.py:54
python.DataScoutingInfo.getAllDataScoutingIdentifiers
def getAllDataScoutingIdentifiers()
Definition: DataScoutingInfo.py:82
python.DataScoutingInfo.getDataScoutingTypeFromStream
def getDataScoutingTypeFromStream(streamname)
Definition: DataScoutingInfo.py:65
python.DataScoutingInfo.getAllDataScoutingResultIDs
def getAllDataScoutingResultIDs()
Definition: DataScoutingInfo.py:72
histSizes.list
def list(name, path='/')
Definition: histSizes.py:38
python.DataScoutingInfo.getDataScoutingStreams
def getDataScoutingStreams()
Definition: DataScoutingInfo.py:61