hpstr
The Heavy Photon Search Toolkit for Reconstruction (hpstr) provides an interface to physics data from the HPS experiment saved in the LCIO format and converts it into an ROOT based format.
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Classes | Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
TridentWABAnaProcessor Class Reference

#include <TridentWABAnaProcessor.h>

Inheritance diagram for TridentWABAnaProcessor:
Processor

Classes

struct  TridentCand
 
struct  WABCand
 

Public Member Functions

 TridentWABAnaProcessor (const std::string &name, Process &process)
 
 ~TridentWABAnaProcessor ()
 
virtual bool process (IEvent *ievent)
 Process the event and put new data products into it.
 
virtual void initialize (TTree *tree)
 Callback for the Processor to take any necessary action when the processing of events starts, such as creating histograms.
 
virtual void finalize ()
 Callback for the Processor to take any necessary action when the processing of events finishes, such as calculating job-summary quantities.
 
virtual void configure (const ParameterSet &parameters)
 Callback for the Processor to configure itself from the given set of parameters.
 
- Public Member Functions inherited from Processor
 Processor (const std::string &name, Process &process)
 Class constructor.
 
virtual ~Processor ()
 
virtual void initialize (std::string inFilename, std::string outFilename)
 Callback for the Processor to take any necessary action when the processing of events starts, such as initializing files.
 
virtual void setFile (TFile *outFile)
 Set output TFile for AnaProcessors.
 
virtual bool process ()
 Process the histograms and generate analysis output.
 

Private Types

typedef std::map< std::string, std::shared_ptr< TridentHistos > >::iterator reg_it
 

Private Member Functions

VertexmatchPairToVertex (Track *ele, Track *pos, std::vector< Vertex * > &verts)
 
std::pair< Track *, MCParticle * > matchToMCParticle (Track *part, std::vector< MCParticle * > &mcParts)
 
std::vector< CalCluster * > getUnmatchedClusters (std::vector< CalCluster * > &allClusters, std::vector< std::pair< CalCluster *, Track * > > electrons, std::vector< std::pair< CalCluster *, Track * > > positrons)
 
template<typename Iter , typename RandomGenerator >
Iter select_randomly (Iter start, Iter end, RandomGenerator &g)
 
template<typename Iter >
Iter select_randomly (Iter start, Iter end)
 

Private Attributes

std::shared_ptr< BaseSelectorvtxSelector
 
std::shared_ptr< BaseSelectortrkSelector
 
std::vector< std::string > regionSelections_
 
std::vector< std::string > regionWABSelections_
 
std::string selectionCfg_
 
std::string trkSelCfg_
 
TBranch * bfspart_ {nullptr}
 
TBranch * bvtxs_ {nullptr}
 
TBranch * btrks_ {nullptr}
 
TBranch * bhits_ {nullptr}
 
TBranch * brawhits_ {nullptr}
 
TBranch * bclus_ {nullptr}
 
TBranch * btsdata_ {nullptr}
 
TBranch * bmcParts_ {nullptr}
 
TBranch * bevth_ {nullptr}
 
std::vector< Vertex * > * vtxs_ {}
 
std::vector< TrackerHit * > * hits_ {}
 
std::vector< RawSvtHit * > * rawhits_ {}
 
std::vector< Particle * > * fspart_ {}
 
std::vector< Track * > * trks_ {}
 
std::vector< CalCluster * > * clus_ {}
 
std::vector< MCParticle * > * mcParts_ {}
 
EventHeaderevth_ {nullptr}
 
TSDatatsdata_ {nullptr}
 
std::string anaName_ {"vtxAna"}
 
std::string mcColl_ {"MCParticle"}
 
std::string hitColl_ {"SiClustersOnTrack"}
 
std::string rawhitColl_ {"TrackRawHits"}
 
std::string cluColl_ {"Vertices"}
 
std::string vtxColl_ {"Vertices"}
 
std::string tsdataColl_ {"TSData"}
 
std::string fspartColl_ {"FinalStateParticles_KF"}
 
std::string trkColl_ {"GBLTracks"}
 
TTree * tree_ {nullptr}
 
std::shared_ptr< TridentHistos_vtx_histos
 
std::map< std::string, std::shared_ptr< BaseSelector > > _reg_vtx_selectors
 
std::map< std::string, std::shared_ptr< TridentHistos > > _reg_vtx_histos
 
std::map< std::string, std::shared_ptr< FlatTupleMaker > > _reg_tuples
 
std::map< std::string, std::shared_ptr< BaseSelector > > _reg_WAB_selectors
 
std::map< std::string, std::shared_ptr< TridentHistos > > _reg_WAB_histos
 
std::vector< std::string > _regions
 
std::vector< std::string > _regionsWAB
 
std::string histoCfg_ {""}
 
double calTimeOffset_ {-999}
 
double trkTimeOffset_ {-999}
 
double beamE_ {2.3}
 
int isData {0}
 
std::shared_ptr< AnaHelpers_ah
 
int debug_ {0}
 

Additional Inherited Members

- Static Public Member Functions inherited from Processor
static void declare (const std::string &classname, ProcessorMaker *)
 Internal function which is part of the ProcessorFactory machinery.
 
- Protected Attributes inherited from Processor
Processprocess_
 
TFile * outF_ {nullptr}
 
std::string name_
 

Detailed Description

Definition at line 31 of file TridentWABAnaProcessor.h.

Member Typedef Documentation

◆ reg_it

typedef std::map<std::string,std::shared_ptr<TridentHistos>>::iterator reg_it
private

Definition at line 100 of file TridentWABAnaProcessor.h.

Constructor & Destructor Documentation

◆ TridentWABAnaProcessor()

TridentWABAnaProcessor ( const std::string &  name,
Process process 
)

Definition at line 13 of file TridentWABAnaProcessor.cxx.

◆ ~TridentWABAnaProcessor()

Definition at line 19 of file TridentWABAnaProcessor.cxx.

Member Function Documentation

◆ configure()

void configure ( const ParameterSet parameters)
virtual

Callback for the Processor to configure itself from the given set of parameters.

Parameters
parametersParameterSet for configuration.

Reimplemented from Processor.

Definition at line 21 of file TridentWABAnaProcessor.cxx.

◆ finalize()

void finalize ( )
virtual

Callback for the Processor to take any necessary action when the processing of events finishes, such as calculating job-summary quantities.

Implements Processor.

Definition at line 659 of file TridentWABAnaProcessor.cxx.

◆ getUnmatchedClusters()

std::vector< CalCluster * > getUnmatchedClusters ( std::vector< CalCluster * > &  allClusters,
std::vector< std::pair< CalCluster *, Track * > >  electrons,
std::vector< std::pair< CalCluster *, Track * > >  positrons 
)
private

Definition at line 748 of file TridentWABAnaProcessor.cxx.

◆ initialize()

void initialize ( TTree *  tree)
virtual

Callback for the Processor to take any necessary action when the processing of events starts, such as creating histograms.

Parameters
tree

Implements Processor.

Definition at line 54 of file TridentWABAnaProcessor.cxx.

◆ matchPairToVertex()

Vertex * matchPairToVertex ( Track ele,
Track pos,
std::vector< Vertex * > &  verts 
)
private

Definition at line 685 of file TridentWABAnaProcessor.cxx.

◆ matchToMCParticle()

std::pair< Track *, MCParticle * > matchToMCParticle ( Track part,
std::vector< MCParticle * > &  mcParts 
)
private

Definition at line 700 of file TridentWABAnaProcessor.cxx.

◆ process()

bool process ( IEvent ievent)
virtual

Process the event and put new data products into it.

Parameters
eventThe Event to process.
Returns
status of the processing, false will move to next event and skip other processes.

Implements Processor.

Definition at line 128 of file TridentWABAnaProcessor.cxx.

◆ select_randomly() [1/2]

template<typename Iter >
Iter select_randomly ( Iter  start,
Iter  end 
)
inlineprivate

Definition at line 135 of file TridentWABAnaProcessor.h.

◆ select_randomly() [2/2]

template<typename Iter , typename RandomGenerator >
Iter select_randomly ( Iter  start,
Iter  end,
RandomGenerator &  g 
)
inlineprivate

Definition at line 128 of file TridentWABAnaProcessor.h.

Member Data Documentation

◆ _ah

std::shared_ptr<AnaHelpers> _ah
private

Definition at line 108 of file TridentWABAnaProcessor.h.

◆ _reg_tuples

std::map<std::string, std::shared_ptr<FlatTupleMaker> > _reg_tuples
private

Definition at line 91 of file TridentWABAnaProcessor.h.

◆ _reg_vtx_histos

std::map<std::string, std::shared_ptr<TridentHistos> > _reg_vtx_histos
private

Definition at line 90 of file TridentWABAnaProcessor.h.

◆ _reg_vtx_selectors

std::map<std::string, std::shared_ptr<BaseSelector> > _reg_vtx_selectors
private

Definition at line 89 of file TridentWABAnaProcessor.h.

◆ _reg_WAB_histos

std::map<std::string, std::shared_ptr<TridentHistos> > _reg_WAB_histos
private

Definition at line 94 of file TridentWABAnaProcessor.h.

◆ _reg_WAB_selectors

std::map<std::string, std::shared_ptr<BaseSelector> > _reg_WAB_selectors
private

Definition at line 93 of file TridentWABAnaProcessor.h.

◆ _regions

std::vector<std::string> _regions
private

Definition at line 96 of file TridentWABAnaProcessor.h.

◆ _regionsWAB

std::vector<std::string> _regionsWAB
private

Definition at line 97 of file TridentWABAnaProcessor.h.

◆ _vtx_histos

std::shared_ptr<TridentHistos> _vtx_histos
private

Definition at line 86 of file TridentWABAnaProcessor.h.

◆ anaName_

std::string anaName_ {"vtxAna"}
private

Definition at line 75 of file TridentWABAnaProcessor.h.

◆ bclus_

TBranch* bclus_ {nullptr}
private

Definition at line 60 of file TridentWABAnaProcessor.h.

◆ beamE_

double beamE_ {2.3}
private

Definition at line 106 of file TridentWABAnaProcessor.h.

◆ bevth_

TBranch* bevth_ {nullptr}
private

Definition at line 63 of file TridentWABAnaProcessor.h.

◆ bfspart_

TBranch* bfspart_ {nullptr}
private

Definition at line 55 of file TridentWABAnaProcessor.h.

◆ bhits_

TBranch* bhits_ {nullptr}
private

Definition at line 58 of file TridentWABAnaProcessor.h.

◆ bmcParts_

TBranch* bmcParts_ {nullptr}
private

Definition at line 62 of file TridentWABAnaProcessor.h.

◆ brawhits_

TBranch* brawhits_ {nullptr}
private

Definition at line 59 of file TridentWABAnaProcessor.h.

◆ btrks_

TBranch* btrks_ {nullptr}
private

Definition at line 57 of file TridentWABAnaProcessor.h.

◆ btsdata_

TBranch* btsdata_ {nullptr}
private

Definition at line 61 of file TridentWABAnaProcessor.h.

◆ bvtxs_

TBranch* bvtxs_ {nullptr}
private

Definition at line 56 of file TridentWABAnaProcessor.h.

◆ calTimeOffset_

double calTimeOffset_ {-999}
private

Definition at line 103 of file TridentWABAnaProcessor.h.

◆ cluColl_

std::string cluColl_ {"Vertices"}
private

Definition at line 79 of file TridentWABAnaProcessor.h.

◆ clus_

std::vector<CalCluster*>* clus_ {}
private

Definition at line 70 of file TridentWABAnaProcessor.h.

◆ debug_

int debug_ {0}
private

Definition at line 142 of file TridentWABAnaProcessor.h.

◆ evth_

EventHeader* evth_ {nullptr}
private

Definition at line 72 of file TridentWABAnaProcessor.h.

◆ fspart_

std::vector<Particle*>* fspart_ {}
private

Definition at line 68 of file TridentWABAnaProcessor.h.

◆ fspartColl_

std::string fspartColl_ {"FinalStateParticles_KF"}
private

Definition at line 82 of file TridentWABAnaProcessor.h.

◆ histoCfg_

std::string histoCfg_ {""}
private

Definition at line 102 of file TridentWABAnaProcessor.h.

◆ hitColl_

std::string hitColl_ {"SiClustersOnTrack"}
private

Definition at line 77 of file TridentWABAnaProcessor.h.

◆ hits_

std::vector<TrackerHit*>* hits_ {}
private

Definition at line 66 of file TridentWABAnaProcessor.h.

◆ isData

int isData {0}
private

Definition at line 107 of file TridentWABAnaProcessor.h.

◆ mcColl_

std::string mcColl_ {"MCParticle"}
private

Definition at line 76 of file TridentWABAnaProcessor.h.

◆ mcParts_

std::vector<MCParticle*>* mcParts_ {}
private

Definition at line 71 of file TridentWABAnaProcessor.h.

◆ rawhitColl_

std::string rawhitColl_ {"TrackRawHits"}
private

Definition at line 78 of file TridentWABAnaProcessor.h.

◆ rawhits_

std::vector<RawSvtHit*>* rawhits_ {}
private

Definition at line 67 of file TridentWABAnaProcessor.h.

◆ regionSelections_

std::vector<std::string> regionSelections_
private

Definition at line 48 of file TridentWABAnaProcessor.h.

◆ regionWABSelections_

std::vector<std::string> regionWABSelections_
private

Definition at line 49 of file TridentWABAnaProcessor.h.

◆ selectionCfg_

std::string selectionCfg_
private

Definition at line 51 of file TridentWABAnaProcessor.h.

◆ tree_

TTree* tree_ {nullptr}
private

Definition at line 84 of file TridentWABAnaProcessor.h.

◆ trkColl_

std::string trkColl_ {"GBLTracks"}
private

Definition at line 83 of file TridentWABAnaProcessor.h.

◆ trks_

std::vector<Track*>* trks_ {}
private

Definition at line 69 of file TridentWABAnaProcessor.h.

◆ trkSelCfg_

std::string trkSelCfg_
private

Definition at line 52 of file TridentWABAnaProcessor.h.

◆ trkSelector

std::shared_ptr<BaseSelector> trkSelector
private

Definition at line 47 of file TridentWABAnaProcessor.h.

◆ trkTimeOffset_

double trkTimeOffset_ {-999}
private

Definition at line 104 of file TridentWABAnaProcessor.h.

◆ tsdata_

TSData* tsdata_ {nullptr}
private

Definition at line 73 of file TridentWABAnaProcessor.h.

◆ tsdataColl_

std::string tsdataColl_ {"TSData"}
private

Definition at line 81 of file TridentWABAnaProcessor.h.

◆ vtxColl_

std::string vtxColl_ {"Vertices"}
private

Definition at line 80 of file TridentWABAnaProcessor.h.

◆ vtxs_

std::vector<Vertex*>* vtxs_ {}
private

Definition at line 65 of file TridentWABAnaProcessor.h.

◆ vtxSelector

std::shared_ptr<BaseSelector> vtxSelector
private

Definition at line 46 of file TridentWABAnaProcessor.h.


The documentation for this class was generated from the following files: