DAS  3.0
Das Analysis System
getTriggerTurnons.cc File Reference
#include <cassert>
#include <cstdlib>
#include <cmath>
#include <filesystem>
#include <fstream>
#include <iostream>
#include <TH2.h>
#include <TKey.h>
#include <TString.h>
#include "Core/CommonTools/interface/binnings.h"
#include "Core/CommonTools/interface/DASOptions.h"
#include "Core/Trigger/interface/sigmoid.h"
#include "Core/Trigger/interface/match.h"
#include <boost/property_tree/ptree.hpp>
#include <boost/property_tree/info_parser.hpp>
#include "common.h"
#include <darwin.h>
+ Include dependency graph for getTriggerTurnons.cc:

Namespaces

 DAS
 
 DAS::Normalisation
 

Functions

void getTriggerTurnons (const fs::path &input, const fs::path &outputRoot, const fs::path &outputTxt, const pt::ptree &config, const int steering)
 
int main (int argc, char *argv[])
 

Function Documentation

◆ main()

int main ( int  argc,
char *  argv[] 
)
Todo:
get year from metainfo
Todo:
get lumis from metainfo
186 {
187  try {
189 
190  fs::path input, outputRoot, outputTxt;
191 
192  auto options = DAS::Options(
193  "Determine the trigger thresholds and efficiencies.\n"
194  "Strategy:\n"
195  " - For the first trigger (presumably HLT40), only TnP is available\n"
196  " - For all other triggers, emulation is used by default\n"
197  " - The other methods are used as cross-checks",
198  DT::config);
199 
200  options.input ("input", &input, "input ROOT file")
201  .output("outputRoot", &outputRoot, "output ROOT file with trigger efficiency curves")
202  .output("outputTxt" , &outputTxt , "output 2-column text file with turn-on points" )
203  .arg<int>("year", "flags.year", "4-digit year")
204  .arg<fs::path>("luminosities" , "corrections.normalisation.luminosities" , "2-column text file with luminosity per trigger");
205 
206  const auto& config = options(argc, argv);
207  const int steering = options.steering();
208 
209  DAS::Normalisation::getTriggerTurnons(input, outputRoot, outputTxt, config, steering);
210  }
211  catch (boost::exception& e) {
212  DE::Diagnostic(e);
213  return EXIT_FAILURE;
214  }
215 
216  return EXIT_SUCCESS;
217 }
DAS::Normalisation::getTriggerTurnons
void getTriggerTurnons(const fs::path &input, const fs::path &outputRoot, const fs::path &outputTxt, const pt::ptree &config, const int steering)
Get the trigger turn-on points from the trigger curves.
Definition: getTriggerTurnons.cc:39
DYToLL_M-50_13TeV_pythia8_cff_GEN_SIM_RECOBEFMIX_DIGI_L1_DIGI2RAW_L1Reco_RECO.options
options
Definition: DYToLL_M-50_13TeV_pythia8_cff_GEN_SIM_RECOBEFMIX_DIGI_L1_DIGI2RAW_L1Reco_RECO.py:41
Darwin::Exceptions::Diagnostic
void Diagnostic(const boost::exception &e)
Definition: exceptions.h:116
Darwin::Tools::StandardInit
void StandardInit()
Definition: FileUtils.cc:25
Ntupliser_cfg.config
config
Definition: Ntupliser_cfg.py:260
DYToLL_M-50_13TeV_pythia8_cff_GEN_SIM_RECOBEFMIX_DIGI_L1_DIGI2RAW_L1Reco_RECO.input
input
Definition: DYToLL_M-50_13TeV_pythia8_cff_GEN_SIM_RECOBEFMIX_DIGI_L1_DIGI2RAW_L1Reco_RECO.py:35
DAS::Options
Darwin::Tools::Options Options(const char *, int=Darwin::Tools::none)
Constructs Darwin options with the correct commit information.
Definition: DASOptions.cc:14