ATLAS Offline Software
Loading...
Searching...
No Matches
TrigConf::HLTChain Class Reference

HLT chain configuration information. More...

#include <HLTChain.h>

Inheritance diagram for TrigConf::HLTChain:

Public Member Functions

 HLTChain (void)
 default constructor
 HLTChain (const std::string &chain_name, int chain_counter, int chain_version, const std::string &level, const std::string &lower_chain_name, int lower_chain_counter, std::vector< HLTSignature * > &&signatureList)
 constructor with configuration data
 HLTChain (const HLTChain &ch)
 copy constructor
virtual ~HLTChain () override
 destructor
const std::string & chain_name () const
int chain_counter () const
int chain_version () const
const std::string & level () const
HLTLevel level_enum () const
bool has_l2 () const
const std::string & lower_chain_name () const
int lower_chain_counter () const
unsigned int chain_hash_id () const
unsigned int lower_chain_hash_id () const
int EB_after_step () const
const std::vector< size_t > & leg_multiplicities () const
bool hasMultipleLowerChains () const
const std::vector< int > & lower_chain_counters () const
std::vector< unsigned int > lower_chain_hash_ids () const
std::vector< HLTTriggerType * > & triggerTypeList ()
const std::vector< HLTTriggerType * > & triggerTypeList () const
HLTChainset_chain_name (const std::string &chain_name)
HLTChainset_chain_counter (int chain_counter)
HLTChainset_chain_version (int chain_version)
HLTChainset_level (std::string_view level)
HLTChainset_has_l2 (const bool has_l2)
HLTChainset_lower_chain_name (const std::string &lower_chain_name)
HLTChainset_lower_chain_counter (int lower_chain_counter)
HLTChainset_lower_chain_counters (const std::vector< int > &low_ccs)
HLTChainset_signatureList (const std::vector< HLTSignature * > &sigList)
HLTChainset_triggerTypeList (const std::vector< HLTTriggerType * > &trigList)
HLTChainset_groupList (const std::set< std::string > &groups)
HLTChainset_EB_after_step (int EB_after_step)
HLTChainset_leg_multiplicities (const std::vector< size_t > &mult)
std::vector< HLTSignature * > & signatureList ()
const std::vector< HLTSignature * > & signatureList () const
const std::vector< HLTSignature * > & signatures () const
unsigned int lastStep () const
void shiftStepCounter (int shift)
void addStream (HLTStreamTag *)
void clearStreams ()
const std::vector< HLTStreamTag * > & streams () const
const std::vector< HLTStreamTag * > & streamTagList () const __attribute__((deprecated))
const std::vector< HLTStreamTag * > & streams_orig () const
std::pair< bool, float > stream_prescale (const std::string &streamName) const
const std::set< std::string > & groups () const
const std::set< std::string > & groupList () const __attribute__((deprecated))
void addGroup (const std::string &group)
void clearGroups ()
HLTChainset_prescales (const HLTPrescale &prescales)
HLTChainset_prescale (float prescale)
HLTChainset_rerun_prescale (float rerun_prescale)
HLTChainset_pass_through (float pass_through)
HLTPrescaleprescales ()
const HLTPrescaleprescales () const
float prescale () const
float pass_through () const
std::pair< bool, float > rerun_prescale (const std::string &targetName) const
float rerun_prescale () const __attribute__((deprecated))
bool operator< (const HLTChain &e) const
void createSignatureLabels ()
 label the signatures
void print (const std::string &indent="", unsigned int detail=1) const override
 print the chain
void writeXML (std::ofstream &xmlfile)
DiffStructcompareTo (const HLTChain *o) const
std::string __str__ () const override
int superMasterTableId () const
unsigned int smk () const
unsigned int id () const
const std::string & name () const
const std::string & comment () const
unsigned int version () const
void setSuperMasterTableId (int id)
void setSMK (int id)
void setId (unsigned int id)
void setName (const std::string &name)
void setVersion (unsigned int version)
void setComment (const std::string &c)
void printNameIdV (const std::string &indent="") const

Public Attributes

struct { 
   unsigned int   l2 {0} 
   unsigned int   ef {0} 
mergeCounter

Protected Member Functions

std::ostream & indent (std::ostream &o, int lvl, int size) const

Private Attributes

unsigned int m_chain_hash_id {}
 hash value from m_chain_name, this is used to identify the chain in the HLTResult
int m_chain_counter {}
 chain counter
int m_chain_version {}
 chain version
std::string m_level
 trigger level
std::string m_lower_chain_name
 name of the lower trigger chain (or the LVL1 trigger item)
int m_lower_chain_counter {}
 counter of the lower trigger chain (or the ID of the LVL1 trigger item)
std::vector< int > m_lower_chain_counters
 counters of the lower trigger items if more than 1
unsigned int m_lower_chain_hash_id {}
 hash value from m_lower_chain_name, this is used to match to a chain from the previous trigger level
int m_EB_after_step {}
 EB_after_step flag.
std::vector< size_t > m_leg_multiplicities
 Number of objects required per leg.
HLTPrescale m_prescales
std::vector< HLTSignature * > m_HLTSignatureList
std::vector< HLTTriggerType * > m_HLTTriggerTypeList
std::set< std::string > m_groups
std::vector< HLTStreamTag * > m_streams_orig
std::vector< HLTStreamTag * > m_streams
std::unordered_map< std::string, HLTStreamTag * > m_streams_map
bool m_has_l2 {false}
unsigned int m_smk
unsigned int m_id
std::string m_name
unsigned int m_version
std::string m_comment

Friends

std::ostream & operator<< (std::ostream &, const HLTChain &)

Detailed Description

HLT chain configuration information.

Definition at line 35 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

Constructor & Destructor Documentation

◆ HLTChain() [1/3]

TrigConf::HLTChain::HLTChain ( void )

default constructor

Definition at line 28 of file TrigConfHLTData/Root/HLTChain.cxx.

28 :
33 m_level(""),
38{}
unsigned int m_lower_chain_hash_id
hash value from m_lower_chain_name, this is used to match to a chain from the previous trigger level
std::string m_lower_chain_name
name of the lower trigger chain (or the LVL1 trigger item)
unsigned int m_chain_hash_id
hash value from m_chain_name, this is used to identify the chain in the HLTResult
int m_lower_chain_counter
counter of the lower trigger chain (or the ID of the LVL1 trigger item)
TrigConfData(const std::string &name="")

◆ HLTChain() [2/3]

HLTChain::HLTChain ( const std::string & chain_name,
int chain_counter,
int chain_version,
const std::string & level,
const std::string & lower_chain_name,
int lower_chain_counter,
std::vector< HLTSignature * > && signatureList )

constructor with configuration data

Parameters
chain_namechain name
chain_counterchain counter
chain_versionchain version
leveltrigger level
lower_chain_namename of lower chain
lower_chain_countercounter of lower chain
prescaleprescale value of the chain
pass_throughpass_through flag of the chain
signatureListlist of signatures that the chain consists of

Definition at line 40 of file TrigConfHLTData/Root/HLTChain.cxx.

46 :
50 m_level ( level ),
53 m_EB_after_step (-1 ),
55{
58 // create signalture id's (labels)
62}
const std::string & lower_chain_name() const
std::vector< HLTSignature * > & signatureList()
void createSignatureLabels()
label the signatures
std::vector< HLTSignature * > m_HLTSignatureList
static HLTHash string2hash(std::string_view, const std::string &category=s_defaultCategory)
hash function translating TE names into identifiers
void setName(const std::string &name)
void setVersion(unsigned int version)

◆ HLTChain() [3/3]

HLTChain::HLTChain ( const HLTChain & ch)

copy constructor

does a deep copy of everything underneath

Definition at line 65 of file TrigConfHLTData/Root/HLTChain.cxx.

65 :
66 TrigConfData(o),
67 m_chain_hash_id ( o.m_chain_hash_id ),
68 m_chain_counter ( o.m_chain_counter ),
69 m_chain_version ( o.m_chain_version ),
70 m_level ( o.m_level ),
71 m_lower_chain_name ( o.m_lower_chain_name ),
72 m_lower_chain_counter ( o.m_lower_chain_counter ),
73 m_lower_chain_counters( o.m_lower_chain_counters ),
74 m_EB_after_step ( o.m_EB_after_step ),
75 m_prescales ( o.m_prescales ),
76 m_groups ( o.m_groups ),
77 m_has_l2 ( o.m_has_l2 )
78{
79 // deep copy to ensure ownership
80 for(HLTSignature* sig : o.m_HLTSignatureList)
81 m_HLTSignatureList.push_back(new HLTSignature(*sig));
82
83 for(HLTTriggerType* tt : o.m_HLTTriggerTypeList)
84 m_HLTTriggerTypeList.push_back(new HLTTriggerType(*tt));
85
86 for(HLTStreamTag* tt : o.m_streams_orig)
87 m_streams_orig.push_back(new HLTStreamTag(*tt));
88
89 for(HLTStreamTag* tt : o.m_streams)
90 m_streams.push_back(new HLTStreamTag(*tt));
91
92 for(const auto& strstream : o.m_streams_map)
93 m_streams_map.emplace(strstream.first, new HLTStreamTag(*strstream.second) ) ;
94}
std::unordered_map< std::string, HLTStreamTag * > m_streams_map
std::vector< HLTStreamTag * > m_streams_orig
std::vector< int > m_lower_chain_counters
counters of the lower trigger items if more than 1
std::vector< HLTStreamTag * > m_streams
std::vector< HLTTriggerType * > m_HLTTriggerTypeList

◆ ~HLTChain()

TrigConf::HLTChain::~HLTChain ( )
overridevirtual

destructor

Definition at line 97 of file TrigConfHLTData/Root/HLTChain.cxx.

97 {
98 for(HLTSignature *sig : m_HLTSignatureList) delete sig;
99 for(HLTTriggerType *tt : m_HLTTriggerTypeList) delete tt;
100 clearStreams();
101}

Member Function Documentation

◆ __str__()

string HLTChain::__str__ ( ) const
overridevirtual

Reimplemented from TrigConf::TrigConfData.

Definition at line 465 of file TrigConfHLTData/Root/HLTChain.cxx.

465 {
466 stringstream s;
467 s << *this;
468 return s.str();
469}

◆ addGroup()

void TrigConf::HLTChain::addGroup ( const std::string & group)
inline

Definition at line 132 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

132{ m_groups.insert(group); }

◆ addStream()

void TrigConf::HLTChain::addStream ( HLTStreamTag * stream)

Definition at line 239 of file TrigConfHLTData/Root/HLTChain.cxx.

239 {
240 if(m_streams_map.find(stream->name()) != m_streams_map.end())
241 throw runtime_error(string("Can not add stream '")+ stream->name() + "' to chain '" + name() + "', since it exists already.");
242
243 m_streams_orig.push_back(stream);
244 HLTStreamTag *cp = new HLTStreamTag(*stream);
245 m_streams.push_back(cp);
246 m_streams_map.insert(std::pair<std::string, HLTStreamTag*>(cp->name(),cp));
247
248 // copy the stream prescales from the prescales to the live prescales
249 std::pair<bool, float> sps = prescales().getStreamPrescale(cp->name());
250 if(sps.first)
251 cp->set_prescale(sps.second);
252}
std::pair< bool, float > getStreamPrescale(std::string_view streamName) const
const std::string & name() const

◆ chain_counter()

int TrigConf::HLTChain::chain_counter ( ) const
inline

Definition at line 74 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

74{ return m_chain_counter; }

◆ chain_hash_id()

unsigned int TrigConf::HLTChain::chain_hash_id ( ) const
inline

Definition at line 81 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

81{ return m_chain_hash_id; }

◆ chain_name()

const std::string & TrigConf::HLTChain::chain_name ( ) const
inline

Definition at line 73 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

73{ return name(); }

◆ chain_version()

int TrigConf::HLTChain::chain_version ( ) const
inline

Definition at line 75 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

75{ return m_chain_version; }

◆ clearGroups()

void TrigConf::HLTChain::clearGroups ( )
inline

Definition at line 133 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

133{ m_groups.clear(); }

◆ clearStreams()

void TrigConf::HLTChain::clearStreams ( )

Definition at line 255 of file TrigConfHLTData/Root/HLTChain.cxx.

255 {
256 // The memory management between the streams map and the stream vectors is completely confused
257 // It's going to be too invasive a change to fix that directly so instead just make sure that
258 // everything is correctly deleted at the end
259 std::unordered_set<HLTStreamTag *> deleted;
260 for(HLTStreamTag *s : m_streams_orig)
261 if (deleted.insert(s).second)
262 delete s;
263 for(HLTStreamTag *s : m_streams)
264 if (deleted.insert(s).second)
265 delete s;
266 for (auto &p : m_streams_map)
267 if (deleted.insert(p.second).second)
268 delete p.second;
269 m_streams_orig.clear();
270 m_streams.clear();
271 m_streams_map.clear();
272}

◆ comment()

const std::string & TrigConf::TrigConfData::comment ( ) const
inlineinherited

Definition at line 23 of file TrigConfData.h.

23{return m_comment;}

◆ compareTo()

TrigConf::DiffStruct * TrigConf::HLTChain::compareTo ( const HLTChain * o) const

Definition at line 298 of file TrigConfHLTData/Root/HLTChain.cxx.

298 {
299 DiffStruct * ds = new DiffStruct("CHAIN");
300 ds->check("chain_counter", chain_counter(), o->chain_counter());
301 ds->check("lower_chain_name", orderLowerChainNames(lower_chain_name()), orderLowerChainNames(o->lower_chain_name()) );
302 ds->check("level", level(), o->level());
303 ds->check("prescale", prescales().prescale(), o->prescales().prescale());
304 ds->check("pass_through", prescales().pass_through(), o->prescales().pass_through());
305// for(StreamTag* st : streamTagList()) {
306// o->streamTagList() st->name()
307
308// }
309
310
311 if(!ds->empty()) {
312 ds->name = name();
313 } else {
314 delete ds; ds=0;
315 }
316 return ds;
317
318}
float pass_through() const
Definition HLTPrescale.h:57
float prescale() const
Definition HLTPrescale.h:56

◆ createSignatureLabels()

void TrigConf::HLTChain::createSignatureLabels ( )

label the signatures

Definition at line 183 of file TrigConfHLTData/Root/HLTChain.cxx.

183 {
184 for (HLTSignature* signature : m_HLTSignatureList) {
185 std::stringstream os;
186 os << chain_name() << "_" << signature->signature_counter();
187 signature->set_label( os.str() );
188 }
189}

◆ EB_after_step()

int TrigConf::HLTChain::EB_after_step ( ) const
inline

Definition at line 83 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

83{ return m_EB_after_step; }

◆ groupList()

const std::set< std::string > & TrigConf::HLTChain::groupList ( ) const
inline

Definition at line 130 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

130{ return m_groups; }

◆ groups()

const std::set< std::string > & TrigConf::HLTChain::groups ( ) const
inline

Definition at line 128 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

128{ return m_groups; }

◆ has_l2()

bool TrigConf::HLTChain::has_l2 ( ) const
inline

Definition at line 78 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

78{ return m_has_l2; }

◆ hasMultipleLowerChains()

bool TrigConf::HLTChain::hasMultipleLowerChains ( ) const

Definition at line 105 of file TrigConfHLTData/Root/HLTChain.cxx.

105 {
106 return m_lower_chain_name.find(',')!=std::string::npos;
107}

◆ id()

unsigned int TrigConf::TrigConfData::id ( ) const
inlineinherited

Definition at line 21 of file TrigConfData.h.

21{return m_id;}

◆ indent()

std::ostream & TrigConfData::indent ( std::ostream & o,
int lvl,
int size ) const
protectedinherited

Definition at line 23 of file TrigConfData.cxx.

23 {
24 int width = lvl*size;
25 if(width==0) return o;
26 o << setw(lvl*size) << " ";
27 return o;
28}
size_t size() const
Number of registered mappings.
const double width

◆ lastStep()

unsigned int HLTChain::lastStep ( ) const

Definition at line 169 of file TrigConfHLTData/Root/HLTChain.cxx.

169 {
170 if(m_HLTSignatureList.empty())
171 return 0;
172 return m_HLTSignatureList[m_HLTSignatureList.size()-1]->step();
173}

◆ leg_multiplicities()

const std::vector< size_t > & TrigConf::HLTChain::leg_multiplicities ( ) const
inline

Definition at line 84 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

84{ return m_leg_multiplicities; }
std::vector< size_t > m_leg_multiplicities
Number of objects required per leg.

◆ level()

const std::string & TrigConf::HLTChain::level ( ) const
inline

Definition at line 76 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

76{ return m_level; }

◆ level_enum()

HLTLevel TrigConf::HLTChain::level_enum ( ) const
inline

Definition at line 77 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

77{ return m_level=="L2"?L2:(m_level=="EF"?EF:HLT); }

◆ lower_chain_counter()

int TrigConf::HLTChain::lower_chain_counter ( ) const
inline

Definition at line 80 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

80{ return m_lower_chain_counter; }

◆ lower_chain_counters()

const std::vector< int > & TrigConf::HLTChain::lower_chain_counters ( ) const

Definition at line 111 of file TrigConfHLTData/Root/HLTChain.cxx.

111 {
113}

◆ lower_chain_hash_id()

unsigned int TrigConf::HLTChain::lower_chain_hash_id ( ) const
inline

Definition at line 82 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

82{ return m_lower_chain_hash_id; }

◆ lower_chain_hash_ids()

vector< unsigned int > TrigConf::HLTChain::lower_chain_hash_ids ( ) const

Definition at line 125 of file TrigConfHLTData/Root/HLTChain.cxx.

125 {
126 vector<unsigned int> ids;
127 vector<std::string> names = parse(m_lower_chain_name);
128 for ( unsigned i = names.size(); i-- ; ) {
129 ids.push_back(HLTUtils::string2hash(names[i]));
130 }
131 return ids;
132}
std::vector< std::string > parse(std::string names)

◆ lower_chain_name()

const std::string & TrigConf::HLTChain::lower_chain_name ( ) const
inline

Definition at line 79 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

79{ return m_lower_chain_name; }

◆ name()

const std::string & TrigConf::TrigConfData::name ( ) const
inlineinherited

Definition at line 22 of file TrigConfData.h.

22{return m_name;}

◆ operator<()

bool TrigConf::HLTChain::operator< ( const HLTChain & e) const
inline

Definition at line 150 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

150 {
151 return m_level[0]>e.m_level[0] ||
152 (m_level[0]==e.m_level[0] && m_chain_counter<e.m_chain_counter);
153 }

◆ pass_through()

float TrigConf::HLTChain::pass_through ( ) const
inline

Definition at line 144 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

144{ return prescales().pass_through(); }

◆ prescale()

float TrigConf::HLTChain::prescale ( ) const
inline

Definition at line 143 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

143{ return prescales().prescale(); }

◆ prescales() [1/2]

HLTPrescale & TrigConf::HLTChain::prescales ( )
inline

Definition at line 141 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

141{ return m_prescales; }

◆ prescales() [2/2]

const HLTPrescale & TrigConf::HLTChain::prescales ( ) const
inline

Definition at line 142 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

142{ return m_prescales; }

◆ print()

void TrigConf::HLTChain::print ( const std::string & indent = "",
unsigned int detail = 1 ) const
overridevirtual

print the chain

Implements TrigConf::TrigConfData.

Definition at line 368 of file TrigConfHLTData/Root/HLTChain.cxx.

368 {
369 if(detail>=2) {
370 int dp = cout.precision();
371 cout.unsetf(ios_base::floatfield);
372 cout.precision(3);
373 //cout.setf(std::ios::fixed, std::ios::floatfield);
374
375 cout << indent << "HLTChain chainid = " << chain_counter() << " ";
376 printNameIdV();
377 if(detail>=3) {
378 cout << " | counter: " << chain_counter();
379 if(level()!="HLT") {
380 cout << " | " << level()
381 << " | lower chain: " << lower_chain_name()
382 << " | lower chain counter: " << lower_chain_counter();
383 } else {
384 cout << " | CTP input: " << lower_chain_name()
385 << " | lower chain counter: " << lower_chain_counter();
386 }
387 cout << " | prescale: " << prescale()
388 << " | pass through: " << pass_through();
389
390 cout << " | rerun: " << prescales().getRerunPrescales().size() << " [ ";
391 for(HLTPrescale::value_type rrps : prescales().getRerunPrescales())
392 cout << rrps.first << ":" << rrps.second << " ";
393 cout << "]" << std::endl;
394
395 }
396 if(detail>=4) {
397 cout << indent << " Groups : " << groups().size() << " [ ";
398 for(const string& group : groups()) cout << "'" << group << "' ";
399 cout << "]" << std::endl;
400
401 cout << indent << " Trigger type bits : " << triggerTypeList().size() << " [ ";
402 for(HLTTriggerType* tt : triggerTypeList()) cout << tt->bit() << " ";
403 cout << "]" << std::endl;
404
405 cout << indent << " Streams : " << streams().size() << endl;
406 for(HLTStreamTag* streamTag : streams()) cout << indent << " " << *streamTag;
407
408 cout << indent << " Steps : " << signatureList().size() << endl;
409 for(HLTSignature* sig : signatureList()) sig->print(indent);
410 cout << indent << "---------------------------------------------------------- " << endl;
411 }
412
413 cout.precision(dp);
414 }
415}
const std::vector< HLTStreamTag * > & streams() const
const std::set< std::string > & groups() const
std::vector< HLTTriggerType * > & triggerTypeList()
PrescaleMap_t::value_type value_type
Definition HLTPrescale.h:47
const PrescaleMap_t & getRerunPrescales() const
Definition HLTPrescale.h:60
std::ostream & indent(std::ostream &o, int lvl, int size) const
void printNameIdV(const std::string &indent="") const

◆ printNameIdV()

void TrigConfData::printNameIdV ( const std::string & indent = "") const
inherited

Definition at line 31 of file TrigConfData.cxx.

31 {
32 cout << indent << name();
33 if(id()>0 || version()>0)
34 cout << " (id=" << id() << "/v=" << version() << ")";
35 cout << endl;
36 if(comment()!="")
37 cout << indent << "Comment: " << comment() << endl;
38}
unsigned int id() const
const std::string & comment() const
unsigned int version() const

◆ rerun_prescale() [1/2]

float TrigConf::HLTChain::rerun_prescale ( ) const
inline

Definition at line 147 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

147{ return prescales().getRerunPrescale("").second; }
std::pair< bool, float > getRerunPrescale(std::string_view targetName) const

◆ rerun_prescale() [2/2]

std::pair< bool, float > TrigConf::HLTChain::rerun_prescale ( const std::string & targetName) const
inline

Definition at line 145 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

145{ return prescales().getRerunPrescale(targetName); }

◆ set_chain_counter()

HLTChain & TrigConf::HLTChain::set_chain_counter ( int chain_counter)
inline

Definition at line 94 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

94{ m_chain_counter = chain_counter; return *this; }

◆ set_chain_name()

TrigConf::HLTChain & TrigConf::HLTChain::set_chain_name ( const std::string & chain_name)

Definition at line 136 of file TrigConfHLTData/Root/HLTChain.cxx.

136 {
139 return *this;
140}

◆ set_chain_version()

HLTChain & TrigConf::HLTChain::set_chain_version ( int chain_version)
inline

Definition at line 95 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

95{ m_chain_version = chain_version; return *this; }

◆ set_EB_after_step()

HLTChain & TrigConf::HLTChain::set_EB_after_step ( int EB_after_step)
inline

◆ set_groupList()

HLTChain & TrigConf::HLTChain::set_groupList ( const std::set< std::string > & groups)
inline

Definition at line 103 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

103{ m_groups = groups; return *this; }

◆ set_has_l2()

HLTChain & TrigConf::HLTChain::set_has_l2 ( const bool has_l2)
inline

Definition at line 97 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

97{ m_has_l2 = has_l2; return *this; }

◆ set_leg_multiplicities()

HLTChain & TrigConf::HLTChain::set_leg_multiplicities ( const std::vector< size_t > & mult)
inline

Definition at line 105 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

105{ m_leg_multiplicities = mult; return *this; }

◆ set_level()

HLTChain & TrigConf::HLTChain::set_level ( std::string_view level)
inline

Definition at line 96 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

96{ m_level.assign(level); return *this; }

◆ set_lower_chain_counter()

HLTChain & TrigConf::HLTChain::set_lower_chain_counter ( int lower_chain_counter)
inline

Definition at line 99 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

◆ set_lower_chain_counters()

HLTChain & TrigConf::HLTChain::set_lower_chain_counters ( const std::vector< int > & low_ccs)
inline

Definition at line 100 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

100{ m_lower_chain_counters = low_ccs; return *this; }

◆ set_lower_chain_name()

TrigConf::HLTChain & TrigConf::HLTChain::set_lower_chain_name ( const std::string & lower_chain_name)

◆ set_pass_through()

HLTChain & TrigConf::HLTChain::set_pass_through ( float pass_through)
inline

Definition at line 139 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

139{ m_prescales.setPassThrough(pass_through); return *this; }

◆ set_prescale()

HLTChain & TrigConf::HLTChain::set_prescale ( float prescale)
inline

Definition at line 137 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

137{ m_prescales.setPrescale(prescale); return *this; }

◆ set_prescales()

TrigConf::HLTChain & TrigConf::HLTChain::set_prescales ( const HLTPrescale & prescales)

Definition at line 208 of file TrigConfHLTData/Root/HLTChain.cxx.

208 {
209
210 // copy the original (menu) stream prescales to the live set
211 for(HLTStreamTag* stream : m_streams_orig) {
212 HLTStreamTag* target = m_streams_map[stream->name()];
213 target->set_prescale(stream->prescale());
214 }
215
216 // copy the stream prescales from the new HLTPprescale to the live set
217
218 for(HLTPrescale::value_type ps : prescales.getStreamPrescales()) {
219 const string & streamName = ps.first;
220
221 HLTStreamTag* streamTag = findStreamTag(m_streams, streamName);
222
223 if(streamTag) {
224 streamTag->set_prescale(ps.second);
225 } else {
226 //throw runtime_error(string("Can not set prescale for stream ")+ ps.first + "since chain '" + name() + "' does not write to that stream.");
227 cerr << "TrigConf::HLTChain WARNING Can not set prescale for stream '" + streamName + "' since chain '" + name() + "' does not write to that stream. Available are" << endl;
228 for(auto stream : m_streams) {
229 cout << " Available are " << stream->name() << endl;
230 }
231 }
232 }
234 return *this;
235}
void set_prescale(float val)

◆ set_rerun_prescale()

HLTChain & TrigConf::HLTChain::set_rerun_prescale ( float rerun_prescale)
inline

Definition at line 138 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

138{ m_prescales.setRerunPrescale("",rerun_prescale); return *this; }
std::pair< bool, float > rerun_prescale(const std::string &targetName) const

◆ set_signatureList()

TrigConf::HLTChain & TrigConf::HLTChain::set_signatureList ( const std::vector< HLTSignature * > & sigList)

Definition at line 162 of file TrigConfHLTData/Root/HLTChain.cxx.

162 {
163 m_HLTSignatureList = sigList;
165 return *this;
166}

◆ set_triggerTypeList()

TrigConf::HLTChain & TrigConf::HLTChain::set_triggerTypeList ( const std::vector< HLTTriggerType * > & trigList)

Definition at line 143 of file TrigConfHLTData/Root/HLTChain.cxx.

144{
145 for (HLTTriggerType *tt : m_HLTTriggerTypeList)
146 delete tt;
147 m_HLTTriggerTypeList = trigList;
148 return *this;
149}

◆ setComment()

void TrigConf::TrigConfData::setComment ( const std::string & c)
inlineinherited

Definition at line 32 of file TrigConfData.h.

◆ setId()

void TrigConf::TrigConfData::setId ( unsigned int id)
inlineinherited

Definition at line 29 of file TrigConfData.h.

29{ m_id=id; }

◆ setName()

void TrigConf::TrigConfData::setName ( const std::string & name)
inlineinherited

Definition at line 30 of file TrigConfData.h.

30{ m_name = name;}

◆ setSMK()

void TrigConf::TrigConfData::setSMK ( int id)
inlineinherited

Definition at line 28 of file TrigConfData.h.

28{m_smk=id;}

◆ setSuperMasterTableId()

void TrigConf::TrigConfData::setSuperMasterTableId ( int id)
inlineinherited

Definition at line 27 of file TrigConfData.h.

27{m_smk=id;}

◆ setVersion()

void TrigConf::TrigConfData::setVersion ( unsigned int version)
inlineinherited

Definition at line 31 of file TrigConfData.h.

◆ shiftStepCounter()

void HLTChain::shiftStepCounter ( int shift)

Definition at line 176 of file TrigConfHLTData/Root/HLTChain.cxx.

176 {
177 for(HLTSignature* sig : m_HLTSignatureList)
178 sig->set_signature_counter( sig->signature_counter() + shift );
179}

◆ signatureList() [1/2]

std::vector< HLTSignature * > & TrigConf::HLTChain::signatureList ( )
inline

Definition at line 109 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

109{ return m_HLTSignatureList; }

◆ signatureList() [2/2]

const std::vector< HLTSignature * > & TrigConf::HLTChain::signatureList ( ) const
inline

Definition at line 110 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

110{ return m_HLTSignatureList; }

◆ signatures()

const std::vector< HLTSignature * > & TrigConf::HLTChain::signatures ( ) const
inline

Definition at line 111 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

111{ return m_HLTSignatureList; }

◆ smk()

unsigned int TrigConf::TrigConfData::smk ( ) const
inlineinherited

Definition at line 20 of file TrigConfData.h.

20{return m_smk;}

◆ stream_prescale()

std::pair< bool, float > TrigConf::HLTChain::stream_prescale ( const std::string & streamName) const

Definition at line 275 of file TrigConfHLTData/Root/HLTChain.cxx.

275 {
276 std::unordered_map<std::string, HLTStreamTag*>::const_iterator i = m_streams_map.find(streamName);
277 bool found = (i!=m_streams_map.cend());
278 float ps = found ? i->second->prescale() : 0;
279 return std::make_pair(found,ps);
280}

◆ streams()

const std::vector< HLTStreamTag * > & TrigConf::HLTChain::streams ( ) const
inline

Definition at line 119 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

119{ return m_streams; }

◆ streams_orig()

const std::vector< HLTStreamTag * > & TrigConf::HLTChain::streams_orig ( ) const
inline

Definition at line 123 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

123{ return m_streams_orig; }

◆ streamTagList()

const std::vector< HLTStreamTag * > & TrigConf::HLTChain::streamTagList ( ) const
inline

Definition at line 121 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

121{ return m_streams; } //deprecated

◆ superMasterTableId()

int TrigConf::TrigConfData::superMasterTableId ( ) const
inlineinherited

Definition at line 19 of file TrigConfData.h.

19{return (int)m_smk;}

◆ triggerTypeList() [1/2]

std::vector< HLTTriggerType * > & TrigConf::HLTChain::triggerTypeList ( )
inline

Definition at line 89 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

89{ return m_HLTTriggerTypeList; }

◆ triggerTypeList() [2/2]

const std::vector< HLTTriggerType * > & TrigConf::HLTChain::triggerTypeList ( ) const
inline

Definition at line 90 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

90{ return m_HLTTriggerTypeList; }

◆ version()

unsigned int TrigConf::TrigConfData::version ( ) const
inlineinherited

Definition at line 24 of file TrigConfData.h.

24{return m_version;}

◆ writeXML()

void TrigConf::HLTChain::writeXML ( std::ofstream & xmlfile)

Definition at line 322 of file TrigConfHLTData/Root/HLTChain.cxx.

322 {
323 xmlfile << " <CHAIN chain_counter=\"" << chain_counter() << "\" "
324 << "chain_name=\"" << name() << "\" "
325 << "level=\"" << m_level << "\" "
326 << "lower_chain_name=\"" << m_lower_chain_name << "\" "
327 << "pass_through=\"" << prescales().pass_through() << "\" "
328 << "prescale=\"" << prescales().prescale() << "\">"
329 << endl;
330
331 xmlfile << " <PRESCALES"
332 << " chain_counter=\"" << chain_counter() << "\""
333 << " level=\"" << m_level << "\""
334 << " prescale=\"" << prescales().prescale() << "\""
335 << " pass_through=\"" << prescales().pass_through() << "\"";
336 if(prescales().getRerunPrescales().size()==0) {
337 xmlfile << "/>" << endl;
338 } else {
339 xmlfile << ">" << endl;
340 for(HLTPrescale::value_type rerun_ps : prescales().getRerunPrescales())
341 xmlfile << " <RERUN_PRESCALES target=\"" << rerun_ps.first << "\" prescale=\"" << rerun_ps.second << "\"/>" << endl;
342 xmlfile << " </PRESCALES>" << endl;
343 }
344
345 xmlfile << " <TRIGGERTYPE_LIST/>" << endl;
346
347 xmlfile << " <STREAMTAG_LIST>" << endl;
348 for (const TrigConf::HLTStreamTag* streamTag : m_streams)
349 streamTag->writeXML(xmlfile);
350 xmlfile << " </STREAMTAG_LIST>" << endl;
351
352 xmlfile << " <GROUP_LIST>" << endl;
353 for (const string& group : m_groups)
354 xmlfile << " <GROUP name=\"" << group << "\"/>" << endl;
355 xmlfile << " </GROUP_LIST>" << endl;
356
357 xmlfile << " <SIGNATURE_LIST>" << endl;
358 for(TrigConf::HLTSignature* signature : m_HLTSignatureList)
359 signature->writeXML(xmlfile);
360 xmlfile << " </SIGNATURE_LIST>" << endl;
361
362 xmlfile << " </CHAIN>" << endl;
363
364 return;
365}
static std::vector< std::string > xmlfile
Definition iLumiCalc.h:29

◆ operator<<

std::ostream & operator<< ( std::ostream & ,
const HLTChain &  )
friend

Member Data Documentation

◆ ef

unsigned int TrigConf::HLTChain::ef {0}

Definition at line 201 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

201{0};

◆ l2

unsigned int TrigConf::HLTChain::l2 {0}

Definition at line 200 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

200{0};

◆ m_chain_counter

int TrigConf::HLTChain::m_chain_counter {}
private

chain counter

Definition at line 173 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

173{};

◆ m_chain_hash_id

unsigned int TrigConf::HLTChain::m_chain_hash_id {}
private

hash value from m_chain_name, this is used to identify the chain in the HLTResult

Definition at line 172 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

172{};

◆ m_chain_version

int TrigConf::HLTChain::m_chain_version {}
private

chain version

Definition at line 174 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

174{};

◆ m_comment

std::string TrigConf::TrigConfData::m_comment
privateinherited

Definition at line 48 of file TrigConfData.h.

◆ m_EB_after_step

int TrigConf::HLTChain::m_EB_after_step {}
private

EB_after_step flag.

Definition at line 180 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

180{};

◆ m_groups

std::set<std::string> TrigConf::HLTChain::m_groups
private

Definition at line 186 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

◆ m_has_l2

bool TrigConf::HLTChain::m_has_l2 {false}
private

Definition at line 192 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

192{false};

◆ m_HLTSignatureList

std::vector<HLTSignature*> TrigConf::HLTChain::m_HLTSignatureList
private

Definition at line 184 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

◆ m_HLTTriggerTypeList

std::vector<HLTTriggerType*> TrigConf::HLTChain::m_HLTTriggerTypeList
private

Definition at line 185 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

◆ m_id

unsigned int TrigConf::TrigConfData::m_id
privateinherited

Definition at line 45 of file TrigConfData.h.

◆ m_leg_multiplicities

std::vector<size_t> TrigConf::HLTChain::m_leg_multiplicities
private

Number of objects required per leg.

NOTE: Run3 only quantity

Definition at line 181 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

◆ m_level

std::string TrigConf::HLTChain::m_level
private

trigger level

Definition at line 175 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

◆ m_lower_chain_counter

int TrigConf::HLTChain::m_lower_chain_counter {}
private

counter of the lower trigger chain (or the ID of the LVL1 trigger item)

Definition at line 177 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

177{};

◆ m_lower_chain_counters

std::vector<int> TrigConf::HLTChain::m_lower_chain_counters
private

counters of the lower trigger items if more than 1

Definition at line 178 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

◆ m_lower_chain_hash_id

unsigned int TrigConf::HLTChain::m_lower_chain_hash_id {}
private

hash value from m_lower_chain_name, this is used to match to a chain from the previous trigger level

Definition at line 179 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

179{};

◆ m_lower_chain_name

std::string TrigConf::HLTChain::m_lower_chain_name
private

name of the lower trigger chain (or the LVL1 trigger item)

Definition at line 176 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

◆ m_name

std::string TrigConf::TrigConfData::m_name
privateinherited

Definition at line 46 of file TrigConfData.h.

◆ m_prescales

HLTPrescale TrigConf::HLTChain::m_prescales
private

Definition at line 182 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

◆ m_smk

unsigned int TrigConf::TrigConfData::m_smk
privateinherited

Definition at line 44 of file TrigConfData.h.

◆ m_streams

std::vector<HLTStreamTag*> TrigConf::HLTChain::m_streams
private

Definition at line 188 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

◆ m_streams_map

std::unordered_map<std::string, HLTStreamTag*> TrigConf::HLTChain::m_streams_map
private

Definition at line 189 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

◆ m_streams_orig

std::vector<HLTStreamTag*> TrigConf::HLTChain::m_streams_orig
private

Definition at line 187 of file TrigConfHLTData/TrigConfHLTData/HLTChain.h.

◆ m_version

unsigned int TrigConf::TrigConfData::m_version
privateinherited

Definition at line 47 of file TrigConfData.h.

◆ [struct]

struct { ... } TrigConf::HLTChain::mergeCounter

The documentation for this class was generated from the following files: