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

Flat encoding of SRProng. More...

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

Public Member Functions

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

Protected Attributes

short unsigned int nhit
 
short unsigned int nhitx
 
short unsigned int nhity
 
short unsigned int nplane
 
short unsigned int maxplanecont
 
short unsigned int maxplanegap
 
float calE
 
float weightedCalE
 
float pngminx
 
float pngmaxx
 
float pngminy
 
float pngmaxy
 
float len
 
short unsigned int view
 
float meantime
 
float maxtime
 
float mintime
 
float meantimeRes
 
FlatVector3D start
 
FlatVector3D dir
 
FlatParticleTruth truth
 
FlatParticleTruth truthXView
 
FlatParticleTruth truthYView
 
FlatCVNNeutronDaughterResult cvnneutron
 
FlatCVNParticleResult cvnpart
 
FlatCVNParticleResult cvnpart_opphorn
 
FlatCVNParticleResult spprongcvnpart5label
 
FlatCVNParticleResult spprongcvnpartnumuccemid
 
TTree * cvnmaps_tree
 
FlatPixelMap cvnmaps
 
long cvnmaps_idx
 
int cvnmaps_length
 
TTree * prongtrainingdata_tree
 
FlatProngTrainingData prongtrainingdata
 
long prongtrainingdata_idx
 
int prongtrainingdata_length
 

Detailed Description

Flat encoding of SRProng.

Definition at line 26 of file FlatProng.h.

Constructor & Destructor Documentation

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

Definition at line 4456 of file FlatRecord.cxx.

References compare_h5_caf::branch, calE, cvnmaps_idx, cvnmaps_length, cvnmaps_tree, maxplanecont, maxplanegap, maxtime, meantime, meantimeRes, mintime, nhit, nhitx, nhity, nplane, pngmaxx, pngmaxy, pngminx, pngminy, prongtrainingdata_idx, prongtrainingdata_length, prongtrainingdata_tree, view, and weightedCalE.

4457  : start(prefix+"start.", tr, policy),
4458  dir(prefix+"dir.", tr, policy),
4459  truth(prefix+"truth.", tr, policy),
4460  truthXView(prefix+"truthXView.", tr, policy),
4461  truthYView(prefix+"truthYView.", tr, policy),
4462  cvnneutron(prefix+"cvnneutron.", tr, policy),
4463  cvnpart(prefix+"cvnpart.", tr, policy),
4464  cvnpart_opphorn(prefix+"cvnpart_opphorn.", tr, policy),
4465  spprongcvnpart5label(prefix+"spprongcvnpart5label.", tr, policy),
4466  spprongcvnpartnumuccemid(prefix+"spprongcvnpartnumuccemid.", tr, policy),
4467  cvnmaps_tree(make_tree(prefix+"cvnmaps", "cvnmaps", tr)),
4468  cvnmaps((prefix+"cvnmaps."), cvnmaps_tree, policy),
4469  cvnmaps_idx(0), cvnmaps_length(0),
4470  prongtrainingdata_tree(make_tree(prefix+"prongtrainingdata", "prongtrainingdata", tr)),
4471  prongtrainingdata((prefix+"prongtrainingdata."), prongtrainingdata_tree, policy),
4473 {
4474  branch(tr, prefix+"nhit", &nhit, policy);
4475  branch(tr, prefix+"nhitx", &nhitx, policy);
4476  branch(tr, prefix+"nhity", &nhity, policy);
4477  branch(tr, prefix+"nplane", &nplane, policy);
4478  branch(tr, prefix+"maxplanecont", &maxplanecont, policy);
4479  branch(tr, prefix+"maxplanegap", &maxplanegap, policy);
4480  branch(tr, prefix+"calE", &calE, policy);
4481  branch(tr, prefix+"weightedCalE", &weightedCalE, policy);
4482  branch(tr, prefix+"pngminx", &pngminx, policy);
4483  branch(tr, prefix+"pngmaxx", &pngmaxx, policy);
4484  branch(tr, prefix+"pngminy", &pngminy, policy);
4485  branch(tr, prefix+"pngmaxy", &pngmaxy, policy);
4486  branch(tr, prefix+"len", &len, policy);
4487  branch(tr, prefix+"view", &view, policy);
4488  branch(tr, prefix+"meantime", &meantime, policy);
4489  branch(tr, prefix+"maxtime", &maxtime, policy);
4490  branch(tr, prefix+"mintime", &mintime, policy);
4491  branch(tr, prefix+"meantimeRes", &meantimeRes, policy);
4492  if(cvnmaps_tree->GetNbranches() > 0){
4493  branch(tr, prefix+"cvnmaps_idx", &cvnmaps_idx, 0);
4494  branch(tr, prefix+"cvnmaps_length", &cvnmaps_length, 0);
4495  }
4496  if(prongtrainingdata_tree->GetNbranches() > 0){
4497  branch(tr, prefix+"prongtrainingdata_idx", &prongtrainingdata_idx, 0);
4498  branch(tr, prefix+"prongtrainingdata_length", &prongtrainingdata_length, 0);
4499  }
4500 }
const XML_Char int len
Definition: expat.h:262
FlatVector3D dir
Definition: FlatProng.h:55
float weightedCalE
Definition: FlatProng.h:42
short unsigned int nhity
Definition: FlatProng.h:37
TTree * cvnmaps_tree
Definition: FlatProng.h:65
FlatCVNParticleResult cvnpart
Definition: FlatProng.h:60
short unsigned int nhitx
Definition: FlatProng.h:36
TTree * prongtrainingdata_tree
Definition: FlatProng.h:70
float meantimeRes
Definition: FlatProng.h:52
short unsigned int view
Definition: FlatProng.h:48
short unsigned int nplane
Definition: FlatProng.h:38
FlatParticleTruth truthXView
Definition: FlatProng.h:57
FlatParticleTruth truth
Definition: FlatProng.h:56
FlatVector3D start
Definition: FlatProng.h:54
FlatCVNParticleResult spprongcvnpart5label
Definition: FlatProng.h:62
FlatParticleTruth truthYView
Definition: FlatProng.h:58
int cvnmaps_length
Definition: FlatProng.h:68
FlatCVNParticleResult cvnpart_opphorn
Definition: FlatProng.h:61
FlatPixelMap cvnmaps
Definition: FlatProng.h:66
FlatCVNParticleResult spprongcvnpartnumuccemid
Definition: FlatProng.h:63
int prongtrainingdata_length
Definition: FlatProng.h:73
FlatProngTrainingData prongtrainingdata
Definition: FlatProng.h:71
const XML_Char * prefix
Definition: expat.h:380
float meantime
Definition: FlatProng.h:49
short unsigned int maxplanegap
Definition: FlatProng.h:40
FlatCVNNeutronDaughterResult cvnneutron
Definition: FlatProng.h:59
short unsigned int maxplanecont
Definition: FlatProng.h:39
short unsigned int nhit
Definition: FlatProng.h:35
long prongtrainingdata_idx
Definition: FlatProng.h:72
long cvnmaps_idx
Definition: FlatProng.h:67
flat::FlatProng::~FlatProng ( )

Definition at line 4502 of file FlatRecord.cxx.

References cvnmaps_tree, and prongtrainingdata_tree.

4503 {
4504  if(cvnmaps_tree->GetNbranches() > 0) cvnmaps_tree->Write();
4505  delete cvnmaps_tree;
4506  if(prongtrainingdata_tree->GetNbranches() > 0) prongtrainingdata_tree->Write();
4507  delete prongtrainingdata_tree;
4508 }
TTree * cvnmaps_tree
Definition: FlatProng.h:65
TTree * prongtrainingdata_tree
Definition: FlatProng.h:70

Member Function Documentation

void flat::FlatProng::Fill ( const caf::SRProng sr)

Definition at line 4510 of file FlatRecord.cxx.

References caf::SRProng::calE, calE, caf::SRProng::cvnmaps, cvnmaps, cvnmaps_idx, cvnmaps_length, cvnmaps_tree, caf::SRProng::cvnneutron, cvnneutron, caf::SRProng::cvnpart, cvnpart, caf::SRProng::cvnpart_opphorn, cvnpart_opphorn, caf::SRProng::dir, dir, flat::FlatVector3D::Fill(), flat::FlatPixelMap::Fill(), flat::FlatProngTrainingData::Fill(), flat::FlatCVNNeutronDaughterResult::Fill(), flat::FlatCVNParticleResult::Fill(), flat::FlatParticleTruth::Fill(), caf::SRProng::len, caf::SRProng::maxplanecont, maxplanecont, caf::SRProng::maxplanegap, maxplanegap, maxtime, caf::SRProng::maxtime, meantime, caf::SRProng::meantime, meantimeRes, caf::SRProng::meantimeRes, mintime, caf::SRProng::mintime, caf::SRProng::nhit, nhit, caf::SRProng::nhitx, nhitx, caf::SRProng::nhity, nhity, caf::SRProng::nplane, nplane, caf::SRProng::pngmaxx, pngmaxx, caf::SRProng::pngmaxy, pngmaxy, caf::SRProng::pngminx, pngminx, caf::SRProng::pngminy, pngminy, caf::SRProng::prongtrainingdata, prongtrainingdata, prongtrainingdata_idx, prongtrainingdata_length, prongtrainingdata_tree, caf::SRProng::spprongcvnpart5label, spprongcvnpart5label, caf::SRProng::spprongcvnpartnumuccemid, spprongcvnpartnumuccemid, caf::SRProng::start, start, caf::SRProng::truth, truth, caf::SRProng::truthXView, truthXView, caf::SRProng::truthYView, truthYView, caf::SRProng::view, view, caf::SRProng::weightedCalE, weightedCalE, and submit_syst::x.

Referenced by flat::FlatFuzzyK::Fill().

4511 {
4512  nhit = sr.nhit;
4513  nhitx = sr.nhitx;
4514  nhity = sr.nhity;
4515  nplane = sr.nplane;
4517  maxplanegap = sr.maxplanegap;
4518  calE = sr.calE;
4520  pngminx = sr.pngminx;
4521  pngmaxx = sr.pngmaxx;
4522  pngminy = sr.pngminy;
4523  pngmaxy = sr.pngmaxy;
4524  len = sr.len;
4525  view = sr.view;
4526  meantime = sr.meantime;
4527  maxtime = sr.maxtime;
4528  mintime = sr.mintime;
4529  meantimeRes = sr.meantimeRes;
4530 
4531  start.Fill(sr.start);
4532  dir.Fill(sr.dir);
4533  truth.Fill(sr.truth);
4537  cvnpart.Fill(sr.cvnpart);
4541 
4542  cvnmaps_idx += cvnmaps_length; // increment taken by previous record
4543  cvnmaps_length = sr.cvnmaps.size();
4544  for(const auto& x: sr.cvnmaps){
4545  cvnmaps.Fill(x);
4546  cvnmaps_tree->Fill();
4547  }
4548 
4549  prongtrainingdata_idx += prongtrainingdata_length; // increment taken by previous record
4551  for(const auto& x: sr.prongtrainingdata){
4553  prongtrainingdata_tree->Fill();
4554  }
4555 }
const XML_Char int len
Definition: expat.h:262
FlatVector3D dir
Definition: FlatProng.h:55
unsigned short nhity
number of hits in y-view
Definition: SRProng.h:32
float pngmaxx
Maximum X that contain all the cell hits. [cm].
Definition: SRProng.h:41
float weightedCalE
Definition: FlatProng.h:42
SRParticleTruth truthXView
Truth information for the prong.
Definition: SRProng.h:47
short unsigned int nhity
Definition: FlatProng.h:37
TTree * cvnmaps_tree
Definition: FlatProng.h:65
float weightedCalE
calE, weighted to take into account hits shared between prongs [GeV]
Definition: SRProng.h:37
FlatCVNParticleResult cvnpart
Definition: FlatProng.h:60
SRCVNParticleResult cvnpart_opphorn
cvnpart trained with opposite horn current
Definition: SRProng.h:51
short unsigned int nhitx
Definition: FlatProng.h:36
void Fill(const caf::SRVector3D &sr)
float len
track length [cm]
Definition: SRProng.h:44
float pngminy
Minimum Y that contain all the cell hits. [cm].
Definition: SRProng.h:42
TTree * prongtrainingdata_tree
Definition: FlatProng.h:70
SRVector3D start
Shower start point in detector coordinates. [cm].
Definition: SRProng.h:38
float meantimeRes
Definition: FlatProng.h:52
float mintime
Min time of cell(s) hits.
Definition: SRProng.h:60
void Fill(const caf::SRCVNNeutronDaughterResult &sr)
short unsigned int view
Definition: FlatProng.h:48
short unsigned int nplane
Definition: FlatProng.h:38
FlatParticleTruth truthXView
Definition: FlatProng.h:57
FlatParticleTruth truth
Definition: FlatProng.h:56
FlatVector3D start
Definition: FlatProng.h:54
unsigned short nhitx
number of hits in x-view
Definition: SRProng.h:31
void Fill(const caf::SRPixelMap &sr)
SRCVNParticleResult cvnpart
CVN prongID information for 4 views.
Definition: SRProng.h:50
FlatCVNParticleResult spprongcvnpart5label
Definition: FlatProng.h:62
void Fill(const caf::SRParticleTruth &sr)
FlatParticleTruth truthYView
Definition: FlatProng.h:58
int cvnmaps_length
Definition: FlatProng.h:68
SRCVNParticleResult spprongcvnpart5label
Single particle-trained prong CVN, Electron/Photon/Proton/Pion/Muon.
Definition: SRProng.h:52
FlatCVNParticleResult cvnpart_opphorn
Definition: FlatProng.h:61
View_t view
Prong view caf::kX = 0, caf::kY = 1 or caf::kXorY = 2.
Definition: SRProng.h:45
float meantime
Average time of cell(s) hits weighted by their energy.
Definition: SRProng.h:58
float pngminx
Minimum X that contain all the cell hits. [cm].
Definition: SRProng.h:40
void Fill(const caf::SRProngTrainingData &sr)
FlatPixelMap cvnmaps
Definition: FlatProng.h:66
float maxtime
Max time of cell(s) hits.
Definition: SRProng.h:59
FlatCVNParticleResult spprongcvnpartnumuccemid
Definition: FlatProng.h:63
int prongtrainingdata_length
Definition: FlatProng.h:73
std::vector< SRProngTrainingData > prongtrainingdata
Prong label information.
Definition: SRProng.h:56
FlatProngTrainingData prongtrainingdata
Definition: FlatProng.h:71
unsigned short maxplanegap
maximum number of gapped planes in prong
Definition: SRProng.h:35
float meantimeRes
Average time of cell(s) hits weighted by their time resolution.
Definition: SRProng.h:61
SRParticleTruth truth
Truth information for the prong.
Definition: SRProng.h:46
SRCVNNeutronDaughterResult cvnneutron
Neutron Daughter CVN information.
Definition: SRProng.h:49
SRParticleTruth truthYView
Truth information for the prong.
Definition: SRProng.h:48
float pngmaxy
Maximum Y that contain all the cell hits. [cm].
Definition: SRProng.h:43
float meantime
Definition: FlatProng.h:49
unsigned short nplane
number of planes spanned
Definition: SRProng.h:33
unsigned short maxplanecont
maximum number of contiguous planes in prong
Definition: SRProng.h:34
unsigned short nhit
number of hits
Definition: SRProng.h:28
SRVector3D dir
Shower direction at start point [unit vector recommended].
Definition: SRProng.h:39
SRCVNParticleResult spprongcvnpartnumuccemid
Single particle-trained prong CVN for NumuCC (exclude muons in training sample), EMid.
Definition: SRProng.h:53
short unsigned int maxplanegap
Definition: FlatProng.h:40
FlatCVNNeutronDaughterResult cvnneutron
Definition: FlatProng.h:59
std::vector< SRPixelMap > cvnmaps
Pixel maps used in CVN evaluation and training 80 cells x 100 planes in each view.
Definition: SRProng.h:55
short unsigned int maxplanecont
Definition: FlatProng.h:39
void Fill(const caf::SRCVNParticleResult &sr)
short unsigned int nhit
Definition: FlatProng.h:35
long prongtrainingdata_idx
Definition: FlatProng.h:72
long cvnmaps_idx
Definition: FlatProng.h:67
float calE
energy based on summed calibrated deposited charge [GeV]
Definition: SRProng.h:36

Member Data Documentation

float flat::FlatProng::calE
protected

Definition at line 41 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

FlatPixelMap flat::FlatProng::cvnmaps
protected

Definition at line 66 of file FlatProng.h.

Referenced by Fill().

long flat::FlatProng::cvnmaps_idx
protected

Definition at line 67 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

int flat::FlatProng::cvnmaps_length
protected

Definition at line 68 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

TTree* flat::FlatProng::cvnmaps_tree
protected

Definition at line 65 of file FlatProng.h.

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

FlatCVNNeutronDaughterResult flat::FlatProng::cvnneutron
protected

Definition at line 59 of file FlatProng.h.

Referenced by Fill().

FlatCVNParticleResult flat::FlatProng::cvnpart
protected

Definition at line 60 of file FlatProng.h.

Referenced by Fill().

FlatCVNParticleResult flat::FlatProng::cvnpart_opphorn
protected

Definition at line 61 of file FlatProng.h.

Referenced by Fill().

FlatVector3D flat::FlatProng::dir
protected

Definition at line 55 of file FlatProng.h.

Referenced by Fill().

float flat::FlatProng::len
protected

Definition at line 47 of file FlatProng.h.

short unsigned int flat::FlatProng::maxplanecont
protected

Definition at line 39 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

short unsigned int flat::FlatProng::maxplanegap
protected

Definition at line 40 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

float flat::FlatProng::maxtime
protected

Definition at line 50 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

float flat::FlatProng::meantime
protected

Definition at line 49 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

float flat::FlatProng::meantimeRes
protected

Definition at line 52 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

float flat::FlatProng::mintime
protected

Definition at line 51 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

short unsigned int flat::FlatProng::nhit
protected

Definition at line 35 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

short unsigned int flat::FlatProng::nhitx
protected

Definition at line 36 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

short unsigned int flat::FlatProng::nhity
protected

Definition at line 37 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

short unsigned int flat::FlatProng::nplane
protected

Definition at line 38 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

float flat::FlatProng::pngmaxx
protected

Definition at line 44 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

float flat::FlatProng::pngmaxy
protected

Definition at line 46 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

float flat::FlatProng::pngminx
protected

Definition at line 43 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

float flat::FlatProng::pngminy
protected

Definition at line 45 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

FlatProngTrainingData flat::FlatProng::prongtrainingdata
protected

Definition at line 71 of file FlatProng.h.

Referenced by Fill().

long flat::FlatProng::prongtrainingdata_idx
protected

Definition at line 72 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

int flat::FlatProng::prongtrainingdata_length
protected

Definition at line 73 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

TTree* flat::FlatProng::prongtrainingdata_tree
protected

Definition at line 70 of file FlatProng.h.

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

FlatCVNParticleResult flat::FlatProng::spprongcvnpart5label
protected

Definition at line 62 of file FlatProng.h.

Referenced by Fill().

FlatCVNParticleResult flat::FlatProng::spprongcvnpartnumuccemid
protected

Definition at line 63 of file FlatProng.h.

Referenced by Fill().

FlatVector3D flat::FlatProng::start
protected

Definition at line 54 of file FlatProng.h.

Referenced by Fill(), progbar.ProgressBar::Start(), and progbar.ProgressBar::Update().

FlatParticleTruth flat::FlatProng::truth
protected

Definition at line 56 of file FlatProng.h.

Referenced by Fill().

FlatParticleTruth flat::FlatProng::truthXView
protected

Definition at line 57 of file FlatProng.h.

Referenced by Fill().

FlatParticleTruth flat::FlatProng::truthYView
protected

Definition at line 58 of file FlatProng.h.

Referenced by Fill().

short unsigned int flat::FlatProng::view
protected

Definition at line 48 of file FlatProng.h.

Referenced by Fill(), and FlatProng().

float flat::FlatProng::weightedCalE
protected

Definition at line 42 of file FlatProng.h.

Referenced by Fill(), and FlatProng().


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