ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitProd/TreeFiller/interface/FillerMCParticles.h
Revision: 1.3
Committed: Fri Sep 5 23:46:09 2008 UTC (16 years, 7 months ago) by bendavid
Content type: text/plain
Branch: MAIN
Changes since 1.2: +9 -2 lines
Log Message:
Fixed filling of simulation info, added config for simultaneous RAW-RECO reading

File Contents

# Content
1 //--------------------------------------------------------------------------------------------------
2 // $Id: FillerMCParticles.h,v 1.2 2008/07/31 12:34:04 loizides Exp $
3 //
4 // FillerMCParticles
5 //
6 // Imlementation of a filler to fill HepMC particles (gen) AND TrackingParticles (sim)
7 // into mithep::MCParticles. Gen and Sim particle information is thus merged into a single
8 // collection.
9 //
10 // Authors: C.Loizides, J.Bendavid
11 //--------------------------------------------------------------------------------------------------
12
13 #ifndef TREEFILLER_FILLERMCPARTICLES_H
14 #define TREEFILLER_FILLERMCPARTICLES_H
15
16 #include <map>
17 #include "FWCore/ParameterSet/interface/ParameterSet.h"
18 #include "MitAna/DataUtil/interface/TreeWriter.h"
19 #include "MitAna/DataTree/interface/Collections.h"
20 #include "MitProd/TreeFiller/interface/BaseFiller.h"
21 #include "MitProd/TreeFiller/interface/AssociationMaps.h"
22 #include "SimDataFormats/Track/interface/SimTrackContainer.h"
23
24 namespace mithep
25 {
26 class FillerMCParticles : public BaseFiller
27 {
28 public:
29 FillerMCParticles(const edm::ParameterSet &cfg, const char *name, bool active=1);
30 ~FillerMCParticles();
31
32 void BookDataBlock(TreeWriter &tws);
33 void FillDataBlock(const edm::Event &e, const edm::EventSetup &es);
34 void ResolveLinks (const edm::Event &e, const edm::EventSetup &es);
35
36 private:
37 Bool_t genActive_; //=true if generated particles are filled
38 Bool_t simActive_; //=true if simulated particles are filled
39 Bool_t trackingActive_; //=true if simulated TrackingParticles are mapped
40 std::string genEdmName_; //edm name of generated particles
41 std::string simEdmName_; //edm name of simulated particles
42 std::string trackingEdmName_; //edm name of simulated TrackingParticles
43 std::string genMapName_; //name of exported map wrt generated particles
44 std::string simMapName_; //name of exported map wrt simulated particles
45 std::string trackingMapName_; //name of exported map wrt simulated TrackingParticles
46 std::string mitName_; //name of MCParticles branch in OAK
47 std::map<unsigned int, SimTrackRef> simTidMap_; //map of SimTracks to G4 track ids
48 mithep::MCParticleArr *mcParticles_; //array of MCParticles
49 mithep::GenParticleMap *genMap_; //map wrt generated particles
50 mithep::SimTrackMap *simMap_; //map wrt simulated particles
51 mithep::TrackingParticleMap *trackingMap_; //map wrt simulated TrackingParticles
52 };
53 }
54 #endif