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

Flat encoding of SRCVNResult. More...

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

Public Member Functions

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

Protected Attributes

float numuid
 
float nueid
 
float nutauid
 
float ncid
 
float cosmicid
 
float maxval
 
unsigned int argmax
 
unsigned int noutput
 
TTree * output_tree
 
float output
 
long output_idx
 
int output_length
 

Detailed Description

Flat encoding of SRCVNResult.

Definition at line 20 of file FlatCVNResult.h.

Constructor & Destructor Documentation

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

Definition at line 4078 of file FlatRecord.cxx.

References argmax, compare_h5_caf::branch, cosmicid, maxval, noutput, nueid, numuid, nutauid, output, output_idx, output_length, and output_tree.

4079  : output_tree(make_tree(prefix+"output", "output", tr)),
4080  output(0),
4081  output_idx(0), output_length(0)
4082 {
4083  branch(tr, prefix+"numuid", &numuid, policy);
4084  branch(tr, prefix+"nueid", &nueid, policy);
4085  branch(tr, prefix+"nutauid", &nutauid, policy);
4086  branch(tr, prefix+"ncid", &ncid, policy);
4087  branch(tr, prefix+"cosmicid", &cosmicid, policy);
4088  branch(tr, prefix+"maxval", &maxval, policy);
4089  branch(tr, prefix+"argmax", &argmax, policy);
4090  branch(tr, prefix+"noutput", &noutput, policy);
4091  branch(output_tree, prefix+"output", &output, policy);
4092  if(output_tree->GetNbranches() > 0){
4093  branch(tr, prefix+"output_idx", &output_idx, 0);
4094  branch(tr, prefix+"output_length", &output_length, 0);
4095  }
4096 }
Definition: FillPIDs.h:18
unsigned int noutput
Definition: FlatCVNResult.h:36
const XML_Char * prefix
Definition: expat.h:380
unsigned int argmax
Definition: FlatCVNResult.h:35
flat::FlatCVNResult::~FlatCVNResult ( )

Definition at line 4098 of file FlatRecord.cxx.

References output_tree.

4099 {
4100  if(output_tree->GetNbranches() > 0) output_tree->Write();
4101  delete output_tree;
4102 }

Member Function Documentation

void flat::FlatCVNResult::Fill ( const caf::SRCVNResult sr)

Definition at line 4104 of file FlatRecord.cxx.

References caf::SRCVNResult::argmax, argmax, caf::SRCVNResult::cosmicid, cosmicid, caf::SRCVNResult::maxval, maxval, caf::SRCVNResult::ncid, caf::SRCVNResult::noutput, noutput, caf::SRCVNResult::nueid, nueid, caf::SRCVNResult::numuid, numuid, caf::SRCVNResult::nutauid, nutauid, caf::SRCVNResult::output, output, output_idx, output_length, output_tree, and submit_syst::x.

Referenced by flat::FlatMRProperties::Fill(), and flat::FlatIDBranch::Fill().

4105 {
4106  numuid = sr.numuid;
4107  nueid = sr.nueid;
4108  nutauid = sr.nutauid;
4109  ncid = sr.ncid;
4110  cosmicid = sr.cosmicid;
4111  maxval = sr.maxval;
4112  argmax = sr.argmax;
4113  noutput = sr.noutput;
4114 
4115  output_idx += output_length; // increment taken by previous record
4116  output_length = sr.output.size();
4117  for(const auto& x: sr.output){
4118  output = x;
4119  output_tree->Fill();
4120  }
4121 }
float ncid
Likelihood Neutral Current.
Definition: SRCVNResult.h:23
Definition: FillPIDs.h:18
unsigned int noutput
Definition: FlatCVNResult.h:36
float maxval
Maximum value among net outputs.
Definition: SRCVNResult.h:25
float nutauid
Likelihood Charge Current NuTau.
Definition: SRCVNResult.h:22
float nueid
Likelihood Charge Current NuE.
Definition: SRCVNResult.h:21
unsigned int noutput
Number of entries in output vector.
Definition: SRCVNResult.h:27
float cosmicid
Likelihood Cosmic Interaction.
Definition: SRCVNResult.h:24
std::vector< float > output
List of net output nodes.
Definition: SRCVNResult.h:19
unsigned int argmax
Definition: FlatCVNResult.h:35
float numuid
Likelihood Charge Current NuMu.
Definition: SRCVNResult.h:20
unsigned int argmax
Index of maximum value.
Definition: SRCVNResult.h:26

Member Data Documentation

unsigned int flat::FlatCVNResult::argmax
protected

Definition at line 35 of file FlatCVNResult.h.

Referenced by Fill(), and FlatCVNResult().

float flat::FlatCVNResult::cosmicid
protected

Definition at line 33 of file FlatCVNResult.h.

Referenced by Fill(), and FlatCVNResult().

float flat::FlatCVNResult::maxval
protected

Definition at line 34 of file FlatCVNResult.h.

Referenced by Fill(), and FlatCVNResult().

float flat::FlatCVNResult::ncid
protected

Definition at line 32 of file FlatCVNResult.h.

unsigned int flat::FlatCVNResult::noutput
protected

Definition at line 36 of file FlatCVNResult.h.

Referenced by Fill(), and FlatCVNResult().

float flat::FlatCVNResult::nueid
protected

Definition at line 30 of file FlatCVNResult.h.

Referenced by Fill(), and FlatCVNResult().

float flat::FlatCVNResult::numuid
protected

Definition at line 29 of file FlatCVNResult.h.

Referenced by Fill(), and FlatCVNResult().

float flat::FlatCVNResult::nutauid
protected

Definition at line 31 of file FlatCVNResult.h.

Referenced by Fill(), and FlatCVNResult().

float flat::FlatCVNResult::output
protected

Definition at line 39 of file FlatCVNResult.h.

Referenced by Fill(), and FlatCVNResult().

long flat::FlatCVNResult::output_idx
protected

Definition at line 40 of file FlatCVNResult.h.

Referenced by Fill(), and FlatCVNResult().

int flat::FlatCVNResult::output_length
protected

Definition at line 41 of file FlatCVNResult.h.

Referenced by Fill(), and FlatCVNResult().

TTree* flat::FlatCVNResult::output_tree
protected

Definition at line 38 of file FlatCVNResult.h.

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


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