ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitAna/TreeMod/interface/AnaFwkMod.h
Revision: 1.10
Committed: Sat Sep 22 07:55:22 2012 UTC (12 years, 7 months ago) by ceballos
Content type: text/plain
Branch: MAIN
CVS Tags: Mit_031, Mit_030, Mit_029c, Mit_029b, Mit_030_pre1, Mit_029a
Changes since 1.9: +2 -1 lines
Log Message:
adding true PU

File Contents

# Content
1 //--------------------------------------------------------------------------------------------------
2 // $Id: AnaFwkMod.h,v 1.9 2011/07/22 18:21:01 bendavid Exp $
3 //
4 // AnaFwkMod
5 //
6 // This module collects interesting global information, like the overall number of processed
7 // events and puts this information into the OutputList.
8 //
9 // Authors: C.Loizides
10 //--------------------------------------------------------------------------------------------------
11
12 #ifndef MITANA_TREEEMOD_ANAFWKMOD_H
13 #define MITANA_TREEEMOD_ANAFWKMOD_H
14
15 #include "MitAna/TreeMod/interface/BaseMod.h"
16 #include "MitAna/DataTree/interface/EventHeaderCol.h"
17 #include "MitAna/DataTree/interface/PileupInfoFwd.h"
18
19 class TTree;
20 class TH1D;
21 class TH3D;
22 class TStopwatch;
23
24 namespace mithep
25 {
26 class AnaFwkMod : public BaseMod
27 {
28 public:
29 AnaFwkMod(const char *name="AnaFwkMod",
30 const char *title="Analysis framework module");
31
32 Long64_t GetPrintScale() const { return fPrintScale; }
33 Long64_t GetSkipNEvents() const { return fSkipNEvents; }
34 void SetPrintScale(UInt_t n) { fPrintScale = n; }
35 void SetSkipNEvents(Long64_t n) { fSkipNEvents = n; }
36
37 protected:
38 void BeginRun();
39 Bool_t Notify();
40 void CopyAllEventHeaders();
41 void Process();
42 void SlaveBegin();
43 void SlaveTerminate();
44
45 TString fAllHeadTreeName; //all events tree name
46 TString fAllHeadBrName; //all event headers branch name
47 Long64_t fSkipNEvents; //number of events to skip from beginning (def=0)
48 UInt_t fPrintScale; //scale of when to print event number/timings (def=100)
49 TStopwatch *fSWtotal; //!stop watch for overall timing
50 TStopwatch *fSWevent; //!stop watch per n events
51 EventHeaderArr fAllHeaders; //!pointer to array of all event headers
52 TTree *fAllHeadTree; //!all event headers tree in current file
53 EventHeader *fAllEventHeader; //!all event header
54 Bool_t fReload; //!reload tree after file changed
55 Int_t fCurEnt; //!curent entry in AllEvents tree
56 Int_t fNEventsSkimmed; //!number of skimmed events
57 Int_t fNEventsSkipped; //!number of skippeded events
58 const PileupInfoCol *fPileupInfo; //!
59 TString fPileupInfoName; //Name of PileupInfo Branch for pileup truth distributions
60 Bool_t fDoPUInfo;
61 TH1D *hNPU; //in-time pileup distribution
62 TH3D *hNPU50ns; //three-dimensional pileup distribution (bx=0,-2,+2) suitable for 50ns spacing
63 TH1D *hNPUTrue; //true pileup distribution
64
65 ClassDef(AnaFwkMod, 1) // Analysis framework module
66 };
67 }
68 #endif