ATLAS Offline Software
Functions
Run2toRun3ConvertersHLT.h File Reference
#include "TrigConfData/HLTMenu.h"
#include "TrigConfHLTData/HLTFrame.h"
Include dependency graph for Run2toRun3ConvertersHLT.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void convertRun2HLTMenuToRun3 (const TrigConf::HLTFrame *frame, const std::string &filename)
 
void convertRun2HLTPrescalesToRun3 (const TrigConf::HLTFrame *frame, const std::string &filename)
 

Function Documentation

◆ convertRun2HLTMenuToRun3()

void convertRun2HLTMenuToRun3 ( const TrigConf::HLTFrame frame,
const std::string &  filename 
)

Definition at line 165 of file Run2toRun3ConvertersHLT.cxx.

165  {
167  convertHLTMenu(frame, menu);
168 
170  writer.writeJsonFile(filename, menu);
171 
172 }

◆ convertRun2HLTPrescalesToRun3()

void convertRun2HLTPrescalesToRun3 ( const TrigConf::HLTFrame frame,
const std::string &  filename 
)

Definition at line 174 of file Run2toRun3ConvertersHLT.cxx.

174  {
176  ptree top;
177  top.put("filetype", "hltprescale");
178  top.put("name", frame->name());
179  ptree pChains;
180  for ( auto cptr : frame->getHLTChainList() ) {
181  ptree pChain;
182  pChain.put("name", cptr->chain_name());
183  pChain.put("counter", cptr->chain_counter());
184  pChain.put("hash", cptr->chain_hash_id());
185  pChain.put("prescale", cptr->prescale());
186  pChain.put("enabled", (cptr->prescale()>0 ? true: false));
187 
188  pChains.push_back(std::make_pair(cptr->chain_name(), pChain));
189  }
190  top.add_child("prescales", pChains);
191  TrigConf::HLTPrescalesSet psk(std::move(top));
192 
194  convertHLTMenu(frame, menu);
195 
197  writer.writeJsonFile(filename, menu, psk);
198 }
TrigConf::JsonFileWriterHLT
Loader of trigger configurations from Json files.
Definition: JsonFileWriterHLT.h:23
TrigConf::TrigConfData::name
const std::string & name() const
Definition: TrigConfData.h:22
TrigConf::HLTMenu
HLT menu configuration.
Definition: HLTMenu.h:21
convertHLTMenu
bool convertHLTMenu(const TrigConf::HLTFrame *frame, TrigConf::HLTMenu &menu)
Definition: Run2toRun3ConvertersHLT.cxx:59
python.TriggerConfig.menu
menu
Definition: TriggerConfig.py:842
menu
make the sidebar many part of the config
Definition: hcg.cxx:551
ptree
boost::property_tree::ptree ptree
Definition: JsonFileLoader.cxx:16
TrigConf::HLTFrame::getHLTChainList
const HLTChainList & getHLTChainList() const
const accessor to the list of HLT chains
Definition: HLTFrame.h:49
CaloCellTimeCorrFiller.filename
filename
Definition: CaloCellTimeCorrFiller.py:24
top
@ top
Definition: TruthClasses.h:64
TrigConf::HLTPrescalesSet
HLT menu configuration.
Definition: HLTPrescalesSet.h:19
example.writer
writer
show summary of content
Definition: example.py:36