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

Flat encoding of SRVertexBranch. More...

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

Public Member Functions

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

Protected Attributes

size_t nhough
 
size_t nvdt
 
FlatElastic elastic
 
TTree * hough_tree
 
FlatHoughVertex hough
 
long hough_idx
 
int hough_length
 
TTree * vdt_tree
 
FlatVertexDT vdt
 
long vdt_idx
 
int vdt_length
 

Detailed Description

Flat encoding of SRVertexBranch.

Definition at line 23 of file FlatVertexBranch.h.

Constructor & Destructor Documentation

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

Definition at line 2940 of file FlatRecord.cxx.

References compare_h5_caf::branch, hough_idx, hough_length, hough_tree, nhough, nvdt, vdt_idx, vdt_length, and vdt_tree.

2941  : elastic(prefix+"elastic.", tr, policy),
2942  hough_tree(make_tree(prefix+"hough", "hough", tr)),
2943  hough((prefix+"hough."), hough_tree, policy),
2944  hough_idx(0), hough_length(0),
2945  vdt_tree(make_tree(prefix+"vdt", "vdt", tr)),
2946  vdt((prefix+"vdt."), vdt_tree, policy),
2947  vdt_idx(0), vdt_length(0)
2948 {
2949  branch(tr, prefix+"nhough", &nhough, policy);
2950  branch(tr, prefix+"nvdt", &nvdt, policy);
2951  if(hough_tree->GetNbranches() > 0){
2952  branch(tr, prefix+"hough_idx", &hough_idx, 0);
2953  branch(tr, prefix+"hough_length", &hough_length, 0);
2954  }
2955  if(vdt_tree->GetNbranches() > 0){
2956  branch(tr, prefix+"vdt_idx", &vdt_idx, 0);
2957  branch(tr, prefix+"vdt_length", &vdt_length, 0);
2958  }
2959 }
const XML_Char * prefix
Definition: expat.h:380
flat::FlatVertexBranch::~FlatVertexBranch ( )

Definition at line 2961 of file FlatRecord.cxx.

References hough_tree, and vdt_tree.

2962 {
2963  if(hough_tree->GetNbranches() > 0) hough_tree->Write();
2964  delete hough_tree;
2965  if(vdt_tree->GetNbranches() > 0) vdt_tree->Write();
2966  delete vdt_tree;
2967 }

Member Function Documentation

void flat::FlatVertexBranch::Fill ( const caf::SRVertexBranch sr)

Definition at line 2969 of file FlatRecord.cxx.

References caf::SRVertexBranch::elastic, elastic, flat::FlatElastic::Fill(), caf::SRVertexBranch::hough, hough_idx, hough_length, hough_tree, caf::SRVertexBranch::nhough, nhough, caf::SRVertexBranch::nvdt, nvdt, caf::SRVertexBranch::vdt, vdt_idx, vdt_length, vdt_tree, and submit_syst::x.

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

2970 {
2971  nhough = sr.nhough;
2972  nvdt = sr.nvdt;
2973 
2974  elastic.Fill(sr.elastic);
2975 
2976  hough_idx += hough_length; // increment taken by previous record
2977  hough_length = sr.hough.size();
2978  for(const auto& x: sr.hough){
2979  hough.Fill(x);
2980  hough_tree->Fill();
2981  }
2982 
2983  vdt_idx += vdt_length; // increment taken by previous record
2984  vdt_length = sr.vdt.size();
2985  for(const auto& x: sr.vdt){
2986  vdt.Fill(x);
2987  vdt_tree->Fill();
2988  }
2989 }
Perform a "2 point" Hough transform on a collection of hits.
Definition: Hough2P.cxx:20
void Fill(const caf::SRElastic &sr)
std::vector< SRVertexDT > vdt
Vector of vertices found by VertexDT.
std::vector< SRHoughVertex > hough
Vector of vertices found by HoughVertex.
size_t nhough
Number of vertices in HoughVertex (hough.size())
SRElastic elastic
Single vertex found by Elastic Arms.
VertexDT finding algorithm.
size_t nvdt
Number of vertices in VertexDT (vdt.size())

Member Data Documentation

FlatElastic flat::FlatVertexBranch::elastic
protected

Definition at line 35 of file FlatVertexBranch.h.

Referenced by Fill().

FlatHoughVertex flat::FlatVertexBranch::hough
protected

Definition at line 38 of file FlatVertexBranch.h.

long flat::FlatVertexBranch::hough_idx
protected

Definition at line 39 of file FlatVertexBranch.h.

Referenced by Fill(), and FlatVertexBranch().

int flat::FlatVertexBranch::hough_length
protected

Definition at line 40 of file FlatVertexBranch.h.

Referenced by Fill(), and FlatVertexBranch().

TTree* flat::FlatVertexBranch::hough_tree
protected

Definition at line 37 of file FlatVertexBranch.h.

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

size_t flat::FlatVertexBranch::nhough
protected

Definition at line 32 of file FlatVertexBranch.h.

Referenced by Fill(), and FlatVertexBranch().

size_t flat::FlatVertexBranch::nvdt
protected

Definition at line 33 of file FlatVertexBranch.h.

Referenced by Fill(), and FlatVertexBranch().

FlatVertexDT flat::FlatVertexBranch::vdt
protected

Definition at line 43 of file FlatVertexBranch.h.

long flat::FlatVertexBranch::vdt_idx
protected

Definition at line 44 of file FlatVertexBranch.h.

Referenced by Fill(), and FlatVertexBranch().

int flat::FlatVertexBranch::vdt_length
protected

Definition at line 45 of file FlatVertexBranch.h.

Referenced by Fill(), and FlatVertexBranch().

TTree* flat::FlatVertexBranch::vdt_tree
protected

Definition at line 42 of file FlatVertexBranch.h.

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


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