DAS  3.0
Das Analysis System
applyMClumi.cc File Reference
#include <cstdlib>
#include <thread>
#include <iostream>
#include <filesystem>
#include <utility>
#include <optional>
#include <TChain.h>
#include <TFile.h>
#include <TROOT.h>
#include <TH1D.h>
#include <TRegexp.h>
#include "Core/Objects/interface/Event.h"
#include "Core/Objects/interface/Jet.h"
#include "Core/CommonTools/interface/ControlPlots.h"
#include "Core/CommonTools/interface/DASOptions.h"
#include "Core/CommonTools/interface/toolbox.h"
#include <darwin.h>
+ Include dependency graph for applyMClumi.cc:

Namespaces

 DAS
 
 DAS::Normalisation
 

Functions

float GetNormFactor (const int steering, const vector< fs::path > &sumWgts, const float xsec)
 
void applyMClumi (const vector< fs::path > &inputs, const vector< fs::path > &sumWgts, const fs::path &output, const pt::ptree &config, const int steering, const DT::Slice slice={1, 0})
 
int main (int argc, char *argv[])
 

Function Documentation

◆ main()

int main ( int  argc,
char *  argv[] 
)
131 {
132  try {
134 
135  vector<fs::path> inputs, sumWgts;
136  fs::path output;
137 
138  auto options = DAS::Options(
139  "Normalise the MC samples to the cross section.",
141  options.inputs("inputs", &inputs, "input ROOT file(s) or directory (n-tuples)")
142  .inputs("sumWgts", &sumWgts, "input ROOT file(s) or directory (output of `getSumWeights`")
143  .output("output", &output, "output ROOT file")
144  .arg<float>("xsection", "corrections.MCnormalisation.xsection", "cross section value");
145 
146  const auto& config = options(argc, argv);
147  const auto& slice = options.slice();
148  const int steering = options.steering();
149 
150  DAS::Normalisation::applyMClumi(inputs, sumWgts, output, config, steering, slice);
151  }
152  catch (boost::exception& e) {
153  DE::Diagnostic(e);
154  return EXIT_FAILURE;
155  }
156 
157  return EXIT_SUCCESS;
158 }
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:131
Darwin::Tools::Friend
@ Friend
activate -F to only fill the new branches
Definition: Options.h:28
DAS::Normalisation::applyMClumi
void applyMClumi(const vector< fs::path > &inputs, const vector< fs::path > &sumWgts, const fs::path &output, const pt::ptree &config, const int steering, const DT::Slice slice={1, 0})
Definition: applyMClumi.cc:60
Darwin::Tools::split
@ split
activate -k and -j to define slice
Definition: Options.h:26
Darwin::Tools::StandardInit
void StandardInit()
Definition: FileUtils.cc:29
Ntupliser_cfg.config
config
Definition: Ntupliser_cfg.py:264
jercExample.inputs
def inputs
Definition: jercExample.py:118
DAS::Options
Darwin::Tools::Options Options(const char *, int=Darwin::Tools::none)
Constructs Darwin options with the correct commit information.
Definition: DASOptions.cc:14