1 |
loizides |
1.1 |
//--------------------------------------------------------------------------------------------------
|
2 |
loizides |
1.4 |
// $Id: GenFakesMod.h,v 1.3 2009/07/13 11:27:13 loizides Exp $
|
3 |
loizides |
1.1 |
//
|
4 |
loizides |
1.4 |
// GenFakesMod
|
5 |
loizides |
1.1 |
//
|
6 |
|
|
// This Module generates a collection of FakeEventHeaders containing information
|
7 |
loizides |
1.4 |
// about possible fakes and their weight. The collection generated takes into account
|
8 |
|
|
// all possible faking combinatorics from the given set of fakable objects.
|
9 |
loizides |
1.1 |
//
|
10 |
|
|
// Authors: S.Xie
|
11 |
|
|
//--------------------------------------------------------------------------------------------------
|
12 |
|
|
|
13 |
|
|
#ifndef MITPHYSICS_FAKEMODS_GENFAKESMOD_H
|
14 |
|
|
#define MITPHYSICS_FAKEMODS_GENFAKESMOD_H
|
15 |
|
|
|
16 |
|
|
#include "MitAna/TreeMod/interface/BaseMod.h"
|
17 |
|
|
|
18 |
|
|
namespace mithep
|
19 |
|
|
{
|
20 |
loizides |
1.3 |
class FakeRate;
|
21 |
|
|
|
22 |
loizides |
1.1 |
class GenFakesMod : public BaseMod
|
23 |
|
|
{
|
24 |
|
|
public:
|
25 |
|
|
GenFakesMod(const char *name="GenFakesMod",
|
26 |
|
|
const char *title="Fake Object Generation Module");
|
27 |
|
|
|
28 |
|
|
const char *GetCleanElectronsName() const { return fCleanElectronsName; }
|
29 |
|
|
const char *GetCleanMuonsName() const { return fCleanMuonsName; }
|
30 |
|
|
const char *GetCleanPhotonsName() const { return fCleanPhotonsName; }
|
31 |
|
|
const char *GetCleanJetsName() const { return fCleanJetsName; }
|
32 |
phedex |
1.2 |
const char *GetElFakeableObjsName() const { return fElFakeableObjsName; }
|
33 |
|
|
const char *GetMuFakeableObjsName() const { return fMuFakeableObjsName; }
|
34 |
loizides |
1.1 |
const char *GetMCLeptonsName() const { return fMCLeptonsName; }
|
35 |
|
|
const char *GetMCTausName() const { return fMCTausName; }
|
36 |
|
|
const char *GetFakeEventHeadersName() const { return fFakeEventHeadersName; }
|
37 |
|
|
const char *GetOutputName() const { return GetFakeEventHeadersName(); }
|
38 |
|
|
const Bool_t GetUse2DFakeRate() const { return fUse2DFakeRate; }
|
39 |
|
|
const Bool_t GetUseFitFunction() const { return fUseFitFunction; }
|
40 |
|
|
|
41 |
|
|
void SetCleanElectronsName(const char *name) { fCleanElectronsName = name; }
|
42 |
|
|
void SetCleanMuonssName(const char *name) { fCleanMuonsName = name; }
|
43 |
|
|
void SetCleanPhotonsName(const char *name) { fCleanPhotonsName = name; }
|
44 |
|
|
void SetCleanJetsName(const char *name) { fCleanJetsName = name; }
|
45 |
phedex |
1.2 |
void SetElFakeableObjsName(const char *name) { fElFakeableObjsName = name; }
|
46 |
|
|
void SetMuFakeableObjsName(const char *name) { fMuFakeableObjsName = name; }
|
47 |
loizides |
1.1 |
void SetMCLeptonsName(const char *name) { fMCLeptonsName = name; }
|
48 |
|
|
void SetMCTausName(const char *name) { fMCTausName = name; }
|
49 |
|
|
void SetFakeEventHeadersName(const char *name) { fFakeEventHeadersName = name; }
|
50 |
|
|
void SetOutputName(const char *name) { SetFakeEventHeadersName(name); }
|
51 |
|
|
void SetElectronFRFilename(const char *name) { fElectronFRFilename = name; }
|
52 |
|
|
void SetMuonFRFilename(const char *name) { fMuonFRFilename = name; }
|
53 |
|
|
void SetUse2DFakeRate(Bool_t b) { fUse2DFakeRate = b; }
|
54 |
|
|
void SetUseFitFunction(Bool_t b) { fUseFitFunction = b; }
|
55 |
|
|
void SetElectronFRFunctionName(const char *name) { fElectronFRFunctionName = name; }
|
56 |
|
|
void SetMuonFRFunctionName(const char *name) { fMuonFRFunctionName = name; }
|
57 |
|
|
void SetElectronFRHistName(const char *name) { fElectronFRHistName = name; }
|
58 |
|
|
void SetMuonFRHistName(const char *name) { fMuonFRHistName = name; }
|
59 |
|
|
|
60 |
|
|
void LoadFakeRate();
|
61 |
|
|
|
62 |
|
|
protected:
|
63 |
|
|
void Process();
|
64 |
|
|
|
65 |
|
|
FakeRate *fFakeRate; //holds the fake probabilities
|
66 |
|
|
TString fElectronFRFilename; //file containing electron fake rate
|
67 |
|
|
TString fMuonFRFilename; //file containing muon fake rate
|
68 |
|
|
Bool_t fUse2DFakeRate; //whether to use fit function or not
|
69 |
|
|
Bool_t fUseFitFunction; //whether to use fit function or not
|
70 |
|
|
TString fElectronFRFunctionName; //fit function containing electron fake rate
|
71 |
|
|
TString fMuonFRFunctionName; //fit function containing muon fake rate
|
72 |
|
|
TString fElectronFRHistName; //hist containing electron fake rate
|
73 |
|
|
TString fMuonFRHistName; //hist containing muon fake rate
|
74 |
|
|
TString fCleanElectronsName; //name of clean electrons (input)
|
75 |
|
|
TString fCleanMuonsName; //name of clean muons (input)
|
76 |
|
|
TString fCleanPhotonsName; //name of clean photons (input)
|
77 |
|
|
TString fCleanJetsName; //name of clean jets (input)
|
78 |
|
|
TString fMCLeptonsName; //name of MC leptons
|
79 |
|
|
TString fMCTausName; //name of MC taus
|
80 |
phedex |
1.2 |
TString fElFakeableObjsName; //name of electron fakeable objects (input)
|
81 |
|
|
TString fMuFakeableObjsName; //name of muon fakeable objects (input)
|
82 |
loizides |
1.4 |
TString fFakeEventHeadersName; //name of FakeEventHeaders (output)
|
83 |
loizides |
1.1 |
|
84 |
loizides |
1.4 |
ClassDef(GenFakesMod, 1) // FakeEventHeader generation module
|
85 |
loizides |
1.1 |
};
|
86 |
|
|
}
|
87 |
|
|
#endif
|