Public Member Functions | Protected Attributes | List of all members
flat::FlatMichelE Class Reference

Flat encoding of SRMichelE. More...

#include "/cvmfs/nova-development.opensciencegrid.org/novasoft/releases/N20-11-28/FlatMaker/FlatMichelE.h"

Public Member Functions

 FlatMichelE (const std::string &prefix, TTree *tr, const IBranchPolicy *policy)
 
 ~FlatMichelE ()
 
void Fill (const caf::SRMichelE &sr)
 

Protected Attributes

size_t nkalman
 
size_t ndiscrete
 
size_t ncosmic
 
size_t nbpf
 
size_t nslc
 
TTree * trkkalman_tree
 
FlatTrkME trkkalman
 
long trkkalman_idx
 
int trkkalman_length
 
TTree * trkdiscrete_tree
 
FlatTrkME trkdiscrete
 
long trkdiscrete_idx
 
int trkdiscrete_length
 
TTree * trkcosmic_tree
 
FlatTrkME trkcosmic
 
long trkcosmic_idx
 
int trkcosmic_length
 
TTree * trkbpf_tree
 
FlatTrkME trkbpf
 
long trkbpf_idx
 
int trkbpf_length
 
TTree * slc_tree
 
FlatSlcME slc
 
long slc_idx
 
int slc_length
 

Detailed Description

Flat encoding of SRMichelE.

Definition at line 22 of file FlatMichelE.h.

Constructor & Destructor Documentation

flat::FlatMichelE::FlatMichelE ( const std::string prefix,
TTree *  tr,
const IBranchPolicy policy 
)

Definition at line 2803 of file FlatRecord.cxx.

References compare_h5_caf::branch, nbpf, ncosmic, ndiscrete, nkalman, nslc, slc_idx, slc_length, slc_tree, trkbpf_idx, trkbpf_length, trkbpf_tree, trkcosmic_idx, trkcosmic_length, trkcosmic_tree, trkdiscrete_idx, trkdiscrete_length, trkdiscrete_tree, trkkalman_idx, trkkalman_length, and trkkalman_tree.

2804  : trkkalman_tree(make_tree(prefix+"trkkalman", "trkkalman", tr)),
2805  trkkalman((prefix+"trkkalman."), trkkalman_tree, policy),
2807  trkdiscrete_tree(make_tree(prefix+"trkdiscrete", "trkdiscrete", tr)),
2808  trkdiscrete((prefix+"trkdiscrete."), trkdiscrete_tree, policy),
2810  trkcosmic_tree(make_tree(prefix+"trkcosmic", "trkcosmic", tr)),
2811  trkcosmic((prefix+"trkcosmic."), trkcosmic_tree, policy),
2813  trkbpf_tree(make_tree(prefix+"trkbpf", "trkbpf", tr)),
2814  trkbpf((prefix+"trkbpf."), trkbpf_tree, policy),
2815  trkbpf_idx(0), trkbpf_length(0),
2816  slc_tree(make_tree(prefix+"slc", "slc", tr)),
2817  slc((prefix+"slc."), slc_tree, policy),
2818  slc_idx(0), slc_length(0)
2819 {
2820  branch(tr, prefix+"nkalman", &nkalman, policy);
2821  branch(tr, prefix+"ndiscrete", &ndiscrete, policy);
2822  branch(tr, prefix+"ncosmic", &ncosmic, policy);
2823  branch(tr, prefix+"nbpf", &nbpf, policy);
2824  branch(tr, prefix+"nslc", &nslc, policy);
2825  if(trkkalman_tree->GetNbranches() > 0){
2826  branch(tr, prefix+"trkkalman_idx", &trkkalman_idx, 0);
2827  branch(tr, prefix+"trkkalman_length", &trkkalman_length, 0);
2828  }
2829  if(trkdiscrete_tree->GetNbranches() > 0){
2830  branch(tr, prefix+"trkdiscrete_idx", &trkdiscrete_idx, 0);
2831  branch(tr, prefix+"trkdiscrete_length", &trkdiscrete_length, 0);
2832  }
2833  if(trkcosmic_tree->GetNbranches() > 0){
2834  branch(tr, prefix+"trkcosmic_idx", &trkcosmic_idx, 0);
2835  branch(tr, prefix+"trkcosmic_length", &trkcosmic_length, 0);
2836  }
2837  if(trkbpf_tree->GetNbranches() > 0){
2838  branch(tr, prefix+"trkbpf_idx", &trkbpf_idx, 0);
2839  branch(tr, prefix+"trkbpf_length", &trkbpf_length, 0);
2840  }
2841  if(slc_tree->GetNbranches() > 0){
2842  branch(tr, prefix+"slc_idx", &slc_idx, 0);
2843  branch(tr, prefix+"slc_length", &slc_length, 0);
2844  }
2845 }
FlatTrkME trkcosmic
Definition: FlatMichelE.h:48
TTree * trkbpf_tree
Definition: FlatMichelE.h:52
FlatTrkME trkbpf
Definition: FlatMichelE.h:53
FlatTrkME trkdiscrete
Definition: FlatMichelE.h:43
const XML_Char * prefix
Definition: expat.h:380
TTree * trkcosmic_tree
Definition: FlatMichelE.h:47
TTree * trkdiscrete_tree
Definition: FlatMichelE.h:42
TTree * trkkalman_tree
Definition: FlatMichelE.h:37
FlatTrkME trkkalman
Definition: FlatMichelE.h:38
flat::FlatMichelE::~FlatMichelE ( )

Definition at line 2847 of file FlatRecord.cxx.

References slc_tree, trkbpf_tree, trkcosmic_tree, trkdiscrete_tree, and trkkalman_tree.

2848 {
2849  if(trkkalman_tree->GetNbranches() > 0) trkkalman_tree->Write();
2850  delete trkkalman_tree;
2851  if(trkdiscrete_tree->GetNbranches() > 0) trkdiscrete_tree->Write();
2852  delete trkdiscrete_tree;
2853  if(trkcosmic_tree->GetNbranches() > 0) trkcosmic_tree->Write();
2854  delete trkcosmic_tree;
2855  if(trkbpf_tree->GetNbranches() > 0) trkbpf_tree->Write();
2856  delete trkbpf_tree;
2857  if(slc_tree->GetNbranches() > 0) slc_tree->Write();
2858  delete slc_tree;
2859 }
TTree * trkbpf_tree
Definition: FlatMichelE.h:52
TTree * trkcosmic_tree
Definition: FlatMichelE.h:47
TTree * trkdiscrete_tree
Definition: FlatMichelE.h:42
TTree * trkkalman_tree
Definition: FlatMichelE.h:37

Member Function Documentation

void flat::FlatMichelE::Fill ( const caf::SRMichelE sr)

Definition at line 2861 of file FlatRecord.cxx.

References flat::FlatTrkME::Fill(), flat::FlatSlcME::Fill(), caf::SRMichelE::nbpf, nbpf, caf::SRMichelE::ncosmic, ncosmic, caf::SRMichelE::ndiscrete, ndiscrete, caf::SRMichelE::nkalman, nkalman, caf::SRMichelE::nslc, nslc, caf::SRMichelE::slc, slc, slc_idx, slc_length, slc_tree, caf::SRMichelE::trkbpf, trkbpf, trkbpf_idx, trkbpf_length, trkbpf_tree, caf::SRMichelE::trkcosmic, trkcosmic, trkcosmic_idx, trkcosmic_length, trkcosmic_tree, caf::SRMichelE::trkdiscrete, trkdiscrete, trkdiscrete_idx, trkdiscrete_length, trkdiscrete_tree, caf::SRMichelE::trkkalman, trkkalman, trkkalman_idx, trkkalman_length, trkkalman_tree, and submit_syst::x.

2862 {
2863  nkalman = sr.nkalman;
2864  ndiscrete = sr.ndiscrete;
2865  ncosmic = sr.ncosmic;
2866  nbpf = sr.nbpf;
2867  nslc = sr.nslc;
2868 
2869  trkkalman_idx += trkkalman_length; // increment taken by previous record
2870  trkkalman_length = sr.trkkalman.size();
2871  for(const auto& x: sr.trkkalman){
2872  trkkalman.Fill(x);
2873  trkkalman_tree->Fill();
2874  }
2875 
2876  trkdiscrete_idx += trkdiscrete_length; // increment taken by previous record
2877  trkdiscrete_length = sr.trkdiscrete.size();
2878  for(const auto& x: sr.trkdiscrete){
2879  trkdiscrete.Fill(x);
2880  trkdiscrete_tree->Fill();
2881  }
2882 
2883  trkcosmic_idx += trkcosmic_length; // increment taken by previous record
2884  trkcosmic_length = sr.trkcosmic.size();
2885  for(const auto& x: sr.trkcosmic){
2886  trkcosmic.Fill(x);
2887  trkcosmic_tree->Fill();
2888  }
2889 
2890  trkbpf_idx += trkbpf_length; // increment taken by previous record
2891  trkbpf_length = sr.trkbpf.size();
2892  for(const auto& x: sr.trkbpf){
2893  trkbpf.Fill(x);
2894  trkbpf_tree->Fill();
2895  }
2896 
2897  slc_idx += slc_length; // increment taken by previous record
2898  slc_length = sr.slc.size();
2899  for(const auto& x: sr.slc){
2900  slc.Fill(x);
2901  slc_tree->Fill();
2902  }
2903 }
FlatTrkME trkcosmic
Definition: FlatMichelE.h:48
TTree * trkbpf_tree
Definition: FlatMichelE.h:52
std::vector< SRTrkME > trkcosmic
Definition: SRMichelE.h:24
size_t nkalman
Definition: SRMichelE.h:28
std::vector< SRTrkME > trkkalman
Definition: SRMichelE.h:22
size_t nbpf
Definition: SRMichelE.h:31
FlatTrkME trkbpf
Definition: FlatMichelE.h:53
FlatTrkME trkdiscrete
Definition: FlatMichelE.h:43
size_t ndiscrete
Definition: SRMichelE.h:29
std::vector< SRTrkME > trkbpf
Definition: SRMichelE.h:25
std::vector< SRTrkME > trkdiscrete
Definition: SRMichelE.h:23
std::vector< SRSlcME > slc
Definition: SRMichelE.h:26
size_t ncosmic
Definition: SRMichelE.h:30
TTree * trkcosmic_tree
Definition: FlatMichelE.h:47
TTree * trkdiscrete_tree
Definition: FlatMichelE.h:42
TTree * trkkalman_tree
Definition: FlatMichelE.h:37
FlatTrkME trkkalman
Definition: FlatMichelE.h:38
void Fill(const caf::SRSlcME &sr)
void Fill(const caf::SRTrkME &sr)
size_t nslc
Definition: SRMichelE.h:32

Member Data Documentation

size_t flat::FlatMichelE::nbpf
protected

Definition at line 34 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

size_t flat::FlatMichelE::ncosmic
protected

Definition at line 33 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

size_t flat::FlatMichelE::ndiscrete
protected

Definition at line 32 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

size_t flat::FlatMichelE::nkalman
protected

Definition at line 31 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

size_t flat::FlatMichelE::nslc
protected

Definition at line 35 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

FlatSlcME flat::FlatMichelE::slc
protected

Definition at line 58 of file FlatMichelE.h.

Referenced by Fill().

long flat::FlatMichelE::slc_idx
protected

Definition at line 59 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

int flat::FlatMichelE::slc_length
protected

Definition at line 60 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

TTree* flat::FlatMichelE::slc_tree
protected

Definition at line 57 of file FlatMichelE.h.

Referenced by Fill(), FlatMichelE(), and ~FlatMichelE().

FlatTrkME flat::FlatMichelE::trkbpf
protected

Definition at line 53 of file FlatMichelE.h.

Referenced by Fill().

long flat::FlatMichelE::trkbpf_idx
protected

Definition at line 54 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

int flat::FlatMichelE::trkbpf_length
protected

Definition at line 55 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

TTree* flat::FlatMichelE::trkbpf_tree
protected

Definition at line 52 of file FlatMichelE.h.

Referenced by Fill(), FlatMichelE(), and ~FlatMichelE().

FlatTrkME flat::FlatMichelE::trkcosmic
protected

Definition at line 48 of file FlatMichelE.h.

Referenced by Fill().

long flat::FlatMichelE::trkcosmic_idx
protected

Definition at line 49 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

int flat::FlatMichelE::trkcosmic_length
protected

Definition at line 50 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

TTree* flat::FlatMichelE::trkcosmic_tree
protected

Definition at line 47 of file FlatMichelE.h.

Referenced by Fill(), FlatMichelE(), and ~FlatMichelE().

FlatTrkME flat::FlatMichelE::trkdiscrete
protected

Definition at line 43 of file FlatMichelE.h.

Referenced by Fill().

long flat::FlatMichelE::trkdiscrete_idx
protected

Definition at line 44 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

int flat::FlatMichelE::trkdiscrete_length
protected

Definition at line 45 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

TTree* flat::FlatMichelE::trkdiscrete_tree
protected

Definition at line 42 of file FlatMichelE.h.

Referenced by Fill(), FlatMichelE(), and ~FlatMichelE().

FlatTrkME flat::FlatMichelE::trkkalman
protected

Definition at line 38 of file FlatMichelE.h.

Referenced by Fill().

long flat::FlatMichelE::trkkalman_idx
protected

Definition at line 39 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

int flat::FlatMichelE::trkkalman_length
protected

Definition at line 40 of file FlatMichelE.h.

Referenced by Fill(), and FlatMichelE().

TTree* flat::FlatMichelE::trkkalman_tree
protected

Definition at line 37 of file FlatMichelE.h.

Referenced by Fill(), FlatMichelE(), and ~FlatMichelE().


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