Public Member Functions | Private Member Functions | Private Attributes | List of all members
pduneana::PDSPAnalyzer Class Reference
Inheritance diagram for pduneana::PDSPAnalyzer:
art::EDAnalyzer art::detail::Analyzer art::detail::LegacyModule art::Observer art::ModuleBase

Public Member Functions

 PDSPAnalyzer (fhicl::ParameterSet const &p)
 
 PDSPAnalyzer (PDSPAnalyzer const &)=delete
 
 PDSPAnalyzer (PDSPAnalyzer &&)=delete
 
PDSPAnalyzeroperator= (PDSPAnalyzer const &)=delete
 
PDSPAnalyzeroperator= (PDSPAnalyzer &&)=delete
 
void analyze (art::Event const &evt) override
 
void beginJob () override
 
void endJob () override
 
void reset ()
 
double lateralDist (TVector3 &n, TVector3 &x0, TVector3 &p)
 
- Public Member Functions inherited from art::EDAnalyzer
 EDAnalyzer (fhicl::ParameterSet const &pset)
 
template<typename Config >
 EDAnalyzer (Table< Config > const &config)
 
std::string workerType () const
 
- Public Member Functions inherited from art::detail::Analyzer
virtual ~Analyzer () noexcept
 
 Analyzer (fhicl::ParameterSet const &pset)
 
template<typename Config >
 Analyzer (Table< Config > const &config)
 
void doBeginJob (SharedResources const &resources)
 
void doEndJob ()
 
void doRespondToOpenInputFile (FileBlock const &fb)
 
void doRespondToCloseInputFile (FileBlock const &fb)
 
void doRespondToOpenOutputFiles (FileBlock const &fb)
 
void doRespondToCloseOutputFiles (FileBlock const &fb)
 
bool doBeginRun (RunPrincipal &rp, ModuleContext const &mc)
 
bool doEndRun (RunPrincipal &rp, ModuleContext const &mc)
 
bool doBeginSubRun (SubRunPrincipal &srp, ModuleContext const &mc)
 
bool doEndSubRun (SubRunPrincipal &srp, ModuleContext const &mc)
 
bool doEvent (EventPrincipal &ep, ModuleContext const &mc, std::atomic< std::size_t > &counts_run, std::atomic< std::size_t > &counts_passed, std::atomic< std::size_t > &counts_failed)
 
- Public Member Functions inherited from art::Observer
 ~Observer () noexcept
 
 Observer (Observer const &)=delete
 
 Observer (Observer &&)=delete
 
Observeroperator= (Observer const &)=delete
 
Observeroperator= (Observer &&)=delete
 
void registerProducts (ProductDescriptions &, ModuleDescription const &)
 
void fillDescriptions (ModuleDescription const &)
 
fhicl::ParameterSetID selectorConfig () const
 
- Public Member Functions inherited from art::ModuleBase
virtual ~ModuleBase () noexcept
 
 ModuleBase ()
 
ModuleDescription const & moduleDescription () const
 
void setModuleDescription (ModuleDescription const &)
 
std::array< std::vector< ProductInfo >, NumBranchTypes > const & getConsumables () const
 
void sortConsumables (std::string const &current_process_name)
 
template<typename T , BranchType BT>
ViewToken< T > consumesView (InputTag const &tag)
 
template<typename T , BranchType BT>
ViewToken< T > mayConsumeView (InputTag const &tag)
 

Private Member Functions

void BeamTrackInfo (const art::Event &evt, const recob::Track *thisTrack, detinfo::DetectorClocksData const &clockData)
 
void BeamShowerInfo (const art::Event &evt, const recob::Shower *thisShower)
 
void BeamPFPInfo (const art::Event &evt, const recob::PFParticle *particle, anab::MVAReader< recob::Hit, 4 > *hitResults)
 
void BeamForcedTrackInfo (const art::Event &evt, const recob::PFParticle *particle)
 
void TrueBeamInfo (const art::Event &evt, const simb::MCParticle *true_beam_particle, detinfo::DetectorClocksData const &clockData, const sim::ParticleList &plist, std::map< int, std::vector< int >> &trueToPFPs, anab::MVAReader< recob::Hit, 4 > *hitResults)
 
void BeamInstInfo (const art::Event &evt)
 
void DaughterPFPInfo (const art::Event &evt, const recob::PFParticle *particle, detinfo::DetectorClocksData const &clockData, anab::MVAReader< recob::Hit, 4 > *hitResults)
 
void DaughterMatchInfo (const art::Event &evt, const recob::PFParticle *daughterPFP, detinfo::DetectorClocksData const &clockData)
 
void BeamMatchInfo (const art::Event &evt, const recob::PFParticle *particle, const simb::MCParticle *true_beam_particle, detinfo::DetectorClocksData const &clockData)
 
void BeamForcedTrackInfo ()
 
void GetG4RWCoeffs (std::vector< double > &weights, std::vector< double > &coeffs)
 
void G4RWGridWeights (std::vector< std::vector< G4ReweightTraj * >> &hierarchy, std::vector< fhicl::ParameterSet > &pars, std::vector< std::vector< double >> &weights, G4MultiReweighter *multi_rw)
 

Private Attributes

const art::InputTag fTrackModuleLabel
 
TTree * fTree
 
int run
 
int subrun
 
int event
 
int MC
 
int true_beam_PDG
 
double true_beam_mass
 
int true_beam_ID
 
std::string true_beam_endProcess
 
double true_beam_endX
 
double true_beam_endY
 
double true_beam_endZ
 
double true_beam_endX_SCE
 
double true_beam_endY_SCE
 
double true_beam_endZ_SCE
 
double true_beam_startX
 
double true_beam_startY
 
double true_beam_startZ
 
double true_beam_startDirX
 
double true_beam_startDirY
 
double true_beam_startDirZ
 
double true_beam_startPx
 
double true_beam_startPy
 
double true_beam_startPz
 
double true_beam_startP
 
double true_beam_endPx
 
double true_beam_endPy
 
double true_beam_endPz
 
double true_beam_endP
 
double true_beam_endP2
 
double true_beam_last_len
 
int true_beam_nElasticScatters
 
int true_beam_nHits
 
std::vector< double > true_beam_elastic_costheta
 
std::vector< double > true_beam_elastic_X
 
std::vector< double > true_beam_elastic_Y
 
std::vector< double > true_beam_elastic_Z
 
std::vector< double > true_beam_elastic_deltaE
 
std::vector< double > true_beam_elastic_IDE_edep
 
double true_beam_IDE_totalDep
 
std::vector< std::stringtrue_beam_processes
 
std::vector< std::vector< int > > true_beam_reco_byHits_PFP_ID
 
std::vector< std::vector< int > > true_beam_reco_byHits_PFP_nHits
 
std::vector< std::vector< int > > true_beam_reco_byHits_allTrack_ID
 
std::vector< int > true_beam_daughter_PDG
 
std::vector< int > true_beam_daughter_ID
 
std::vector< double > true_beam_daughter_len
 
std::vector< std::stringtrue_beam_daughter_Process
 
std::vector< std::stringtrue_beam_daughter_endProcess
 
std::vector< double > true_beam_daughter_startX
 
std::vector< double > true_beam_daughter_startY
 
std::vector< double > true_beam_daughter_startZ
 
std::vector< double > true_beam_daughter_startP
 
std::vector< double > true_beam_daughter_startPx
 
std::vector< double > true_beam_daughter_startPy
 
std::vector< double > true_beam_daughter_startPz
 
std::vector< double > true_beam_daughter_endX
 
std::vector< double > true_beam_daughter_endY
 
std::vector< double > true_beam_daughter_endZ
 
std::vector< int > true_beam_daughter_nHits
 
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_PFP_ID
 
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_PFP_nHits
 
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_allTrack_ID
 
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_allShower_ID
 
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_PFP_trackScore
 
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_startX
 
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_startY
 
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_startZ
 
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_endX
 
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_endY
 
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_endZ
 
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_len
 
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_startX
 
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_startY
 
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_startZ
 
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_len
 
std::vector< int > true_beam_Pi0_decay_PDG
 
std::vector< int > true_beam_Pi0_decay_ID
 
std::vector< int > true_beam_Pi0_decay_parID
 
std::vector< double > true_beam_Pi0_decay_startP
 
std::vector< double > true_beam_Pi0_decay_startPx
 
std::vector< double > true_beam_Pi0_decay_startPy
 
std::vector< double > true_beam_Pi0_decay_startPz
 
std::vector< double > true_beam_Pi0_decay_startX
 
std::vector< double > true_beam_Pi0_decay_startY
 
std::vector< double > true_beam_Pi0_decay_startZ
 
std::vector< int > true_beam_Pi0_decay_nHits
 
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_PFP_ID
 
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_PFP_nHits
 
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_allTrack_ID
 
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_allShower_ID
 
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_PFP_trackScore
 
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_startX
 
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_startY
 
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_startZ
 
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_endX
 
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_endY
 
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_endZ
 
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_len
 
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_startX
 
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_startY
 
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_startZ
 
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_len
 
std::vector< double > true_beam_Pi0_decay_len
 
std::vector< int > true_beam_grand_daughter_PDG
 
std::vector< int > true_beam_grand_daughter_ID
 
std::vector< int > true_beam_grand_daughter_parID
 
std::vector< int > true_beam_grand_daughter_nHits
 
std::vector< std::stringtrue_beam_grand_daughter_Process
 
std::vector< std::stringtrue_beam_grand_daughter_endProcess
 
int true_daughter_nPiPlus
 
int true_daughter_nPiMinus
 
int true_daughter_nPi0
 
int true_daughter_nProton
 
int true_daughter_nNeutron
 
int true_daughter_nNucleus
 
int reco_beam_vertex_slice
 
double reco_beam_startX
 
double reco_beam_startY
 
double reco_beam_startZ
 
double reco_beam_endX
 
double reco_beam_endY
 
double reco_beam_endZ
 
double true_beam_len
 
double reco_beam_len
 
double reco_beam_alt_len
 
double reco_beam_alt_len_allTrack
 
double reco_beam_vertex_michel_score
 
int reco_beam_vertex_nHits
 
double reco_beam_vertex_michel_score_allTrack
 
int reco_beam_vertex_nHits_allTrack
 
double reco_beam_vertex_michel_score_weight_by_charge
 
double reco_beam_vertex_michel_score_weight_by_charge_allTrack
 
double reco_beam_calo_startX
 
double reco_beam_calo_startY
 
double reco_beam_calo_startZ
 
double reco_beam_calo_endX
 
double reco_beam_calo_endY
 
double reco_beam_calo_endZ
 
double reco_beam_calo_startX_allTrack
 
double reco_beam_calo_startY_allTrack
 
double reco_beam_calo_startZ_allTrack
 
double reco_beam_calo_endX_allTrack
 
double reco_beam_calo_endY_allTrack
 
double reco_beam_calo_endZ_allTrack
 
std::vector< double > reco_beam_calo_X
 
std::vector< double > reco_beam_calo_Y
 
std::vector< double > reco_beam_calo_Z
 
std::vector< double > reco_beam_calo_X_allTrack
 
std::vector< double > reco_beam_calo_Y_allTrack
 
std::vector< double > reco_beam_calo_Z_allTrack
 
std::vector< double > reco_beam_calo_startDirX
 
std::vector< double > reco_beam_calo_endDirX
 
std::vector< double > reco_beam_calo_startDirY
 
std::vector< double > reco_beam_calo_endDirY
 
std::vector< double > reco_beam_calo_startDirZ
 
std::vector< double > reco_beam_calo_endDirZ
 
double reco_beam_trackDirX
 
double reco_beam_trackDirY
 
double reco_beam_trackDirZ
 
double reco_beam_trackEndDirX
 
double reco_beam_trackEndDirY
 
double reco_beam_trackEndDirZ
 
std::vector< double > reco_beam_dEdX_SCE
 
std::vector< double > reco_beam_dQdX_SCE
 
std::vector< double > reco_beam_EField_SCE
 
std::vector< double > reco_beam_resRange_SCE
 
std::vector< double > reco_beam_TrkPitch_SCE
 
std::vector< double > reco_beam_TrkPitch_SCE_allTrack
 
std::vector< double > reco_beam_calibrated_dEdX_SCE
 
std::vector< double > reco_beam_calibrated_dQdX_SCE
 
std::vector< double > reco_beam_dQ
 
std::vector< double > reco_beam_dEdX_NoSCE
 
std::vector< double > reco_beam_dQdX_NoSCE
 
std::vector< double > reco_beam_resRange_NoSCE
 
std::vector< double > reco_beam_TrkPitch_NoSCE
 
std::vector< double > reco_beam_calibrated_dEdX_NoSCE
 
std::vector< double > reco_beam_calo_wire
 
std::vector< double > reco_beam_calo_tick
 
std::vector< double > reco_beam_calo_wire_z
 
std::vector< double > reco_beam_calo_wire_allTrack
 
std::vector< double > reco_beam_calo_wire_NoSCE
 
std::vector< double > reco_beam_dQ_NoSCE
 
std::vector< double > reco_beam_calo_wire_z_NoSCE
 
std::vector< int > reco_beam_calo_TPC
 
std::vector< int > reco_beam_calo_TPC_NoSCE
 
int reco_beam_trackID
 
int n_beam_slices
 
int n_beam_particles
 
std::vector< int > beam_track_IDs
 
std::vector< double > beam_particle_scores
 
bool reco_beam_flipped
 
bool reco_beam_passes_beam_cuts
 
int reco_beam_type
 
double reco_beam_Chi2_proton
 
int reco_beam_Chi2_ndof
 
std::vector< double > reco_track_startX
 
std::vector< double > reco_track_startY
 
std::vector< double > reco_track_startZ
 
std::vector< double > reco_track_endX
 
std::vector< double > reco_track_endY
 
std::vector< double > reco_track_endZ
 
std::vector< double > reco_track_michel_score
 
std::vector< double > reco_track_michel_score_weight_by_charge
 
std::vector< int > reco_track_ID
 
std::vector< int > reco_track_nHits
 
std::vector< double > g4rw_primary_weights
 
std::vector< double > g4rw_primary_plus_sigma_weight
 
std::vector< double > g4rw_primary_minus_sigma_weight
 
std::vector< std::stringg4rw_primary_var
 
std::vector< double > g4rw_alt_primary_plus_sigma_weight
 
std::vector< double > g4rw_alt_primary_minus_sigma_weight
 
std::vector< double > g4rw_full_primary_plus_sigma_weight
 
std::vector< double > g4rw_full_primary_minus_sigma_weight
 
std::vector< std::vector< double > > g4rw_full_grid_weights
 
std::vector< std::vector< double > > g4rw_full_grid_coeffs
 
std::vector< std::vector< double > > g4rw_primary_grid_weights
 
std::vector< double > g4rw_primary_grid_pair_weights
 
std::vector< std::vector< double > > g4rw_full_grid_piplus_weights
 
std::vector< std::vector< double > > g4rw_full_grid_piplus_coeffs
 
std::vector< std::vector< double > > g4rw_full_grid_piplus_weights_fake_data
 
std::vector< std::vector< double > > g4rw_full_grid_piminus_weights
 
std::vector< std::vector< double > > g4rw_full_grid_proton_weights
 
std::vector< std::vector< double > > g4rw_full_grid_proton_coeffs
 
std::vector< std::vector< double > > g4rw_full_grid_neutron_weights
 
std::vector< std::vector< double > > g4rw_full_grid_neutron_coeffs
 
std::vector< std::vector< double > > g4rw_full_grid_kplus_weights
 
std::vector< std::vector< double > > g4rw_full_grid_kplus_coeffs
 
std::string reco_beam_true_byE_endProcess
 
std::string reco_beam_true_byHits_endProcess
 
std::string reco_beam_true_byE_process
 
std::string reco_beam_true_byHits_process
 
int reco_beam_true_byE_PDG
 
int reco_beam_true_byHits_PDG
 
int reco_beam_true_byE_ID
 
int reco_beam_true_byHits_ID
 
bool reco_beam_true_byE_matched
 
bool reco_beam_true_byHits_matched
 
int reco_beam_true_byE_origin
 
int reco_beam_true_byHits_origin
 
double reco_beam_true_byE_endPx
 
double reco_beam_true_byHits_endPx
 
double reco_beam_true_byE_endPy
 
double reco_beam_true_byHits_endPy
 
double reco_beam_true_byE_endPz
 
double reco_beam_true_byHits_endPz
 
double reco_beam_true_byE_endE
 
double reco_beam_true_byHits_endE
 
double reco_beam_true_byE_endP
 
double reco_beam_true_byHits_endP
 
double reco_beam_true_byE_startPx
 
double reco_beam_true_byHits_startPx
 
double reco_beam_true_byE_startPy
 
double reco_beam_true_byHits_startPy
 
double reco_beam_true_byE_startPz
 
double reco_beam_true_byHits_startPz
 
double reco_beam_true_byE_startE
 
double reco_beam_true_byHits_startE
 
double reco_beam_true_byE_startP
 
double reco_beam_true_byHits_startP
 
double reco_beam_true_byHits_purity
 
std::vector< double > reco_beam_incidentEnergies
 
double reco_beam_interactingEnergy
 
std::vector< double > reco_beam_incidentEnergies_allTrack
 
double reco_beam_interactingEnergy_allTrack
 
std::vector< double > true_beam_incidentEnergies
 
std::vector< int > true_beam_slices
 
std::vector< int > true_beam_slices_found
 
std::vector< double > true_beam_slices_deltaE
 
double true_beam_interactingEnergy
 
double em_energy
 
std::vector< double > true_beam_traj_X
 
std::vector< double > true_beam_traj_Y
 
std::vector< double > true_beam_traj_Z
 
std::vector< double > true_beam_traj_Px
 
std::vector< double > true_beam_traj_Py
 
std::vector< double > true_beam_traj_Pz
 
std::vector< double > true_beam_traj_KE
 
std::vector< double > true_beam_traj_X_SCE
 
std::vector< double > true_beam_traj_Y_SCE
 
std::vector< double > true_beam_traj_Z_SCE
 
int reco_beam_PFP_ID
 
int reco_beam_PFP_nHits
 
double reco_beam_PFP_trackScore
 
double reco_beam_PFP_trackScore_weight_by_charge
 
double reco_beam_PFP_emScore
 
double reco_beam_PFP_emScore_weight_by_charge
 
double reco_beam_PFP_michelScore
 
double reco_beam_PFP_michelScore_weight_by_charge
 
double reco_beam_PFP_trackScore_collection
 
double reco_beam_PFP_trackScore_collection_weight_by_charge
 
double reco_beam_PFP_emScore_collection
 
double reco_beam_PFP_emScore_collection_weight_by_charge
 
double reco_beam_PFP_michelScore_collection
 
double reco_beam_PFP_michelScore_collection_weight_by_charge
 
int reco_beam_allTrack_ID
 
bool reco_beam_allTrack_beam_cuts
 
bool reco_beam_allTrack_flipped
 
double reco_beam_allTrack_len
 
double reco_beam_allTrack_startX
 
double reco_beam_allTrack_startY
 
double reco_beam_allTrack_startZ
 
double reco_beam_allTrack_endX
 
double reco_beam_allTrack_endY
 
double reco_beam_allTrack_endZ
 
double reco_beam_allTrack_trackDirX
 
double reco_beam_allTrack_trackDirY
 
double reco_beam_allTrack_trackDirZ
 
double reco_beam_allTrack_trackEndDirX
 
double reco_beam_allTrack_trackEndDirY
 
double reco_beam_allTrack_trackEndDirZ
 
std::vector< double > reco_beam_allTrack_resRange
 
std::vector< double > reco_beam_allTrack_calibrated_dEdX
 
double reco_beam_allTrack_Chi2_proton
 
int reco_beam_allTrack_Chi2_ndof
 
double beam_inst_P
 
bool beam_inst_valid
 
int beam_inst_trigger
 
std::vector< double > beam_inst_TOF
 
std::vector< int > beam_inst_PDG_candidates
 
std::vector< int > beam_inst_TOF_Chan
 
double beam_inst_X
 
double beam_inst_Y
 
double beam_inst_Z
 
double beam_inst_dirX
 
double beam_inst_dirY
 
double beam_inst_dirZ
 
int beam_inst_nFibersP1
 
int beam_inst_nFibersP2
 
int beam_inst_nFibersP3
 
int beam_inst_nTracks
 
int beam_inst_nMomenta
 
int beam_inst_C0
 
int beam_inst_C1
 
double beam_inst_C0_pressure
 
double beam_inst_C1_pressure
 
bool reco_reconstructable_beam_event
 
std::vector< int > reco_daughter_PFP_ID
 
std::vector< int > reco_daughter_pandora_type
 
std::vector< int > reco_daughter_PFP_nHits
 
std::vector< int > reco_daughter_PFP_nHits_collection
 
std::vector< double > reco_daughter_PFP_trackScore
 
std::vector< double > reco_daughter_PFP_emScore
 
std::vector< double > reco_daughter_PFP_michelScore
 
std::vector< double > reco_daughter_PFP_trackScore_collection
 
std::vector< double > reco_daughter_PFP_emScore_collection
 
std::vector< double > reco_daughter_PFP_michelScore_collection
 
std::vector< int > reco_daughter_PFP_true_byHits_PDG
 
std::vector< int > reco_daughter_PFP_true_byHits_ID
 
std::vector< int > reco_daughter_PFP_true_byHits_origin
 
std::vector< int > reco_daughter_PFP_true_byHits_parID
 
std::vector< int > reco_daughter_PFP_true_byHits_parPDG
 
std::vector< std::stringreco_daughter_PFP_true_byHits_process
 
std::vector< double > reco_daughter_PFP_true_byHits_purity
 
std::vector< size_t > reco_daughter_PFP_true_byHits_sharedHits
 EDIT: quality. More...
 
std::vector< size_t > reco_daughter_PFP_true_byHits_emHits
 
std::vector< double > reco_daughter_PFP_true_byHits_completeness
 
std::vector< double > reco_daughter_PFP_true_byHits_len
 
std::vector< double > reco_daughter_PFP_true_byHits_startX
 
std::vector< double > reco_daughter_PFP_true_byHits_startY
 
std::vector< double > reco_daughter_PFP_true_byHits_startZ
 
std::vector< double > reco_daughter_PFP_true_byHits_endX
 
std::vector< double > reco_daughter_PFP_true_byHits_endY
 
std::vector< double > reco_daughter_PFP_true_byHits_endZ
 
std::vector< double > reco_daughter_PFP_true_byHits_startPx
 
std::vector< double > reco_daughter_PFP_true_byHits_startPy
 
std::vector< double > reco_daughter_PFP_true_byHits_startPz
 
std::vector< double > reco_daughter_PFP_true_byHits_startE
 
std::vector< double > reco_daughter_PFP_true_byHits_startP
 
std::vector< std::stringreco_daughter_PFP_true_byHits_endProcess
 
std::vector< int > reco_daughter_PFP_true_byE_PDG
 
std::vector< double > reco_daughter_PFP_true_byE_len
 
std::vector< double > reco_daughter_PFP_true_byE_completeness
 
std::vector< double > reco_daughter_PFP_true_byE_purity
 
std::vector< int > reco_daughter_allTrack_ID
 
std::vector< double > reco_daughter_allTrack_Theta
 
std::vector< double > reco_daughter_allTrack_Phi
 
std::vector< std::vector< double > > reco_daughter_allTrack_dQdX_SCE
 
std::vector< std::vector< double > > reco_daughter_allTrack_dEdX_SCE
 
std::vector< std::vector< double > > reco_daughter_allTrack_resRange_SCE
 
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dEdX_SCE
 
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dQdX_SCE
 
std::vector< std::vector< double > > reco_daughter_allTrack_EField_SCE
 
std::vector< std::vector< double > > reco_daughter_allTrack_calo_X
 
std::vector< std::vector< double > > reco_daughter_allTrack_calo_Y
 
std::vector< std::vector< double > > reco_daughter_allTrack_calo_Z
 
std::vector< double > reco_daughter_allTrack_Chi2_proton
 
std::vector< double > reco_daughter_allTrack_Chi2_muon
 
std::vector< double > reco_daughter_allTrack_Chi2_pion
 
std::vector< int > reco_daughter_allTrack_Chi2_ndof
 
std::vector< int > reco_daughter_allTrack_Chi2_ndof_muon
 
std::vector< int > reco_daughter_allTrack_Chi2_ndof_pion
 
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dEdX_SCE_plane0
 
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dEdX_SCE_plane1
 
std::vector< std::vector< double > > reco_daughter_allTrack_resRange_plane0
 
std::vector< std::vector< double > > reco_daughter_allTrack_resRange_plane1
 
std::vector< double > reco_daughter_allTrack_Chi2_proton_plane0
 
std::vector< double > reco_daughter_allTrack_Chi2_proton_plane1
 
std::vector< int > reco_daughter_allTrack_Chi2_ndof_plane0
 
std::vector< int > reco_daughter_allTrack_Chi2_ndof_plane1
 
std::vector< double > reco_daughter_allTrack_startX
 
std::vector< double > reco_daughter_allTrack_endX
 
std::vector< double > reco_daughter_allTrack_startY
 
std::vector< double > reco_daughter_allTrack_endY
 
std::vector< double > reco_daughter_allTrack_startZ
 
std::vector< double > reco_daughter_allTrack_endZ
 
std::vector< double > reco_daughter_allTrack_len
 
std::vector< double > reco_daughter_allTrack_alt_len
 
std::vector< double > reco_daughter_allTrack_vertex_michel_score
 
std::vector< int > reco_daughter_allTrack_vertex_nHits
 
std::vector< int > reco_daughter_allShower_ID
 
std::vector< double > reco_daughter_allShower_len
 
std::vector< double > reco_daughter_allShower_startX
 
std::vector< double > reco_daughter_allShower_startY
 
std::vector< double > reco_daughter_allShower_startZ
 
std::vector< double > reco_daughter_allShower_dirX
 
std::vector< double > reco_daughter_allShower_dirY
 
std::vector< double > reco_daughter_allShower_dirZ
 
std::vector< double > reco_daughter_allShower_energy
 
std::vector< double > reco_daughter_allTrack_momByRange_proton
 
std::vector< double > reco_daughter_allTrack_momByRange_muon
 
double reco_beam_momByRange_proton
 
double reco_beam_momByRange_muon
 
std::vector< double > reco_daughter_allTrack_momByRange_alt_proton
 
std::vector< double > reco_daughter_allTrack_momByRange_alt_muon
 
double reco_beam_momByRange_alt_proton
 
double reco_beam_momByRange_alt_muon
 
std::vector< double > reco_beam_spacePts_X
 
std::vector< double > reco_beam_spacePts_Y
 
std::vector< double > reco_beam_spacePts_Z
 
std::vector< std::vector< double > > reco_daughter_spacePts_X
 
std::vector< std::vector< double > > reco_daughter_spacePts_Y
 
std::vector< std::vector< double > > reco_daughter_spacePts_Z
 
std::vector< std::vector< double > > reco_daughter_shower_spacePts_X
 
std::vector< std::vector< double > > reco_daughter_shower_spacePts_Y
 
std::vector< std::vector< double > > reco_daughter_shower_spacePts_Z
 
std::map< int, TProfile * > templates
 
std::string fCalorimetryTagSCE
 
std::string fPandora2CaloSCE
 
std::string fCalorimetryTagNoSCE
 
std::string fTrackerTag
 
std::string fHitTag
 
std::string fShowerTag
 
std::string fPFParticleTag
 
std::string fGeneratorTag
 
std::string fBeamModuleLabel
 
protoana::ProtoDUNEBeamlineUtils fBeamlineUtils
 
protoana::ProtoDUNEEmptyEventFinder fEmptyEventFinder
 
double fBeamPIDMomentum
 
std::string dEdX_template_name
 
TFile * dEdX_template_file
 
bool fVerbose
 
fhicl::ParameterSet BeamPars
 
fhicl::ParameterSet BeamCuts
 
protoana::ProtoDUNEBeamCuts beam_cuts
 
art::ServiceHandle< cheat::BackTrackerServicebt_serv
 
art::ServiceHandle< cheat::ParticleInventoryServicepi_serv
 
protoana::ProtoDUNETrackUtils trackUtil
 
protoana::ProtoDUNEShowerUtils showerUtil
 
protoana::ProtoDUNETruthUtils truthUtil
 
protoana::ProtoDUNEPFParticleUtils pfpUtil
 
art::ServiceHandle< geo::Geometrygeom
 
protoana::ProtoDUNECalibration calibration_SCE
 
protoana::ProtoDUNECalibration calibration_NoSCE
 
bool fSaveHits
 
bool fSkipMVA
 
bool fTrueToReco
 
bool fDoReweight
 
bool fDoProtReweight
 
bool fGetTrackMichel
 
bool fMCHasBI
 
bool fRecalibrate
 
bool fCheckSlicesForBeam
 
bool fSCE
 
double fZ0
 
double fPitch
 
TFile * FracsFile
 
TFile * ProtFracsFile
 
std::vector< fhicl::ParameterSetParSet
 
std::vector< fhicl::ParameterSetFakeDataParSet
 
std::vector< fhicl::ParameterSetProtParSet
 
std::vector< double > fGridPoints
 
std::pair< double, double > fGridPair
 
G4ReweightParameterMaker ParMaker
 
G4ReweightParameterMaker FakeDataParameterMaker
 
G4ReweightParameterMaker ProtParMaker
 
G4MultiReweighter * MultiRW
 
G4MultiReweighter * ProtMultiRW
 
G4MultiReweighter * PiMinusMultiRW
 
G4MultiReweighter * KPlusMultiRW
 
G4MultiReweighter * NeutronMultiRW
 
G4MultiReweighter * FakeDataMultiRW
 
G4ReweightManager * RWManager
 

Additional Inherited Members

- Public Types inherited from art::EDAnalyzer
using WorkerType = WorkerT< EDAnalyzer >
 
using ModuleType = EDAnalyzer
 
- Protected Member Functions inherited from art::Observer
std::string const & processName () const
 
bool wantAllEvents () const noexcept
 
bool wantEvent (ScheduleID id, Event const &e) const
 
Handle< TriggerResultsgetTriggerResults (Event const &e) const
 
 Observer (fhicl::ParameterSet const &config)
 
 Observer (std::vector< std::string > const &select_paths, std::vector< std::string > const &reject_paths, fhicl::ParameterSet const &config)
 
- Protected Member Functions inherited from art::ModuleBase
ConsumesCollectorconsumesCollector ()
 
template<typename T , BranchType = InEvent>
ProductToken< T > consumes (InputTag const &)
 
template<typename Element , BranchType = InEvent>
ViewToken< Element > consumesView (InputTag const &)
 
template<typename T , BranchType = InEvent>
void consumesMany ()
 
template<typename T , BranchType = InEvent>
ProductToken< T > mayConsume (InputTag const &)
 
template<typename Element , BranchType = InEvent>
ViewToken< Element > mayConsumeView (InputTag const &)
 
template<typename T , BranchType = InEvent>
void mayConsumeMany ()
 

Detailed Description

Definition at line 294 of file PDSPAnalyzer_module.cc.

Constructor & Destructor Documentation

pduneana::PDSPAnalyzer::PDSPAnalyzer ( fhicl::ParameterSet const &  p)
explicit

Definition at line 810 of file PDSPAnalyzer_module.cc.

811  : EDAnalyzer{p} ,
812  fTrackModuleLabel(p.get< art::InputTag >("TrackModuleLabel")),
813  fCalorimetryTagSCE(p.get<std::string>("CalorimetryTagSCE")),
814  fPandora2CaloSCE(p.get<std::string>("Pandora2CaloSCE")),
815  fCalorimetryTagNoSCE(p.get<std::string>("CalorimetryTagNoSCE")),
816  fTrackerTag(p.get<std::string>("TrackerTag")),
817  fHitTag(p.get<std::string>("HitTag")),
818  fShowerTag(p.get<std::string>("ShowerTag")),
819  fPFParticleTag(p.get<std::string>("PFParticleTag")),
820  fGeneratorTag(p.get<std::string>("GeneratorTag")),
821  fBeamModuleLabel(p.get<std::string>("BeamModuleLabel")),
822  fBeamlineUtils(p.get< fhicl::ParameterSet >("BeamlineUtils")),
823  fEmptyEventFinder(p.get< fhicl::ParameterSet >("EmptyEventFinder")),
824  fBeamPIDMomentum(p.get<double>("BeamPIDMomentum", 1.)),
825  dEdX_template_name(p.get<std::string>("dEdX_template_name")),
826  //dEdX_template_file( dEdX_template_name.c_str(), "OPEN" ),
827  fVerbose(p.get<bool>("Verbose")),
828  BeamPars(p.get<fhicl::ParameterSet>("BeamPars")),
829  BeamCuts(p.get<fhicl::ParameterSet>("BeamCuts")),
830  calibration_SCE(p.get<fhicl::ParameterSet>("CalibrationParsSCE")),
831  calibration_NoSCE(p.get<fhicl::ParameterSet>("CalibrationParsNoSCE")),
832  fSaveHits( p.get<bool>( "SaveHits" ) ),
833  fSkipMVA( p.get<bool>( "SkipMVA" ) ),
834  fTrueToReco( p.get<bool>( "TrueToReco" ) ),
835  fDoReweight(p.get<bool>("DoReweight")),
836  fDoProtReweight(p.get<bool>("DoProtReweight")),
837  fGetTrackMichel(p.get<bool>("GetTrackMichel")),
838  fRecalibrate(p.get<bool>("Recalibrate", true)),
839  fCheckSlicesForBeam(p.get<bool>("CheckSlicesForBeam", false)),
840  fSCE(p.get<bool>("SCE", true)){
841 
843  templates[ 211 ] = (TProfile*)dEdX_template_file->Get( "dedx_range_pi" );
844  templates[ 321 ] = (TProfile*)dEdX_template_file->Get( "dedx_range_ka" );
845  templates[ 13 ] = (TProfile*)dEdX_template_file->Get( "dedx_range_mu" );
846  templates[ 2212 ] = (TProfile*)dEdX_template_file->Get( "dedx_range_pro" );
847 
849 
850  if (fDoReweight || fDoProtReweight) {
851  RWManager = new G4ReweightManager({p.get<fhicl::ParameterSet>("Material")});
852  }
853 
854  if (fDoReweight) {
855  //Pion Reweighter
856  FracsFile = OpenFile(p.get< std::string >("FracsFile"));
857  ParSet = p.get<std::vector<fhicl::ParameterSet>>("ParameterSet");
858  ParMaker = G4ReweightParameterMaker(ParSet);
859  MultiRW = new G4MultiReweighter(211, *FracsFile, ParSet,
860  p.get<fhicl::ParameterSet>("Material"),
861  RWManager);
862  FakeDataParSet = p.get<std::vector<fhicl::ParameterSet>>("FakeDataParameterSet");
863  FakeDataMultiRW = new G4MultiReweighter(211, *FracsFile, FakeDataParSet,
864  p.get<fhicl::ParameterSet>("Material"),
865  RWManager);
866  //Proton Reweighter
867  ProtFracsFile = OpenFile(p.get< std::string >("ProtFracsFile"));
868  ProtParSet = p.get<std::vector<fhicl::ParameterSet>>("ProtParameterSet");
869  ProtParMaker = G4ReweightParameterMaker(ProtParSet);
870  ProtMultiRW = new G4MultiReweighter(
871  2212, *ProtFracsFile, ProtParSet,
872  p.get<fhicl::ParameterSet>("Material"),
873  RWManager);
874 
875 
876  //K Plus Reweighter
877  // -- Just use proton fracs and parameter set
878  // -- because it's just reaction
879  KPlusMultiRW = new G4MultiReweighter(
880  321, *ProtFracsFile, ProtParSet,
881  p.get<fhicl::ParameterSet>("Material"),
882  RWManager);
883 
884  //Neutron Reweighter
885  // -- Just use proton fracs and parameter set
886  // -- because it's just reaction
887  KPlusMultiRW = new G4MultiReweighter(
888  2112, *ProtFracsFile, ProtParSet,
889  p.get<fhicl::ParameterSet>("Material"),
890  RWManager);
891 
892  //Setting up grid points for mutliple variations
893  double start = p.get<double>("ParameterGridStart");
894  double delta = p.get<double>("ParameterGridDelta");
895  int n = p.get<int>("ParameterGridN");
896  for (int i = 0; i < n; ++i) {
897  fGridPoints.push_back(start);
898  start += delta;
899  }
900  fGridPair = p.get<std::pair<double, double>>("GridPair");
901  }
902 
903  fZ0 = geom->Wire( geo::WireID(0, 1, 2, 0) ).GetCenter().Z();
904  fPitch = geom->WirePitch( 2, 1, 0);
905 
906 }
G4MultiReweighter * KPlusMultiRW
protoana::ProtoDUNEBeamCuts beam_cuts
TFile * OpenFile(const std::string filename)
std::vector< fhicl::ParameterSet > FakeDataParSet
std::pair< double, double > fGridPair
std::string string
Definition: nybbler.cc:12
std::vector< fhicl::ParameterSet > ParSet
art::ServiceHandle< geo::Geometry > geom
protoana::ProtoDUNEEmptyEventFinder fEmptyEventFinder
EDAnalyzer(fhicl::ParameterSet const &pset)
Definition: EDAnalyzer.h:25
G4ReweightManager * RWManager
geo::Length_t WirePitch(geo::PlaneID const &planeid) const
Returns the distance between two consecutive wires.
G4MultiReweighter * ProtMultiRW
fhicl::ParameterSet BeamCuts
std::vector< fhicl::ParameterSet > ProtParSet
protoana::ProtoDUNECalibration calibration_NoSCE
const art::InputTag fTrackModuleLabel
G4MultiReweighter * MultiRW
std::void_t< T > n
p
Definition: test.py:223
std::map< int, TProfile * > templates
protoana::ProtoDUNECalibration calibration_SCE
protoana::ProtoDUNEBeamlineUtils fBeamlineUtils
WireGeo const & Wire(geo::WireID const &wireid) const
Returns the specified wire.
G4ReweightParameterMaker ParMaker
std::vector< double > fGridPoints
fhicl::ParameterSet BeamPars
void GetCenter(double *xyz, double localz=0.0) const
Fills the world coordinate of a point on the wire.
Definition: WireGeo.cxx:73
G4MultiReweighter * FakeDataMultiRW
G4ReweightParameterMaker ProtParMaker
pduneana::PDSPAnalyzer::PDSPAnalyzer ( PDSPAnalyzer const &  )
delete
pduneana::PDSPAnalyzer::PDSPAnalyzer ( PDSPAnalyzer &&  )
delete

Member Function Documentation

void pduneana::PDSPAnalyzer::analyze ( art::Event const &  evt)
overridevirtual

Gets the beam pfparticle

Implements art::EDAnalyzer.

Definition at line 908 of file PDSPAnalyzer_module.cc.

908  {
909 
910  //reset containers
911  reset();
912 
913 
914  run = evt.run();
915  subrun = evt.subRun();
916  event = evt.id().event();
917  std::cout<<"########## EvtNo."<<event<<std::endl;
918 
919  if( !evt.isRealData() ) MC = 1;
920  else MC = 0;
921 
922  // Is this a reconstructable beam event?
924 
925  // Get various utilities
927  auto pfpVec = evt.getValidHandle< std::vector< recob::PFParticle > >( fPFParticleTag );
928 
929  if (fGetTrackMichel && !fSkipMVA) {
930  for (const recob::PFParticle & pfp : (*pfpVec)) {
931  const recob::Track* tempTrack = pfpUtil.GetPFParticleTrack(pfp, evt,
933  fTrackerTag);
934  if (tempTrack) {
935  double startX = tempTrack->Start().X();
936  double startY = tempTrack->Start().Y();
937  double startZ = tempTrack->Start().Z();
938 
939  double endX = tempTrack->End().X();
940  double endY = tempTrack->End().Y();
941  double endZ = tempTrack->End().Z();
942 
943  double start[3] = {startX, startY, startZ};
944  double end[3] = {endX, endY, endZ};
945  int end_tpc = geom->FindTPCAtPosition(end).TPC;
946  int start_tpc = geom->FindTPCAtPosition(start).TPC;
947 
948  if (!((end_tpc == 1 || end_tpc == 5) &&
949  (start_tpc == 1 || start_tpc == 5)))
950  continue;
951 
952  std::pair<double, int> vertex_michel_score =
954  fHitTag);
955  std::pair<double, double> vertex_michel_score_weight_by_charge =
957  fHitTag);
958 
959  reco_track_michel_score.push_back(vertex_michel_score.first);
960  reco_track_nHits.push_back(vertex_michel_score.second);
961  reco_track_michel_score_weight_by_charge.push_back( vertex_michel_score_weight_by_charge.second != 0 ? vertex_michel_score_weight_by_charge.first/vertex_michel_score_weight_by_charge.second : -999. );
962  reco_track_ID.push_back(tempTrack->ID());
963  reco_track_startX.push_back(startX);
964  reco_track_startY.push_back(startY);
965  reco_track_startZ.push_back(startZ);
966  reco_track_endX.push_back(endX);
967  reco_track_endY.push_back(endY);
968  reco_track_endZ.push_back(endZ);
969  }
970  }
971  }
972 
973  const sim::ParticleList & plist = pi_serv->ParticleList();
974 
975  art::ServiceHandle < geo::Geometry > fGeometryService;
976  auto const clockData = art::ServiceHandle<detinfo::DetectorClocksService>()->DataFor(evt);
977  auto const detProp = art::ServiceHandle<detinfo::DetectorPropertiesService>()->DataFor(evt, clockData);
978  trkf::TrackMomentumCalculator track_p_calc;
979  ////////////////////////////////////////
980 
981 
982  //double z0 = geom->Wire( geo::WireID(0, 1, 2, 0) ).GetCenter().Z();
983  //double pitch = geom->WirePitch( 2, 1, 0);
984 
985  if (fVerbose) {
986  std::cout << "Z0: " << fZ0 << std::endl;
987  std::cout << "Pitch: " << fPitch << std::endl;
988 
989  double z0_APA2 = geom->Wire(geo::WireID(0, 5, 2, 0)).GetCenter().Z();
990  std::cout << "APA 2 Z0: " << z0_APA2 << std::endl;
991  }
992 
993  // This gets the true beam particle that generated the event
994  const simb::MCParticle* true_beam_particle = 0x0;
995  if( !evt.isRealData() ){
996  auto mcTruths = evt.getValidHandle<std::vector<simb::MCTruth>>(fGeneratorTag);
997  true_beam_particle = truthUtil.GetGeantGoodParticle((*mcTruths)[0],evt);
998  if( !true_beam_particle ){
999  MF_LOG_WARNING("PDSPAnalyzer") << "No true beam particle" << std::endl;
1000  return;
1001  }
1002  if (fVerbose) {
1003  std::cout << "Got " << (*mcTruths)[0].NParticles() <<
1004  " particles in mcTruth" << std::endl;
1005  for (int i = 0; i < (*mcTruths)[0].NParticles(); ++i) {
1006  simb::MCParticle part = (*mcTruths)[0].GetParticle(i);
1007  std::cout << part.Process() << " " << part.TrackId() << " " <<
1008  part.PdgCode() << std::endl;
1009 
1010  }
1011  }
1012  }
1013  ////////////////////////////
1014 
1015  //Get the beam instrumentation from the event
1016  BeamInstInfo(evt);
1017 
1018 
1019  // Helper to get hits and the 4 associated CNN outputs
1020  // CNN Outputs: EM, Track, Michel, Empty
1021  // outputNames: track, em, none, michel
1022  anab::MVAReader<recob::Hit,4> * hitResults = 0x0;
1023  if (!fSkipMVA) {
1024  hitResults = new anab::MVAReader<recob::Hit, 4>(evt, "emtrkmichelid:emtrkmichel" );
1025  }
1026 
1027  /*
1028  auto recoTracks = evt.getValidHandle<std::vector<recob::Track> >(fTrackerTag);
1029  art::FindManyP<recob::Hit> findHits(recoTracks,evt,fTrackerTag);
1030 
1031  auto recoShowers = evt.getValidHandle< std::vector< recob::Shower > >(fShowerTag);
1032  art::FindManyP<recob::Hit> findHitsFromShowers(recoShowers,evt,fShowerTag);
1033  */
1034 
1035  std::map< int, std::vector< int > > trueToPFPs;
1036  if( fTrueToReco ){
1037  trueToPFPs = truthUtil.GetMapMCToPFPs_ByHits( clockData, evt, fPFParticleTag, fHitTag );
1038  }
1039 
1040 
1041  n_beam_slices = 0;
1042  n_beam_particles = 0;
1043  const std::map<unsigned int, std::vector<const recob::PFParticle*>> sliceMap
1045  std::vector<std::vector<const recob::PFParticle*>> beam_slices;
1046  for (auto slice : sliceMap) {
1047  for (auto particle : slice.second) {
1048  bool added = false;
1049  if (pfpUtil.IsBeamParticle(*particle,evt, fPFParticleTag)) {
1050  if (!added) {
1051  beam_slices.push_back(slice.second);
1052  ++n_beam_slices;
1053  added = true;
1054  }
1055  //std::cout << "Slice: " << slice.first << " N Part: " <<
1056  // slice.second.size() << std::endl;
1057  for (const auto * p : slice.second) {
1058  const recob::Track* track
1060  ++n_beam_particles;
1062  if (track) {
1063  //std::cout << "Slice: " << slice.first << " ID: " << track->ID() <<
1064  // std::endl;
1065  beam_track_IDs.push_back(track->ID());
1066  }
1067  else {
1068  beam_track_IDs.push_back(-999);
1069  }
1070  }
1071  }
1072  if (!added) {continue;}
1073  //else {
1074  // std::cout << "Not beam particle" << std::endl;
1075  //}
1076  }
1077  }
1078  //std::cout << "Got " << beam_slices.size() <<" beam slices" << std::endl;
1079 
1080 
1081  ///Gets the beam pfparticle
1082  if(beam_slices.size() == 0){
1083  std::cout << "We found no beam particles for this event... moving on" << std::endl;
1084  //return;
1085  }
1086  else {
1087  std::vector<const recob::PFParticle*> beamParticles = pfpUtil.GetPFParticlesFromBeamSlice(evt,fPFParticleTag);
1088  if (fVerbose)
1089  std::cout << "Found " << beamParticles.size() << " particles" << std::endl;
1090 
1091  //////////////////////////////////////////////////////////////////
1092  int ii = 0; // index of beam particle candidate
1093  int iiloop = 0;
1094  double cut_v = 9999.; // cut value
1095  for (std::vector<const recob::PFParticle*> beam_slice : beam_slices) {
1096  const recob::PFParticle* particle = beam_slice.at(0);
1097  const TVector3 vtx = pfpUtil.GetPFParticleVertex(*particle,evt,fPFParticleTag,fTrackerTag);
1098 
1099  if (fVerbose)
1100  std::cout << "#Start position of beam particle NO." << iiloop <<
1101  ": (" << vtx.X() << ", " << vtx.Y() << ", " << vtx.Z() <<
1102  ")" << std::endl;
1103 
1104  // add selection
1105  double fom = abs(vtx.Z() - 30); // figure of merit (to be compared to the cut value)
1106  if (fom < cut_v) {
1107  cut_v = fom;
1108  ii = iiloop;
1109  }
1110  ++iiloop;
1111  }
1112  // Get the reconstructed PFParticle tagged as beam by Pandora
1113  const recob::PFParticle* particle
1114  = ((fCheckSlicesForBeam && ii >= 0) ?
1115  beam_slices.at(ii).at(0) :
1116  beamParticles.at(0));
1117 
1118  //Get info from the PFP object identified as beam by pandora
1119  BeamPFPInfo(evt, particle, hitResults);
1120  //If MC, attempt to match to some MCParticle
1121  if( !evt.isRealData() ){
1122  BeamMatchInfo(evt, particle, true_beam_particle, clockData);
1123  }
1124 
1125 
1126  // Determine if the beam particle is track-like or shower-like
1127  const recob::Track* thisTrack = pfpUtil.GetPFParticleTrack(*particle,evt,fPFParticleTag,fTrackerTag);
1128  const recob::Shower* thisShower = pfpUtil.GetPFParticleShower(*particle,evt,fPFParticleTag,fShowerTag);
1129  if( thisTrack ){
1130  //Get reconstructed beam track info
1131  BeamTrackInfo(evt, thisTrack, clockData);
1132  }
1133  else if( thisShower ){
1134  //Get reconstructed beam shower info
1135  BeamShowerInfo(evt, thisShower);
1136  }
1137 
1138  //Get info from all PFPs associated as daughters to the primary particle
1139  DaughterPFPInfo(evt, particle, clockData, hitResults);
1140 
1141  //Gets info from forcing pandora to fit a track to the beam PFP regardless
1142  //of the BDT score
1143  BeamForcedTrackInfo(evt, particle);
1144  //To do: BeamForcedShowerInfo?
1145  }
1146 
1147 
1148  //If MC, attempt to match to some MCParticle
1149  if( !evt.isRealData() ){
1150  TrueBeamInfo(evt, true_beam_particle, clockData, plist, trueToPFPs, hitResults);
1151  }
1152 
1153 
1154  //New geant4reweight stuff
1155  //To do: put in its own function
1156  if (!evt.isRealData() && fDoReweight) {
1157  if (fVerbose) std::cout << "Doing reweight" << std::endl;
1158 
1159  //Doing reweighting if the primary is a piplus
1160  if (true_beam_PDG == 211) {
1161  std::vector<G4ReweightTraj *> trajs = CreateNRWTrajs(
1162  *true_beam_particle, plist,
1163  fGeometryService, event);
1164 
1165  bool added = false;
1166  for (size_t i = 0; i < trajs.size(); ++i) {
1167  if (trajs[i]->GetNSteps() > 0) {
1168  for (size_t j = 0; j < ParSet.size(); ++j) {
1169  std::pair<double, double> pm_weights =
1170  MultiRW->GetPlusMinusSigmaParWeight((*trajs[i]), j);
1171 
1172  if (!added) {
1173  g4rw_alt_primary_plus_sigma_weight.push_back(pm_weights.first);
1174  g4rw_alt_primary_minus_sigma_weight.push_back(pm_weights.second);
1175  }
1176  else {
1177  g4rw_alt_primary_plus_sigma_weight[j] *= pm_weights.first;
1178  g4rw_alt_primary_minus_sigma_weight[j] *= pm_weights.second;
1179  }
1180  }
1181  added = true;
1182  }
1183  }
1184 
1185  //Weighting according to the full heirarchy
1186  std::vector<std::vector<G4ReweightTraj *>> new_full_created
1187  = BuildHierarchy(true_beam_ID, 211, plist, fGeometryService,
1188  event, "LAr", false);
1189  if (fVerbose) {
1190  std::cout << "Created " << new_full_created.size() << " reweightable pi+"
1191  << std::endl;
1192  }
1193 
1194  bool new_added = false;
1195  for (size_t i = 0; i < new_full_created.size(); ++i) {
1196  std::vector<G4ReweightTraj *> temp_trajs = new_full_created[i];
1197  if (fVerbose) std::cout << i << " n trajs: " << temp_trajs.size() << std::endl;
1198  for (size_t j = 0; j < temp_trajs.size(); ++j) {
1199  G4ReweightTraj * this_traj = temp_trajs[j];
1200  if (this_traj->GetNSteps() > 0) {
1201  for (size_t k = 0; k < ParSet.size(); ++k) {
1202  std::pair<double, double> pm_weights =
1203  MultiRW->GetPlusMinusSigmaParWeight((*this_traj), k);
1204 
1205  if (!new_added) {
1206  g4rw_full_primary_plus_sigma_weight.push_back(pm_weights.first);
1207  g4rw_full_primary_minus_sigma_weight.push_back(pm_weights.second);
1208  }
1209  else {
1210  g4rw_full_primary_plus_sigma_weight[k] *= pm_weights.first;
1211  g4rw_full_primary_minus_sigma_weight[k] *= pm_weights.second;
1212  }
1213  }
1214  new_added = true;
1215  }
1216  }
1217  }
1218 
1219  G4RWGridWeights(new_full_created, ParSet, g4rw_full_grid_weights,
1220  MultiRW);
1221  for (auto weights : g4rw_full_grid_weights) {
1222  g4rw_full_grid_coeffs.push_back(std::vector<double>());
1223  GetG4RWCoeffs(weights, g4rw_full_grid_coeffs.back());
1224  }
1225  }
1226  }
1227 
1228  //New style of weighting to get full hierarchy (i.e. from full event not
1229  //just from the primary + downstreams) -- currently for piplus and proton
1230  if (!evt.isRealData() && fDoReweight) {
1231  std::vector<std::vector<G4ReweightTraj *>> piplus_hierarchy
1232  = BuildHierarchy(true_beam_ID, 211, plist, fGeometryService,
1233  event, "LAr", false);
1234 
1236  MultiRW);
1237  for (auto weights : g4rw_full_grid_piplus_weights) {
1238  g4rw_full_grid_piplus_coeffs.push_back(std::vector<double>());
1240  }
1241 
1242  std::vector<double> fake_data_input(FakeDataParSet.size(), 1.);
1243  for (size_t i = 0; i < FakeDataParSet.size(); ++i) {
1244  g4rw_full_grid_piplus_weights_fake_data.push_back(std::vector<double>());
1245  for (size_t j = 0; j < fGridPoints.size(); ++j) {
1246  fake_data_input[i] = fGridPoints[j];
1247  bool set_values = FakeDataMultiRW->SetAllParameterValues(fake_data_input);
1248 
1249  if (set_values) {
1250  //Full
1251  if (piplus_hierarchy.size()) {
1252  std::vector<G4ReweightTraj *> & init_trajs = piplus_hierarchy[0];
1253  g4rw_full_grid_piplus_weights_fake_data.back().push_back(
1255  for (size_t k = 1; k < piplus_hierarchy.size(); ++k) {
1256  std::vector<G4ReweightTraj *> & temp_trajs = piplus_hierarchy[k];
1258  *= GetNTrajWeightFromSetPars(temp_trajs, *FakeDataMultiRW);
1259  }
1260  }
1261  }
1262  else {
1263  std::string message = "Could not Get N Traj Weight from set pars";
1264  throw std::runtime_error(message);
1265  }
1266  }
1267 
1268  //Reset to 1.
1269  fake_data_input[i] = 1.;
1270  }
1271 
1272  std::vector<std::vector<G4ReweightTraj *>> proton_hierarchy
1273  = BuildHierarchy(true_beam_ID, 2212, plist, fGeometryService,
1274  event, "LAr", false);
1276  ProtMultiRW);
1277  for (auto weights : g4rw_full_grid_proton_weights) {
1278  g4rw_full_grid_proton_coeffs.push_back(std::vector<double>());
1280  }
1281 
1282  std::vector<std::vector<G4ReweightTraj *>> neutron_hierarchy
1283  = BuildHierarchy(true_beam_ID, 2112, plist, fGeometryService,
1284  event, "LAr", false);
1285  G4RWGridWeights(neutron_hierarchy, ProtParSet,
1287  for (auto weights : g4rw_full_grid_neutron_weights) {
1288  g4rw_full_grid_neutron_coeffs.push_back(std::vector<double>());
1290  }
1291 
1292  std::vector<std::vector<G4ReweightTraj *>> kplus_hierarchy
1293  = BuildHierarchy(true_beam_ID, 321, plist, fGeometryService,
1294  event, "LAr", false);
1296  ProtMultiRW);
1297  for (auto weights : g4rw_full_grid_kplus_weights) {
1298  g4rw_full_grid_kplus_coeffs.push_back(std::vector<double>());
1299  GetG4RWCoeffs(weights, g4rw_full_grid_kplus_coeffs.back());
1300  }
1301  }
1302 
1303  fTree->Fill();
1304 }
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
std::pair< double, double > GetVertexMichelScore_weight_by_charge(const recob::Track &track, const art::Event &evt, const std::string trackModule, const std::string hitModule, double min_length=5., double min_x=-200., double max_x=0., double min_y=200., double max_y=500., double min_z=25., bool check_wire=true, double check_x=0, double check_y=0., double check_z=0.)
std::vector< double > g4rw_full_primary_plus_sigma_weight
int PdgCode() const
Definition: MCParticle.h:212
bool IsBeamParticle(const recob::PFParticle &particle, art::Event const &evt, const std::string particleLabel) const
Use the pandora metadata to tell us if this is a beam particle or not.
unsigned int event
Definition: DataStructs.h:636
std::vector< double > beam_particle_scores
const simb::MCParticle * GetGeantGoodParticle(const simb::MCTruth &genTruth, const art::Event &evt) const
std::vector< double > reco_track_michel_score_weight_by_charge
std::vector< fhicl::ParameterSet > FakeDataParSet
unsigned int run
Definition: DataStructs.h:637
std::vector< double > g4rw_full_primary_minus_sigma_weight
const recob::Shower * GetPFParticleShower(const recob::PFParticle &particle, art::Event const &evt, const std::string particleLabel, const std::string showerLabel) const
Get the shower associated to this particle. Returns a null pointer if not found.
std::string string
Definition: nybbler.cc:12
std::vector< double > reco_track_startZ
std::vector< double > reco_track_startX
std::vector< fhicl::ParameterSet > ParSet
art::ServiceHandle< geo::Geometry > geom
std::vector< std::vector< double > > g4rw_full_grid_piplus_weights
protoana::ProtoDUNEEmptyEventFinder fEmptyEventFinder
const TVector3 GetPFParticleVertex(const recob::PFParticle &particle, art::Event const &evt, const std::string particleLabel, const std::string trackLabel) const
Function to find the interaction vertex of a primary PFParticle.
std::vector< double > reco_track_endX
double GetNTrajWeightFromSetPars(const std::vector< G4ReweightTraj * > &trajs, G4MultiReweighter &rw)
void TrueBeamInfo(const art::Event &evt, const simb::MCParticle *true_beam_particle, detinfo::DetectorClocksData const &clockData, const sim::ParticleList &plist, std::map< int, std::vector< int >> &trueToPFPs, anab::MVAReader< recob::Hit, 4 > *hitResults)
std::vector< double > reco_track_endZ
std::vector< std::vector< double > > g4rw_full_grid_coeffs
std::string Process() const
Definition: MCParticle.h:215
std::vector< double > g4rw_alt_primary_minus_sigma_weight
bool IsEmptyEvent(const art::Event &evt) const
std::vector< std::vector< double > > g4rw_full_grid_proton_weights
int TrackId() const
Definition: MCParticle.h:210
G4MultiReweighter * ProtMultiRW
std::pair< double, int > GetVertexMichelScore(const recob::Track &track, const art::Event &evt, const std::string trackModule, const std::string hitModule, double min_length=5., double min_x=-200., double max_x=0., double min_y=200., double max_y=500., double min_z=25., bool check_wire=true, double check_x=0, double check_y=0., double check_z=0.)
geo::TPCID FindTPCAtPosition(double const worldLoc[3]) const
Returns the ID of the TPC at specified location.
std::vector< fhicl::ParameterSet > ProtParSet
T abs(T value)
void GetG4RWCoeffs(std::vector< double > &weights, std::vector< double > &coeffs)
G4MultiReweighter * MultiRW
std::vector< std::vector< double > > g4rw_full_grid_proton_coeffs
std::vector< std::vector< double > > g4rw_full_grid_neutron_coeffs
std::map< int, std::vector< int > > GetMapMCToPFPs_ByHits(detinfo::DetectorClocksData const &clockData, const art::Event &evt, std::string pfpTag, std::string hitTag)
std::vector< double > reco_track_michel_score
Point_t const & Start() const
Access to track position at different points.
Definition: Track.h:123
std::vector< double > g4rw_alt_primary_plus_sigma_weight
std::vector< int > beam_track_IDs
const recob::Track * GetPFParticleTrack(const recob::PFParticle &particle, art::Event const &evt, const std::string particleLabel, const std::string trackLabel) const
Get the track associated to this particle. Returns a null pointer if not found.
std::vector< std::vector< double > > g4rw_full_grid_weights
std::vector< std::vector< double > > g4rw_full_grid_kplus_weights
std::vector< double > reco_track_endY
void BeamTrackInfo(const art::Event &evt, const recob::Track *thisTrack, detinfo::DetectorClocksData const &clockData)
p
Definition: test.py:223
const std::map< unsigned int, std::vector< const recob::PFParticle * > > GetPFParticleSliceMap(art::Event const &evt, const std::string particleLabel) const
Get a map of slice index to the primary PFParticles within it.
std::vector< int > reco_track_ID
const std::vector< const recob::PFParticle * > GetPFParticlesFromBeamSlice(art::Event const &evt, const std::string particleLabel) const
Return the pointers for the PFParticles in the beam slice. Returns an empty vector is no beam slice w...
std::vector< double > reco_track_startY
std::vector< std::vector< double > > g4rw_full_grid_piplus_weights_fake_data
const sim::ParticleList & ParticleList() const
art::ServiceHandle< cheat::ParticleInventoryService > pi_serv
WireGeo const & Wire(geo::WireID const &wireid) const
Returns the specified wire.
int ID() const
Definition: Track.h:198
protoana::ProtoDUNETruthUtils truthUtil
protoana::ProtoDUNETrackUtils trackUtil
std::vector< int > reco_track_nHits
Hierarchical representation of particle flow.
Definition: PFParticle.h:44
void BeamMatchInfo(const art::Event &evt, const recob::PFParticle *particle, const simb::MCParticle *true_beam_particle, detinfo::DetectorClocksData const &clockData)
void BeamInstInfo(const art::Event &evt)
std::vector< double > fGridPoints
protoana::ProtoDUNEPFParticleUtils pfpUtil
Point_t const & End() const
Definition: Track.h:125
unsigned int subRun
Definition: DataStructs.h:638
std::vector< std::vector< double > > g4rw_full_grid_neutron_weights
void BeamPFPInfo(const art::Event &evt, const recob::PFParticle *particle, anab::MVAReader< recob::Hit, 4 > *hitResults)
void GetCenter(double *xyz, double localz=0.0) const
Fills the world coordinate of a point on the wire.
Definition: WireGeo.cxx:73
TCEvent evt
Definition: DataStructs.cxx:7
G4MultiReweighter * FakeDataMultiRW
#define MF_LOG_WARNING(category)
TPCID_t TPC
Index of the TPC within its cryostat.
Definition: geo_types.h:406
void BeamShowerInfo(const art::Event &evt, const recob::Shower *thisShower)
std::vector< G4ReweightTraj * > CreateNRWTrajs(const simb::MCParticle &part, const sim::ParticleList &plist, art::ServiceHandle< geo::Geometry > geo_serv, int event, std::string material_name="LAr", bool fVerbose=false)
void G4RWGridWeights(std::vector< std::vector< G4ReweightTraj * >> &hierarchy, std::vector< fhicl::ParameterSet > &pars, std::vector< std::vector< double >> &weights, G4MultiReweighter *multi_rw)
std::vector< std::vector< double > > g4rw_full_grid_kplus_coeffs
float GetBeamCosmicScore(const recob::PFParticle &particle, art::Event const &evt, const std::string particleLabel) const
Access the BDT output used to decide if a slice is beam-like or cosmic-like.
std::vector< std::vector< double > > g4rw_full_grid_piplus_coeffs
Track from a non-cascading particle.A recob::Track consists of a recob::TrackTrajectory, plus additional members relevant for a "fitted" track:
Definition: Track.h:49
std::vector< std::vector< G4ReweightTraj * > > BuildHierarchy(int ID, int PDG, const sim::ParticleList &plist, art::ServiceHandle< geo::Geometry > geo_serv, int event, std::string material_name="LAr", bool fVerbose=false)
QTextStream & endl(QTextStream &s)
Event finding and building.
void DaughterPFPInfo(const art::Event &evt, const recob::PFParticle *particle, detinfo::DetectorClocksData const &clockData, anab::MVAReader< recob::Hit, 4 > *hitResults)
void pduneana::PDSPAnalyzer::BeamForcedTrackInfo ( const art::Event evt,
const recob::PFParticle particle 
)
private

Definition at line 4458 of file PDSPAnalyzer_module.cc.

4459  {
4460  try{
4461  const recob::Track* pandora2Track = pfpUtil.GetPFParticleTrack( *particle, evt, fPFParticleTag, "pandora2Track" );
4462  if (fVerbose) std::cout << "pandora2 track: " << pandora2Track << std::endl;
4463 
4464  if( pandora2Track ){
4465  // michle score
4466  if (!fSkipMVA) {
4467  std::pair<double, int> vertex_michel_score = trackUtil.GetVertexMichelScore(*pandora2Track, evt, "pandora2Track", fHitTag);
4468  reco_beam_vertex_nHits_allTrack = vertex_michel_score.second;
4469  reco_beam_vertex_michel_score_allTrack = vertex_michel_score.first;
4470 
4471  std::pair<double, double> vertex_michel_score_weight_by_charge =
4472  trackUtil.GetVertexMichelScore_weight_by_charge(*pandora2Track, evt, "pandora2Track", fHitTag);
4473  if (vertex_michel_score_weight_by_charge.second != 0)
4474  reco_beam_vertex_michel_score_weight_by_charge_allTrack = vertex_michel_score_weight_by_charge.first/vertex_michel_score_weight_by_charge.second;
4475  else
4477  }
4478  reco_beam_allTrack_ID = pandora2Track->ID();
4479  reco_beam_allTrack_beam_cuts = beam_cuts.IsBeamlike( *pandora2Track, evt, "1" );
4480  reco_beam_allTrack_startX = pandora2Track->Trajectory().Start().X();
4481  reco_beam_allTrack_startY = pandora2Track->Trajectory().Start().Y();
4482  reco_beam_allTrack_startZ = pandora2Track->Trajectory().Start().Z();
4483  reco_beam_allTrack_endX = pandora2Track->Trajectory().End().X();
4484  reco_beam_allTrack_endY = pandora2Track->Trajectory().End().Y();
4485  reco_beam_allTrack_endZ = pandora2Track->Trajectory().End().Z();
4486 
4487  auto startDir = pandora2Track->StartDirection();
4488  auto endDir = pandora2Track->EndDirection();
4489 
4490  //try flipping
4493  reco_beam_allTrack_endX = pandora2Track->Trajectory().Start().X();
4494  reco_beam_allTrack_endY = pandora2Track->Trajectory().Start().Y();
4495  reco_beam_allTrack_endZ = pandora2Track->Trajectory().Start().Z();
4496  reco_beam_allTrack_startX = pandora2Track->Trajectory().End().X();
4497  reco_beam_allTrack_startY = pandora2Track->Trajectory().End().Y();
4498  reco_beam_allTrack_startZ = pandora2Track->Trajectory().End().Z();
4499 
4500  reco_beam_allTrack_trackDirX = -1. * endDir.X();
4501  reco_beam_allTrack_trackDirY = -1. * endDir.Y();
4502  reco_beam_allTrack_trackDirZ = -1. * endDir.Z();
4503 
4504  reco_beam_allTrack_trackEndDirX = -1. * startDir.X();
4505  reco_beam_allTrack_trackEndDirY = -1. * startDir.Y();
4506  reco_beam_allTrack_trackEndDirZ = -1. * startDir.Z();
4507  }
4508  else{
4510  reco_beam_allTrack_trackDirX = startDir.X();
4511  reco_beam_allTrack_trackDirY = startDir.Y();
4512  reco_beam_allTrack_trackDirZ = startDir.Z();
4513  reco_beam_allTrack_trackEndDirX = endDir.X();
4514  reco_beam_allTrack_trackEndDirY = endDir.Y();
4515  reco_beam_allTrack_trackEndDirZ = endDir.Z();
4516  }
4517 
4518  reco_beam_allTrack_len = pandora2Track->Length();
4519 
4520  auto allHits = evt.getValidHandle<std::vector<recob::Hit> >(fHitTag);
4521  auto calo = trackUtil.GetRecoTrackCalorimetry(*pandora2Track, evt, "pandora2Track", fPandora2CaloSCE);
4522  size_t index = 0;
4523  bool found_plane = false;
4524  for (index = 0; index < calo.size(); ++index) {
4525  if (calo[index].PlaneID().Plane == 2) {
4526  found_plane = true;
4527  break;
4528  }
4529  }
4530 
4531  if (found_plane) {
4532  reco_beam_alt_len_allTrack = calo[index].Range();
4533  auto calo_range = calo[index].ResidualRange();
4534  auto calo_dEdX = calo[index].dEdx();
4535  auto calo_dQdX = calo[index].dQdx();
4536  auto TpIndices = calo[index].TpIndices();
4537 
4538  for( size_t i = 0; i < calo_range.size(); ++i ){
4539  reco_beam_allTrack_resRange.push_back( calo_range[i] );
4540  //reco_beam_dQdX_SCE_allTrack.push_back( calo_dQdX[i] );
4541  //reco_beam_dEdX_SCE_allTrack.push_back( calo_dEdX[i] );
4542  reco_beam_TrkPitch_SCE_allTrack.push_back( calo[index].TrkPitchVec()[i] );
4543  }
4544 
4545  auto theXYZPoints = calo[index].XYZ();
4546  for( size_t i = 0; i < calo_dQdX.size(); ++i ){
4547  const recob::Hit & theHit = (*allHits)[ TpIndices[i] ];
4548  //reco_beam_dQ_allTrack.push_back(theHit.Integral());
4549  //reco_beam_calo_TPC_allTrack.push_back(theHit.WireID().TPC);
4550  if (theHit.WireID().TPC == 1) {
4551  reco_beam_calo_wire_allTrack.push_back( theHit.WireID().Wire );
4552  }
4553  else if (theHit.WireID().TPC == 5) {
4554  reco_beam_calo_wire_allTrack.push_back( theHit.WireID().Wire + 479);
4555  }
4556  //Need other TPCs?
4557  else {
4558  reco_beam_calo_wire_allTrack.push_back(theHit.WireID().Wire );
4559  }
4560  //reco_beam_calo_tick_allTrack.push_back( theHit.PeakTime() );
4561  //calo_hit_indices_allTrack.push_back( TpIndices[i] );
4562  //reco_beam_calo_wire_z_allTrack.push_back(geom->Wire(theHit.WireID()).GetCenter().Z());
4563 
4564  reco_beam_calo_X_allTrack.push_back(theXYZPoints[i].X());
4565  reco_beam_calo_Y_allTrack.push_back(theXYZPoints[i].Y());
4566  reco_beam_calo_Z_allTrack.push_back(theXYZPoints[i].Z());
4567  }
4568 
4569  //Getting the SCE corrected start/end positions & directions
4570  std::sort(theXYZPoints.begin(), theXYZPoints.end(), [](auto a, auto b)
4571  {return (a.Z() < b.Z());});
4572  if (theXYZPoints.size()) {
4573  reco_beam_calo_startX_allTrack = theXYZPoints[0].X();
4574  reco_beam_calo_startY_allTrack = theXYZPoints[0].Y();
4575  reco_beam_calo_startZ_allTrack = theXYZPoints[0].Z();
4576  reco_beam_calo_endX_allTrack = theXYZPoints.back().X();
4577  reco_beam_calo_endY_allTrack = theXYZPoints.back().Y();
4578  reco_beam_calo_endZ_allTrack = theXYZPoints.back().Z();
4579  }
4580 
4581  //New Calibration
4582  if (fRecalibrate){
4583  std::vector< float > new_dEdX = calibration_SCE.GetCalibratedCalorimetry( *pandora2Track, evt, "pandora2Track", fPandora2CaloSCE, 2);
4584  for( size_t i = 0; i < new_dEdX.size(); ++i ) {
4585  reco_beam_allTrack_calibrated_dEdX.push_back( new_dEdX[i] );
4586  }
4587  /*std::vector<double> new_dQdX = calibration_SCE.CalibratedQdX( *pandora2Track, evt, "pandora2Track", fCalorimetryTagSCE, 2, -10.);
4588  for (auto dqdx : new_dQdX) reco_beam_calibrated_dQdX_SCE_allTrack.push_back(dqdx);*/
4589 
4590  /*std::vector<double> efield = calibration_SCE.GetEFieldVector( *pandora2Track, evt, "pandora2Track", fCalorimetryTagSCE, 2, -10.);
4591  for (auto ef : efield) reco_beam_EField_SCE_allTrack.push_back(ef);*/
4592  }
4593  else{
4594  for (size_t i = 0; i < calo_dEdX.size(); ++i){
4595  reco_beam_allTrack_calibrated_dEdX.push_back(calo_dEdX[i]);
4596  //reco_beam_calibrated_dQdX_SCE_allTrack.push_back(calo_dQdX[i]);
4597 
4598  /*double E_field_nominal = detProp.Efield(); // Electric Field in the drift region in KV/cm
4599  geo::Vector_t E_field_offsets = {0., 0., 0.};
4600  if(sce->EnableCalEfieldSCE()&&fSCE) E_field_offsets = sce->GetCalEfieldOffsets(geo::Point_t{theXYZPoints[i].X(), theXYZPoints[i].Y(), theXYZPoints[i].Z()},calo[index].PlaneID().TPC);
4601  TVector3 E_field_vector = {E_field_nominal*(1 + E_field_offsets.X()), E_field_nominal*E_field_offsets.Y(), E_field_nominal*E_field_offsets.Z()};
4602  double E_field = E_field_vector.Mag();
4603  reco_beam_EField_SCE.push_back(E_field);*/
4604  }
4605  }
4606  double efield_placeholder = 1.;
4607  ////////////////////////////////////////////
4608 
4609  std::pair< double, int > pid_chi2_ndof = trackUtil.Chi2PID( reco_beam_allTrack_calibrated_dEdX, reco_beam_allTrack_resRange, templates[ 2212 ] );
4610  reco_beam_allTrack_Chi2_proton = pid_chi2_ndof.first;
4611  reco_beam_allTrack_Chi2_ndof = pid_chi2_ndof.second;
4612 
4613  std::vector< calo_point > reco_beam_calo_points;
4614  //Doing thin slice
4618 
4619  for( size_t i = 0; i < reco_beam_allTrack_calibrated_dEdX.size(); ++i ){
4620  reco_beam_calo_points.push_back(
4621  calo_point(reco_beam_calo_wire_allTrack[i], 1.,
4623  1., 1.,
4624  1.,
4625  1.,
4628  1., 0,
4629  efield_placeholder, reco_beam_calo_X_allTrack[i],
4631  }
4632 
4633  //std::cout << "N Calo points: " << reco_beam_calo_points.size() << std::endl;
4634  //Sort
4635  std::sort( reco_beam_calo_points.begin(), reco_beam_calo_points.end(), [](calo_point a, calo_point b) {return ( a.z < b.z );} );
4636 
4637  //And also put these in the right order
4638  for( size_t i = 0; i < reco_beam_calo_points.size(); ++i ){
4639  calo_point thePoint = reco_beam_calo_points[i];
4640  reco_beam_calo_wire_allTrack[i] = thePoint.wire;
4641  reco_beam_TrkPitch_SCE_allTrack[i] = thePoint.pitch;
4642  reco_beam_allTrack_calibrated_dEdX[i] = thePoint.calibrated_dEdX;
4643  reco_beam_allTrack_resRange[i] = thePoint.res_range;
4644  reco_beam_calo_X_allTrack[i] = thePoint.x;
4645  reco_beam_calo_Y_allTrack[i] = thePoint.y;
4646  reco_beam_calo_Z_allTrack[i] = thePoint.z;
4647  }
4648 
4649  //Get the initial Energy KE
4650  //double mass = 0.;
4651  double init_KE = 0.;
4652  //std::cout << "Has BI? " << fMCHasBI << " " << evt.isRealData() << std::endl;
4653  if (evt.isRealData() || fMCHasBI) {
4654  double mass = 139.57;
4655 
4656  init_KE = sqrt( 1.e6*beam_inst_P*beam_inst_P + mass*mass ) - mass;
4657  // std::cout << "MC has BI: " << init_KE << std::endl;
4658  }
4659  else{
4661  }
4662 
4663  reco_beam_incidentEnergies_allTrack.push_back( init_KE );
4664  for( size_t i = 0; i < reco_beam_calo_points.size() - 1; ++i ){ //-1 to not count the last slice
4665  //use dedx * pitch or new hit calculation?
4666  if (reco_beam_calo_points[i].calibrated_dEdX < 0.) continue;
4667  double this_energy = reco_beam_incidentEnergies_allTrack.back() - ( reco_beam_calo_points[i].calibrated_dEdX * reco_beam_calo_points[i].pitch );
4668  reco_beam_incidentEnergies_allTrack.push_back( this_energy );
4669  }
4671  }
4672 
4673  }
4674  else{
4677  }
4678  }
4679  else{
4680  reco_beam_allTrack_ID = -999;
4685  reco_beam_allTrack_endX = -999;
4686  reco_beam_allTrack_endY = -999;
4687  reco_beam_allTrack_endZ = -999;
4696 
4697  }
4698  }
4699  catch( const cet::exception &e ){
4700  MF_LOG_WARNING("PDSPAnalyzer") << "beam pandora2Track object not found, moving on" << std::endl;
4701  }
4702 }
std::pair< double, double > GetVertexMichelScore_weight_by_charge(const recob::Track &track, const art::Event &evt, const std::string trackModule, const std::string hitModule, double min_length=5., double min_x=-200., double max_x=0., double min_y=200., double max_y=500., double min_z=25., bool check_wire=true, double check_x=0, double check_y=0., double check_z=0.)
protoana::ProtoDUNEBeamCuts beam_cuts
std::vector< double > reco_beam_calo_Z_allTrack
std::vector< double > reco_beam_calo_Y_allTrack
geo::WireID WireID() const
Definition: Hit.h:233
const recob::TrackTrajectory & Trajectory() const
Access to the stored recob::TrackTrajectory.
Definition: Track.h:98
std::vector< anab::Calorimetry > GetRecoTrackCalorimetry(const recob::Track &track, art::Event const &evt, const std::string trackModule, const std::string caloModule) const
Get the Calorimetry(s) from a given reco track.
std::vector< double > reco_beam_allTrack_calibrated_dEdX
WireID_t Wire
Index of the wire within its plane.
Definition: geo_types.h:580
std::vector< double > reco_beam_calo_X_allTrack
std::vector< double > reco_beam_incidentEnergies_allTrack
double reco_beam_vertex_michel_score_weight_by_charge_allTrack
bool IsBeamlike(const recob::Track &, const art::Event &, std::string)
std::vector< double > reco_beam_TrkPitch_SCE_allTrack
std::pair< double, int > GetVertexMichelScore(const recob::Track &track, const art::Event &evt, const std::string trackModule, const std::string hitModule, double min_length=5., double min_x=-200., double max_x=0., double min_y=200., double max_y=500., double min_z=25., bool check_wire=true, double check_x=0, double check_y=0., double check_z=0.)
bool isRealData() const
Vector_t StartDirection() const
Access to track direction at different points.
Definition: Track.h:131
const double e
double Length(size_t p=0) const
Access to various track properties.
Definition: Track.h:167
std::vector< double > reco_beam_allTrack_resRange
const double a
const recob::Track * GetPFParticleTrack(const recob::PFParticle &particle, art::Event const &evt, const std::string particleLabel, const std::string trackLabel) const
Get the track associated to this particle. Returns a null pointer if not found.
ValidHandle< PROD > getValidHandle(InputTag const &tag) const
Definition: DataViewImpl.h:441
std::map< int, TProfile * > templates
protoana::ProtoDUNECalibration calibration_SCE
std::vector< double > reco_beam_calo_wire_allTrack
std::pair< double, int > Chi2PID(const std::vector< double > &track_dedx, const std::vector< double > &range, TProfile *profile)
int ID() const
Definition: Track.h:198
protoana::ProtoDUNETrackUtils trackUtil
Vector_t EndDirection() const
Definition: Track.h:133
protoana::ProtoDUNEPFParticleUtils pfpUtil
Point_t const & End() const
Returns the position of the last valid point of the trajectory [cm].
static bool * b
Definition: config.cpp:1043
detail::Node< FrameID, bool > PlaneID
Definition: CRTID.h:125
2D representation of charge deposited in the TDC/wire plane
Definition: Hit.h:48
#define MF_LOG_WARNING(category)
TPCID_t TPC
Index of the TPC within its cryostat.
Definition: geo_types.h:406
std::vector< float > GetCalibratedCalorimetry(const recob::Track &track, art::Event const &evt, const std::string trackModule, const std::string caloModule, size_t planeID, double negativeZFix=0.)
Point_t const & Start() const
Returns the position of the first valid point of the trajectory [cm].
Track from a non-cascading particle.A recob::Track consists of a recob::TrackTrajectory, plus additional members relevant for a "fitted" track:
Definition: Track.h:49
calorimetry
cet::coded_exception< error, detail::translate > exception
Definition: exception.h:33
QTextStream & endl(QTextStream &s)
void pduneana::PDSPAnalyzer::BeamForcedTrackInfo ( )
private
void pduneana::PDSPAnalyzer::BeamInstInfo ( const art::Event evt)
private

Definition at line 3579 of file PDSPAnalyzer_module.cc.

3579  {
3580  std::vector<art::Ptr<beam::ProtoDUNEBeamEvent>> beamVec;
3581 
3582  //Get beam instrumentation info
3583  //Works for both MC and data, can probably merge these (To do)
3584  if (evt.isRealData()) {
3585  auto beamHandle
3586  = evt.getValidHandle<std::vector<beam::ProtoDUNEBeamEvent>>(
3588 
3589  if (beamHandle.isValid()) {
3590  art::fill_ptr_vector(beamVec, beamHandle);
3591  }
3592  }
3593  else {
3594  try {
3595  auto beamHandle
3596  = evt.getValidHandle<std::vector<beam::ProtoDUNEBeamEvent>>(
3597  "generator");
3598 
3599  if( beamHandle.isValid()){
3600  art::fill_ptr_vector(beamVec, beamHandle);
3601  }
3602  fMCHasBI = true;
3603  }
3604  catch (const cet::exception &e) {
3605  MF_LOG_WARNING("PDSPAnalyzer") << "BeamEvent generator object not " <<
3606  "found, moving on" << std::endl;
3607  fMCHasBI = false;
3608  return;
3609  }
3610  }
3611 
3612  //High level info about the beam trigger
3613  const beam::ProtoDUNEBeamEvent & beamEvent = *(beamVec.at(0));
3614  beam_inst_trigger = beamEvent.GetTimingTrigger();
3615  if (evt.isRealData() && !fBeamlineUtils.IsGoodBeamlineTrigger(evt)) {
3616  std::cout << "Matched? " << beamEvent.CheckIsMatched() << std::endl;
3617  std::vector< double > momenta = beamEvent.GetRecoBeamMomenta();
3618  std::cout << momenta.size() << std::endl;
3619  MF_LOG_WARNING("PDSPAnalyzer") << "Failed beam quality check" << std::endl;
3620  beam_inst_valid = false;
3621  return;
3622  }
3623 
3624  //Number of tracks reconstructed in the final four fiber monitors
3625  int nTracks = beamEvent.GetBeamTracks().size();
3626 
3627  //Momentum reconstructed from spectrometer
3628  std::vector< double > momenta = beamEvent.GetRecoBeamMomenta();
3629  int nMomenta = momenta.size();
3630 
3631  if (fVerbose) {
3632  std::cout << "Got beam event" << std::endl;
3633  std::cout << "Got " << nTracks << " Tracks" << std::endl;
3634  std::cout << "Got " << nMomenta << " Momenta" << std::endl;
3635  }
3636 
3637  if( nMomenta > 0 ){
3638  beam_inst_P = momenta[0];
3639  if (fVerbose) std::cout << "reco P " << beam_inst_P << std::endl;
3640  }
3641 
3642  //Time of flight + channel combinations
3643  const std::vector<double> the_tofs = beamEvent.GetTOFs();
3644  const std::vector<int> the_chans = beamEvent.GetTOFChans();
3645  for (size_t iTOF = 0; iTOF < the_tofs.size(); ++iTOF) {
3646  beam_inst_TOF.push_back(the_tofs[iTOF]);
3647  beam_inst_TOF_Chan.push_back(the_chans[iTOF]);
3648  }
3649 
3650  beam_inst_C0 = beamEvent.GetCKov0Status();
3651  beam_inst_C1 = beamEvent.GetCKov1Status();
3654 
3655  //position from the projected track into the TPC -- just using the first
3656  //index
3657  if( nTracks > 0 ){
3658  beam_inst_X = beamEvent.GetBeamTracks()[0].Trajectory().End().X();
3659  beam_inst_Y = beamEvent.GetBeamTracks()[0].Trajectory().End().Y();
3660  beam_inst_Z = beamEvent.GetBeamTracks()[0].Trajectory().End().Z();
3661 
3662  beam_inst_dirX = beamEvent.GetBeamTracks()[0].Trajectory().EndDirection().X();
3663  beam_inst_dirY = beamEvent.GetBeamTracks()[0].Trajectory().EndDirection().Y();
3664  beam_inst_dirZ = beamEvent.GetBeamTracks()[0].Trajectory().EndDirection().Z();
3665  }
3666 
3667  beam_inst_nTracks = nTracks;
3668  beam_inst_nMomenta = nMomenta;
3669 
3670  //beamline PID
3671  if (evt.isRealData()) {
3672  std::vector< int > pdg_cands = fBeamlineUtils.GetPID( beamEvent, fBeamPIDMomentum );
3673  beam_inst_PDG_candidates.insert( beam_inst_PDG_candidates.end(), pdg_cands.begin(), pdg_cands.end() );
3674  }
3675 
3676  //number of fibers struck in the spectrometer monitors
3677  beam_inst_nFibersP1 = beamEvent.GetActiveFibers( "XBPF022697" ).size();
3678  beam_inst_nFibersP2 = beamEvent.GetActiveFibers( "XBPF022701" ).size();
3679  beam_inst_nFibersP3 = beamEvent.GetActiveFibers( "XBPF022702" ).size();
3680 }
std::vector< int > beam_inst_TOF_Chan
const int & GetTimingTrigger() const
const std::vector< double > & GetTOFs() const
std::vector< int > beam_inst_PDG_candidates
const double & GetCKov0Pressure() const
const short & GetCKov1Status() const
bool isRealData() const
const double e
const std::vector< short > & GetActiveFibers(std::string) const
const std::vector< double > & GetRecoBeamMomenta() const
ValidHandle< PROD > getValidHandle(InputTag const &tag) const
Definition: DataViewImpl.h:441
bool IsGoodBeamlineTrigger(art::Event const &evt) const
protoana::ProtoDUNEBeamlineUtils fBeamlineUtils
std::vector< int > GetPID(beam::ProtoDUNEBeamEvent const &beamevt, double nominal_momentum)
const std::vector< int > & GetTOFChans() const
const std::vector< recob::Track > & GetBeamTracks() const
const short & GetCKov0Status() const
std::vector< double > beam_inst_TOF
#define MF_LOG_WARNING(category)
void fill_ptr_vector(std::vector< Ptr< T >> &ptrs, H const &h)
Definition: Ptr.h:297
const bool & CheckIsMatched() const
cet::coded_exception< error, detail::translate > exception
Definition: exception.h:33
QTextStream & endl(QTextStream &s)
const double & GetCKov1Pressure() const
void pduneana::PDSPAnalyzer::BeamMatchInfo ( const art::Event evt,
const recob::PFParticle particle,
const simb::MCParticle true_beam_particle,
detinfo::DetectorClocksData const &  clockData 
)
private

Definition at line 4261 of file PDSPAnalyzer_module.cc.

4264  {
4265  protoana::MCParticleSharedHits beam_match = truthUtil.GetMCParticleByHits( clockData, *particle, evt, fPFParticleTag, fHitTag );
4266  if( beam_match.particle ){
4267  reco_beam_true_byHits_matched = ( beam_match.particle->TrackId() == true_beam_particle->TrackId() );
4268  reco_beam_true_byHits_PDG = beam_match.particle->PdgCode();
4269  reco_beam_true_byHits_ID = beam_match.particle->TrackId();
4270 
4274 
4275  reco_beam_true_byHits_startPx = beam_match.particle->Px();
4276  reco_beam_true_byHits_startPy = beam_match.particle->Py();
4277  reco_beam_true_byHits_startPz = beam_match.particle->Pz();
4281  reco_beam_true_byHits_startE = beam_match.particle->E();
4282 
4283  size_t np = beam_match.particle->NumberTrajectoryPoints();
4284  if( np > 1 ){
4285  reco_beam_true_byHits_endPx = beam_match.particle->Px( np - 2 );
4286  reco_beam_true_byHits_endPy = beam_match.particle->Py( np - 2 );
4287  reco_beam_true_byHits_endPz = beam_match.particle->Pz( np - 2 );
4291  reco_beam_true_byHits_endE = beam_match.particle->E( np - 2 );
4292  }
4293 
4294  auto list = truthUtil.GetMCParticleListByHits( clockData, *particle, evt, fPFParticleTag, fHitTag );
4295  double total = 0.;
4296  double matched_hits = 0.;
4297  for( size_t j = 0; j < list.size(); ++j ){
4298  // std::cout << "Contrib " << j << " " << list[j].first->TrackId() << " " << list[j].second << std::endl;
4299  //std::cout << "Contrib " << j << " " << list[j].particle->TrackId() << " " << list[j].particle->PdgCode()
4300  // << " " << pi_serv->TrackIdToMCTruth_P(list[j].particle->TrackId())->Origin()
4301  // << " " << list[j].nSharedHits << " " << list[j].nSharedDeltaRayHits << std::endl;
4302 
4303  if( list[j].particle == beam_match.particle ){
4304  matched_hits = list[j].nSharedHits + list[j].nSharedDeltaRayHits;
4305  }
4306 
4307  total += list[j].nSharedHits + list[j].nSharedDeltaRayHits;
4308  }
4309 
4310  reco_beam_true_byHits_purity = ( matched_hits / total );
4311 
4312  }
4313 
4314  const simb::MCParticle* trueParticle = 0x0;
4315  trueParticle = truthUtil.GetMCParticleFromPFParticle(clockData, *particle, evt, fPFParticleTag);
4316  if( trueParticle ){
4317 
4318  //Check that this is the correct true particle
4319  if( trueParticle->TrackId() == true_beam_particle->TrackId() ){
4321  }
4322 
4323  reco_beam_true_byE_PDG = trueParticle->PdgCode();
4324  reco_beam_true_byE_ID = trueParticle->TrackId();
4325 
4326  reco_beam_true_byE_process = trueParticle->Process();
4327  reco_beam_true_byE_endProcess = trueParticle->EndProcess();
4328  reco_beam_true_byE_origin = pi_serv->TrackIdToMCTruth_P(trueParticle->TrackId())->Origin();
4329 
4330  reco_beam_true_byE_startPx = trueParticle->Px();
4331  reco_beam_true_byE_startPy = trueParticle->Py();
4332  reco_beam_true_byE_startPz = trueParticle->Pz();
4336  reco_beam_true_byE_startE = trueParticle->E();
4337 
4338  size_t np = trueParticle->NumberTrajectoryPoints();
4339  if( np > 1 ){
4340  reco_beam_true_byE_endPx = trueParticle->Px( np - 2 );
4341  reco_beam_true_byE_endPy = trueParticle->Py( np - 2 );
4342  reco_beam_true_byE_endPz = trueParticle->Pz( np - 2 );
4346  reco_beam_true_byE_endE = trueParticle->E( np - 2 );
4347  }
4348 
4349  }
4350 }
double E(const int i=0) const
Definition: MCParticle.h:233
unsigned int NumberTrajectoryPoints() const
Definition: MCParticle.h:218
int PdgCode() const
Definition: MCParticle.h:212
std::string reco_beam_true_byE_endProcess
double Py(const int i=0) const
Definition: MCParticle.h:231
double Px(const int i=0) const
Definition: MCParticle.h:230
const MCParticleSharedHits GetMCParticleByHits(detinfo::DetectorClocksData const &clockData, const T &recobj, const art::Event &evt, std::string recoModule, std::string hitModule) const
std::string Process() const
Definition: MCParticle.h:215
std::string reco_beam_true_byHits_endProcess
int TrackId() const
Definition: MCParticle.h:210
std::vector< MCParticleSharedHits > GetMCParticleListByHits(detinfo::DetectorClocksData const &clockData, const T &recobj, const art::Event &evt, std::string recoModule, std::string hitModule) const
std::string EndProcess() const
Definition: MCParticle.h:216
const art::Ptr< simb::MCTruth > & TrackIdToMCTruth_P(int id) const
const simb::MCParticle * GetMCParticleFromPFParticle(detinfo::DetectorClocksData const &clockData, const recob::PFParticle &pfpart, art::Event const &evt, std::string pfparticleModule) const
art::ServiceHandle< cheat::ParticleInventoryService > pi_serv
protoana::ProtoDUNETruthUtils truthUtil
const simb::MCParticle * particle
double Pz(const int i=0) const
Definition: MCParticle.h:232
std::string reco_beam_true_byHits_process
void pduneana::PDSPAnalyzer::BeamPFPInfo ( const art::Event evt,
const recob::PFParticle particle,
anab::MVAReader< recob::Hit, 4 > *  hitResults 
)
private

Definition at line 2363 of file PDSPAnalyzer_module.cc.

2365  {
2366 
2367  //Get CNN output for the beam
2368  reco_beam_PFP_ID = particle->Self();
2369  const std::vector< art::Ptr< recob::Hit > > beamPFP_hits = pfpUtil.GetPFParticleHits_Ptrs( *particle, evt, fPFParticleTag );
2370  reco_beam_PFP_nHits = beamPFP_hits.size();
2371  if (!fSkipMVA) {
2372  cnnOutput2D cnn = GetCNNOutputFromPFParticle( *particle, evt, *hitResults, pfpUtil, fPFParticleTag );
2373  reco_beam_PFP_trackScore = (cnn.nHits > 0 ?
2374  (cnn.track / cnn.nHits) : -999.);
2375  reco_beam_PFP_emScore = (cnn.nHits > 0 ?
2376  (cnn.em / cnn.nHits) : -999.);
2377  reco_beam_PFP_michelScore = (cnn.nHits > 0 ?
2378  (cnn.michel / cnn.nHits) : -999.);
2379  reco_beam_PFP_trackScore_weight_by_charge = cnn.track_weight_by_charge;
2380  reco_beam_PFP_emScore_weight_by_charge = cnn.em_weight_by_charge;
2381  reco_beam_PFP_michelScore_weight_by_charge = cnn.michel_weight_by_charge;
2382 
2383  cnnOutput2D cnn_collection = GetCNNOutputFromPFParticleFromPlane( *particle, evt, *hitResults, pfpUtil, fPFParticleTag, 2 );
2384  reco_beam_PFP_trackScore_collection = (cnn_collection.nHits > 0 ?
2385  cnn_collection.track / cnn_collection.nHits : -999.);
2386  reco_beam_PFP_emScore_collection = (cnn_collection.nHits > 0 ?
2387  cnn_collection.em / cnn_collection.nHits : -999.);
2388  reco_beam_PFP_michelScore_collection = (cnn_collection.nHits > 0 ?
2389  cnn_collection.michel / cnn_collection.nHits : -999.);
2390  reco_beam_PFP_trackScore_collection_weight_by_charge = cnn_collection.track_weight_by_charge;
2391  reco_beam_PFP_emScore_collection_weight_by_charge = cnn_collection.em_weight_by_charge;
2392  reco_beam_PFP_michelScore_collection_weight_by_charge = cnn_collection.michel_weight_by_charge;
2393 
2394  }
2395 
2396 }
double reco_beam_PFP_trackScore_collection_weight_by_charge
size_t Self() const
Returns the index of this particle.
Definition: PFParticle.h:92
double reco_beam_PFP_emScore_collection_weight_by_charge
cnnOutput2D GetCNNOutputFromPFParticle(const recob::PFParticle &part, const art::Event &evt, const anab::MVAReader< recob::Hit, 4 > &CNN_results, protoana::ProtoDUNEPFParticleUtils &pfpUtil, std::string fPFParticleTag)
Defines an enumeration for cellhit classification.
protoana::ProtoDUNEPFParticleUtils pfpUtil
double reco_beam_PFP_michelScore_collection_weight_by_charge
const std::vector< art::Ptr< recob::Hit > > GetPFParticleHits_Ptrs(const recob::PFParticle &particle, art::Event const &evt, const std::string particleLabel) const
cnnOutput2D GetCNNOutputFromPFParticleFromPlane(const recob::PFParticle &part, const art::Event &evt, const anab::MVAReader< recob::Hit, 4 > &CNN_results, protoana::ProtoDUNEPFParticleUtils &pfpUtil, std::string fPFParticleTag, size_t planeID)
void pduneana::PDSPAnalyzer::BeamShowerInfo ( const art::Event evt,
const recob::Shower thisShower 
)
private

Definition at line 2961 of file PDSPAnalyzer_module.cc.

2961  {
2962  reco_beam_type = 11;
2963  reco_beam_trackID = thisShower->ID();
2964  reco_beam_startX = thisShower->ShowerStart().X();
2965  reco_beam_startY = thisShower->ShowerStart().Y();
2966  reco_beam_startZ = thisShower->ShowerStart().Z();
2967  reco_beam_trackDirX = thisShower->Direction().X();
2968  reco_beam_trackDirY = thisShower->Direction().Y();
2969  reco_beam_trackDirZ = thisShower->Direction().Z();
2970 
2971  auto allHits = evt.getValidHandle<std::vector<recob::Hit> >(fHitTag);
2972  auto calo = showerUtil.GetRecoShowerCalorimetry(*thisShower, evt, fShowerTag, "pandoraShowercalo");
2973  bool found_calo = false;
2974  size_t index = 0;
2975  for ( index = 0; index < calo.size(); ++index) {
2976  if (calo[index].PlaneID().Plane == 2) {
2977  found_calo = true;
2978  break;
2979  }
2980  }
2981  if (found_calo) {
2982  auto TpIndices = calo[index].TpIndices();
2983  for( size_t i = 0; i < TpIndices.size(); ++i ){
2984  const recob::Hit & theHit = (*allHits)[ TpIndices[i] ];
2985  reco_beam_calo_TPC.push_back(theHit.WireID().TPC);
2986  if (theHit.WireID().TPC == 1) {
2987  reco_beam_calo_wire.push_back( theHit.WireID().Wire );
2988  }
2989  else if (theHit.WireID().TPC == 5) {
2990  reco_beam_calo_wire.push_back( theHit.WireID().Wire + 479);
2991  }
2992  //Need other TPCs?
2993  else {
2994  reco_beam_calo_wire.push_back(theHit.WireID().Wire );
2995  }
2996 
2997  reco_beam_calo_tick.push_back( theHit.PeakTime() );
2998  }
2999  }
3000 
3001  if (fVerbose) {
3002  std::cout << "Beam particle is shower-like" << std::endl;
3003  std::cout << thisShower->ShowerStart().X() << " " << thisShower->ShowerStart().Y() << " " << thisShower->ShowerStart().Z() << std::endl;
3004  std::cout << thisShower->Direction().X() << " " << thisShower->Direction().Y() << " " << thisShower->Direction().Z() << std::endl;
3005  }
3006 }
const TVector3 & ShowerStart() const
Definition: Shower.h:192
geo::WireID WireID() const
Definition: Hit.h:233
std::vector< anab::Calorimetry > GetRecoShowerCalorimetry(const recob::Shower &shower, art::Event const &evt, const std::string showerModule, const std::string caloModule) const
Get shower calo info.
WireID_t Wire
Index of the wire within its plane.
Definition: geo_types.h:580
std::vector< double > reco_beam_calo_wire
std::vector< int > reco_beam_calo_TPC
ValidHandle< PROD > getValidHandle(InputTag const &tag) const
Definition: DataViewImpl.h:441
const TVector3 & Direction() const
Definition: Shower.h:189
float PeakTime() const
Time of the signal peak, in tick units.
Definition: Hit.h:218
protoana::ProtoDUNEShowerUtils showerUtil
detail::Node< FrameID, bool > PlaneID
Definition: CRTID.h:125
2D representation of charge deposited in the TDC/wire plane
Definition: Hit.h:48
TPCID_t TPC
Index of the TPC within its cryostat.
Definition: geo_types.h:406
int ID() const
Definition: Shower.h:187
calorimetry
QTextStream & endl(QTextStream &s)
std::vector< double > reco_beam_calo_tick
void pduneana::PDSPAnalyzer::BeamTrackInfo ( const art::Event evt,
const recob::Track thisTrack,
detinfo::DetectorClocksData const &  clockData 
)
private

Definition at line 2398 of file PDSPAnalyzer_module.cc.

2400  {
2401 
2402  auto sce = lar::providerFrom<spacecharge::SpaceChargeService>();
2403  auto const detProp
2405  evt, clockData);
2406  auto allHits = evt.getValidHandle<std::vector<recob::Hit> >(fHitTag);
2407 
2408  //Ajib's michel identifier
2409  if (!fSkipMVA) {
2410  std::pair<double, int> vertex_michel_score =
2411  trackUtil.GetVertexMichelScore(*thisTrack, evt, fTrackerTag, fHitTag/*,
2412  0., -500., 500., 0., 500., 0.*/);
2413  reco_beam_vertex_nHits = vertex_michel_score.second;
2414  reco_beam_vertex_michel_score = vertex_michel_score.first;
2415 
2416  std::pair<double, double> vertex_michel_score_weight_by_charge =
2418  reco_beam_vertex_michel_score_weight_by_charge = (vertex_michel_score_weight_by_charge.second != 0 ? vertex_michel_score_weight_by_charge.first/vertex_michel_score_weight_by_charge.second : -999.);
2419  }
2420 
2421  if (fVerbose) std::cout << "Beam particle is track-like " << thisTrack->ID() << std::endl;
2422  reco_beam_type = 13;
2423 
2424  //Flag to tell if it passes the beam cuts
2425  //-- should probably take out or make it more flexible for other runs
2426  reco_beam_passes_beam_cuts = beam_cuts.IsBeamlike( *thisTrack, evt, "1" );
2427  if (fVerbose) std::cout << "Beam Cuts " << reco_beam_passes_beam_cuts << std::endl;
2428 
2429 
2430  reco_beam_trackID = thisTrack->ID();
2431 
2432  //Using default pandora info -- not SCE-corrected
2433  reco_beam_startX = thisTrack->Trajectory().Start().X();
2434  reco_beam_startY = thisTrack->Trajectory().Start().Y();
2435  reco_beam_startZ = thisTrack->Trajectory().Start().Z();
2436  reco_beam_endX = thisTrack->Trajectory().End().X();
2437  reco_beam_endY = thisTrack->Trajectory().End().Y();
2438  reco_beam_endZ = thisTrack->Trajectory().End().Z();
2439 
2440  auto startDir = thisTrack->StartDirection();
2441  auto endDir = thisTrack->EndDirection();
2442 
2443  //try flipping
2445  reco_beam_flipped = true;
2446  reco_beam_endX = thisTrack->Trajectory().Start().X();
2447  reco_beam_endY = thisTrack->Trajectory().Start().Y();
2448  reco_beam_endZ = thisTrack->Trajectory().Start().Z();
2449  reco_beam_startX = thisTrack->Trajectory().End().X();
2450  reco_beam_startY = thisTrack->Trajectory().End().Y();
2451  reco_beam_startZ = thisTrack->Trajectory().End().Z();
2452 
2453  reco_beam_trackDirX = -1. * endDir.X();
2454  reco_beam_trackDirY = -1. * endDir.Y();
2455  reco_beam_trackDirZ = -1. * endDir.Z();
2456 
2457  reco_beam_trackEndDirX = -1. * startDir.X();
2458  reco_beam_trackEndDirY = -1. * startDir.Y();
2459  reco_beam_trackEndDirZ = -1. * startDir.Z();
2460  }
2461  else{
2462  reco_beam_flipped = false;
2463  reco_beam_trackDirX = startDir.X();
2464  reco_beam_trackDirY = startDir.Y();
2465  reco_beam_trackDirZ = startDir.Z();
2466  reco_beam_trackEndDirX = endDir.X();
2467  reco_beam_trackEndDirY = endDir.Y();
2468  reco_beam_trackEndDirZ = endDir.Z();
2469  }
2470 
2471  reco_beam_len = thisTrack->Length();
2472  trkf::TrackMomentumCalculator track_p_calc;
2473 
2474  //Calculates momentum according to CSDA range
2476  thisTrack->Length(), 2212);
2478  thisTrack->Length(), 13);
2479  ////////////////////////////////////////////////////////////////
2480 
2481 
2482  //To do: remove
2483  std::map< const recob::Hit *, int > hitsToSlices;
2484  std::map< int, std::vector< const recob::Hit * > > slicesToHits;
2485 
2486  //Looking at the hits in the beam track
2487  std::map< size_t, const recob::Hit * > trajPtsToHits = trackUtil.GetRecoHitsFromTrajPoints( *thisTrack, evt, fTrackerTag );
2488  //double max_X = 0.;
2489  //double max_Y = 0.;
2490  //double max_Z = 0.;
2491 
2492  for( auto it = trajPtsToHits.begin(); it != trajPtsToHits.end(); ++it ){
2493 
2494  const recob::Hit * theHit = it->second;
2495  size_t i = it->first;
2496 
2497  double x = thisTrack->Trajectory().LocationAtPoint(i).X();
2498  double y = thisTrack->Trajectory().LocationAtPoint(i).Y();
2499  double z = thisTrack->Trajectory().LocationAtPoint(i).Z();
2500 
2501  if( fSaveHits ){
2502  //saving all hit coordinates for beamtrack
2503  reco_beam_spacePts_X.push_back(x);
2504  reco_beam_spacePts_Y.push_back(y);
2505  reco_beam_spacePts_Z.push_back(z);
2506  }
2507 
2508  //This creates the slices for the thin slice method.
2509  //To do: remove this
2510  int slice = std::floor((z - fZ0) / fPitch);
2511  hitsToSlices[theHit] = slice;
2512  slicesToHits[slice].push_back(theHit);
2513  }
2514 
2515  //Last point is the vertex slice
2516  //To do: remove
2517  reco_beam_vertex_slice = slicesToHits.rbegin()->first;
2518 
2519  //Primary Track Calorimetry
2520  //SCE-corrected
2521  auto calo = trackUtil.GetRecoTrackCalorimetry(*thisTrack, evt, fTrackerTag,
2523  //Get the correct plane (collection) because it's not always the same
2524  bool found_calo = false;
2525  size_t index = 0;
2526  for ( index = 0; index < calo.size(); ++index) {
2527  if (calo[index].PlaneID().Plane == 2) {
2528  found_calo = true;
2529  break;
2530  }
2531  }
2532 
2533  if (found_calo) {
2534  //Using SCE-corrected (from calorimetry) to calculate momentum by range
2536  calo[index].Range(), 2212);
2538  calo[index].Range(), 13);
2539  reco_beam_alt_len = calo[index].Range();
2540 
2541  auto calo_dQdX = calo[index].dQdx();
2542  auto calo_dEdX = calo[index].dEdx();
2543  auto calo_range = calo[index].ResidualRange();
2544  auto TpIndices = calo[index].TpIndices();
2545 
2546  //For Prod3 only
2547  if (fCalorimetryTagSCE == "pandoracali") {
2548  auto pandoracalo = trackUtil.GetRecoTrackCalorimetry(*thisTrack, evt, fTrackerTag, "pandoracalo");
2549  size_t this_index = 0;
2550  for ( this_index = 0; this_index < pandoracalo.size(); ++this_index) {
2551  if (pandoracalo[this_index].PlaneID().Plane == 2) {
2552  break;
2553  }
2554  }
2555  TpIndices = pandoracalo[this_index].TpIndices();
2556  }
2557  std::cout << calo_dQdX.size() << std::endl;
2558  std::cout << calo[index].PlaneID().Plane << std::endl;
2559 
2560  auto theXYZPoints = calo[index].XYZ();
2561  std::vector< size_t > calo_hit_indices;
2562  for( size_t i = 0; i < calo_dQdX.size(); ++i ){
2563  if (fVerbose) std::cout << i << std::endl;
2564  reco_beam_dQdX_SCE.push_back( calo_dQdX[i] );
2565  reco_beam_dEdX_SCE.push_back( calo_dEdX[i] );
2566  reco_beam_resRange_SCE.push_back( calo_range[i] );
2567  reco_beam_TrkPitch_SCE.push_back( calo[index].TrkPitchVec()[i] );
2568 
2569  const recob::Hit & theHit = (*allHits)[ TpIndices[i] ];
2570  reco_beam_dQ.push_back(theHit.Integral());
2571  reco_beam_calo_TPC.push_back(theHit.WireID().TPC);
2572  if (theHit.WireID().TPC == 1) {
2573  reco_beam_calo_wire.push_back( theHit.WireID().Wire );
2574  }
2575  else if (theHit.WireID().TPC == 5) {
2576  reco_beam_calo_wire.push_back( theHit.WireID().Wire + 479);
2577  }
2578  //Need other TPCs?
2579  else {
2580  reco_beam_calo_wire.push_back(theHit.WireID().Wire );
2581  }
2582  reco_beam_calo_tick.push_back( theHit.PeakTime() );
2583  calo_hit_indices.push_back( TpIndices[i] );
2584 
2585  reco_beam_calo_wire_z.push_back(
2586  geom->Wire(theHit.WireID()).GetCenter().Z());
2587  reco_beam_calo_X.push_back(theXYZPoints[i].X());
2588  reco_beam_calo_Y.push_back(theXYZPoints[i].Y());
2589  reco_beam_calo_Z.push_back(theXYZPoints[i].Z());
2590  if (fVerbose)
2591  std::cout << theXYZPoints[i].X() << " " << theXYZPoints[i].Y() << " " <<
2592  theXYZPoints[i].Z() << " " << theHit.WireID().Wire << " " <<
2593  geom->Wire(theHit.WireID()).GetCenter().Z() << " " <<
2594  theHit.WireID().TPC << " " << std::endl;
2595  }
2596 
2597  //Getting the SCE corrected start/end positions & directions
2598  std::sort(theXYZPoints.begin(), theXYZPoints.end(), [](auto a, auto b)
2599  {return (a.Z() < b.Z());});
2600 
2601  //Getting position + direction from SCE-corrected calorimetry
2602  //Attempt to use a few different ways to do this
2603  //
2604  //i.e. just gitting the line from start to end
2605  //or the line between first two points
2606  //or fitting a line to the first 3-4 points
2607  if (theXYZPoints.size()) {
2608  reco_beam_calo_startX = theXYZPoints[0].X();
2609  reco_beam_calo_startY = theXYZPoints[0].Y();
2610  reco_beam_calo_startZ = theXYZPoints[0].Z();
2611  reco_beam_calo_endX = theXYZPoints.back().X();
2612  reco_beam_calo_endY = theXYZPoints.back().Y();
2613  reco_beam_calo_endZ = theXYZPoints.back().Z();
2614 
2615  TVector3 dir((theXYZPoints.back().X() - theXYZPoints[0].X()),
2616  (theXYZPoints.back().Y() - theXYZPoints[0].Y()),
2617  (theXYZPoints.back().Z() - theXYZPoints[0].Z()));
2618  reco_beam_calo_startDirX.push_back(dir.Unit().X());
2619  reco_beam_calo_endDirX.push_back(dir.Unit().X());
2620  reco_beam_calo_startDirY.push_back(dir.Unit().Y());
2621  reco_beam_calo_endDirY.push_back(dir.Unit().Y());
2622  reco_beam_calo_startDirZ.push_back(dir.Unit().Z());
2623  reco_beam_calo_endDirZ.push_back(dir.Unit().Z());
2624  }
2625  else {
2626  reco_beam_calo_startDirX.push_back(-999.);
2627  reco_beam_calo_endDirX.push_back(-999.);
2628  reco_beam_calo_startDirY.push_back(-999.);
2629  reco_beam_calo_endDirY.push_back(-999.);
2630  reco_beam_calo_startDirZ.push_back(-999.);
2631  reco_beam_calo_endDirZ.push_back(-999.);
2632  }
2633 
2634  if (theXYZPoints.size() > 1) {
2635  TVector3 start_p1(theXYZPoints[0].X(),
2636  theXYZPoints[0].Y(), theXYZPoints[0].Z());
2637  TVector3 start_p2(theXYZPoints[1].X(),
2638  theXYZPoints[1].Y(), theXYZPoints[1].Z());
2639  TVector3 start_diff = start_p2 - start_p1;
2640 
2641  reco_beam_calo_startDirX.push_back(start_diff.Unit().X());
2642  reco_beam_calo_startDirY.push_back(start_diff.Unit().Y());
2643  reco_beam_calo_startDirZ.push_back(start_diff.Unit().Z());
2644 
2645  size_t nPoints = theXYZPoints.size();
2646  TVector3 end_p1(theXYZPoints[nPoints - 2].X(),
2647  theXYZPoints[nPoints - 2].Y(), theXYZPoints[nPoints - 2].Z());
2648  TVector3 end_p2(theXYZPoints[nPoints - 1].X(),
2649  theXYZPoints[nPoints - 1].Y(), theXYZPoints[nPoints - 1].Z());
2650  TVector3 end_diff = end_p2 - end_p1;
2651 
2652  reco_beam_calo_endDirX.push_back(end_diff.Unit().X());
2653  reco_beam_calo_endDirY.push_back(end_diff.Unit().Y());
2654  reco_beam_calo_endDirZ.push_back(end_diff.Unit().Z());
2655  }
2656  else {
2657  reco_beam_calo_startDirX.push_back(-999.);
2658  reco_beam_calo_endDirX.push_back(-999.);
2659  reco_beam_calo_startDirY.push_back(-999.);
2660  reco_beam_calo_endDirY.push_back(-999.);
2661  reco_beam_calo_startDirZ.push_back(-999.);
2662  reco_beam_calo_endDirZ.push_back(-999.);
2663  }
2664 
2665  if (theXYZPoints.size() > 2) {
2666  std::vector<TVector3> input;
2667  for (size_t iP = 0; iP < 3; ++iP) {
2668  input.push_back(TVector3(theXYZPoints[iP].X(),
2669  theXYZPoints[iP].Y(),
2670  theXYZPoints[iP].Z()));
2671  }
2672 
2673  TVector3 startDiff = FitLine(input);
2674  reco_beam_calo_startDirX.push_back(startDiff.Unit().X());
2675  reco_beam_calo_startDirY.push_back(startDiff.Unit().Y());
2676  reco_beam_calo_startDirZ.push_back(startDiff.Unit().Z());
2677 
2678  std::vector<TVector3> end_input;
2679  size_t nPoints = theXYZPoints.size();
2680  for (size_t iP = nPoints - 3; iP < nPoints; ++iP) {
2681  end_input.push_back(TVector3(theXYZPoints[iP].X(),
2682  theXYZPoints[iP].Y(),
2683  theXYZPoints[iP].Z()));
2684  }
2685 
2686  TVector3 endDiff = FitLine(end_input);
2687  reco_beam_calo_endDirX.push_back(endDiff.Unit().X());
2688  reco_beam_calo_endDirY.push_back(endDiff.Unit().Y());
2689  reco_beam_calo_endDirZ.push_back(endDiff.Unit().Z());
2690  }
2691  else {
2692  reco_beam_calo_startDirX.push_back(-999.);
2693  reco_beam_calo_endDirX.push_back(-999.);
2694  reco_beam_calo_startDirY.push_back(-999.);
2695  reco_beam_calo_endDirY.push_back(-999.);
2696  reco_beam_calo_startDirZ.push_back(-999.);
2697  reco_beam_calo_endDirZ.push_back(-999.);
2698  }
2699 
2700  if (theXYZPoints.size() > 3) {
2701  std::vector<TVector3> input;
2702  for (size_t iP = 0; iP < 4; ++iP) {
2703  input.push_back(TVector3(theXYZPoints[iP].X(),
2704  theXYZPoints[iP].Y(),
2705  theXYZPoints[iP].Z()));
2706  }
2707 
2708  TVector3 startDiff = FitLine(input);
2709  reco_beam_calo_startDirX.push_back(startDiff.Unit().X());
2710  reco_beam_calo_startDirY.push_back(startDiff.Unit().Y());
2711  reco_beam_calo_startDirZ.push_back(startDiff.Unit().Z());
2712 
2713  std::vector<TVector3> end_input;
2714  size_t nPoints = theXYZPoints.size();
2715  for (size_t iP = nPoints - 4; iP < nPoints; ++iP) {
2716  end_input.push_back(TVector3(theXYZPoints[iP].X(),
2717  theXYZPoints[iP].Y(),
2718  theXYZPoints[iP].Z()));
2719  }
2720 
2721  TVector3 endDiff = FitLine(end_input);
2722  reco_beam_calo_endDirX.push_back(endDiff.Unit().X());
2723  reco_beam_calo_endDirY.push_back(endDiff.Unit().Y());
2724  reco_beam_calo_endDirZ.push_back(endDiff.Unit().Z());
2725 
2726  }
2727  else {
2728  reco_beam_calo_startDirX.push_back(-999.);
2729  reco_beam_calo_endDirX.push_back(-999.);
2730  reco_beam_calo_startDirY.push_back(-999.);
2731  reco_beam_calo_endDirY.push_back(-999.);
2732  reco_beam_calo_startDirZ.push_back(-999.);
2733  reco_beam_calo_endDirZ.push_back(-999.);
2734  }
2735  ////////////////////////////////////////////
2736 
2737  //New Calibration
2738  std::cout << "Getting reco beam calo" << std::endl;
2739  if (fRecalibrate){
2740  std::vector< float > new_dEdX = calibration_SCE.GetCalibratedCalorimetry(*thisTrack, evt, fTrackerTag, fCalorimetryTagSCE, 2, -10.);
2741  std::cout << new_dEdX.size() << " " << reco_beam_resRange_SCE.size() << std::endl;
2742  for( size_t i = 0; i < new_dEdX.size(); ++i ){ reco_beam_calibrated_dEdX_SCE.push_back( new_dEdX[i] ); }
2743  std::cout << "got calibrated dedx" << std::endl;
2744 
2745  std::vector<double> new_dQdX = calibration_SCE.CalibratedQdX(
2746  *thisTrack, evt, fTrackerTag,
2747  fCalorimetryTagSCE, 2, -10.);
2748  for (auto dqdx : new_dQdX) {
2749  reco_beam_calibrated_dQdX_SCE.push_back(dqdx);
2750  }
2751 
2752  std::vector<double> efield = calibration_SCE.GetEFieldVector(
2753  *thisTrack, evt, fTrackerTag, fCalorimetryTagSCE, 2, -10.);
2754  for (auto ef : efield) {
2755  reco_beam_EField_SCE.push_back(ef);
2756  }
2757  }
2758  else{
2759  for (size_t i = 0; i < calo_dQdX.size(); ++i){
2760  reco_beam_calibrated_dEdX_SCE.push_back(calo_dEdX[i]);
2761  reco_beam_calibrated_dQdX_SCE.push_back(calo_dQdX[i]);
2762 
2763  // Electric Field in the drift region in KV/cm
2764  double E_field_nominal = detProp.Efield();
2765 
2766  geo::Vector_t E_field_offsets
2767  = (sce->EnableCalEfieldSCE() && fSCE ?
2768  sce->GetCalEfieldOffsets(
2769  geo::Point_t{theXYZPoints[i].X(),
2770  theXYZPoints[i].Y(),
2771  theXYZPoints[i].Z()},
2772  calo[index].PlaneID().TPC) :
2773  geo::Vector_t{0., 0., 0.});
2774  TVector3 E_field_vector = {
2775  E_field_nominal*(1 + E_field_offsets.X()),
2776  E_field_nominal*E_field_offsets.Y(),
2777  E_field_nominal*E_field_offsets.Z()};
2778 
2779  double E_field = E_field_vector.Mag();
2780  reco_beam_EField_SCE.push_back(E_field);
2781  }
2782  }
2783  ////////////////////////////////////////////
2784 
2785  //Get the chi2-based PID for the SCE-corrected beam track
2786  std::pair< double, int > pid_chi2_ndof = trackUtil.Chi2PID( reco_beam_calibrated_dEdX_SCE, reco_beam_resRange_SCE, templates[ 2212 ] );
2787  reco_beam_Chi2_proton = pid_chi2_ndof.first;
2788  reco_beam_Chi2_ndof = pid_chi2_ndof.second;
2789 
2790  if (fVerbose)
2791  std::cout << "Calo check: " << reco_beam_calibrated_dEdX_SCE.size() << " " <<
2793  std::vector< calo_point > reco_beam_calo_points;
2794  //Doing thin slice method
2795  if (reco_beam_calibrated_dEdX_SCE.size() &&
2798 
2799  for( size_t i = 0; i < reco_beam_calibrated_dEdX_SCE.size(); ++i ){
2800  reco_beam_calo_points.push_back(
2801  calo_point(reco_beam_calo_wire[i], reco_beam_calo_tick[i],
2804  reco_beam_dQ[i],
2807  reco_beam_resRange_SCE[i], calo_hit_indices[i],
2811  }
2812 
2813  //std::cout << "N Calo points: " << reco_beam_calo_points.size() << std::endl;
2814  //Sort
2815  std::sort( reco_beam_calo_points.begin(), reco_beam_calo_points.end(), [](calo_point a, calo_point b) {return ( a.z < b.z );} );
2816 
2817  //And also put these in the right order
2818  for( size_t i = 0; i < reco_beam_calo_points.size(); ++i ){
2819  calo_point thePoint = reco_beam_calo_points[i];
2820  reco_beam_calo_wire[i] = thePoint.wire;
2821  reco_beam_calo_tick[i] = thePoint.tick;
2822  reco_beam_calibrated_dQdX_SCE[i] = thePoint.calibrated_dQdX;
2823  reco_beam_calibrated_dEdX_SCE[i] = thePoint.calibrated_dEdX;
2824  reco_beam_TrkPitch_SCE[i] = thePoint.pitch;
2825  calo_hit_indices[i] = thePoint.hit_index;
2826  reco_beam_calo_wire_z[i] = thePoint.wire_z;
2827  reco_beam_calo_TPC[i] = thePoint.tpc;
2828  reco_beam_resRange_SCE[i] = thePoint.res_range;
2829  reco_beam_dQdX_SCE[i] = thePoint.dQdX;
2830  reco_beam_dQ[i] = thePoint.dQ;
2831  reco_beam_dEdX_SCE[i] = thePoint.dEdX;
2832  reco_beam_EField_SCE[i] = thePoint.EField;
2833  reco_beam_calo_X[i] = thePoint.x;
2834  reco_beam_calo_Y[i] = thePoint.y;
2835  reco_beam_calo_Z[i] = thePoint.z;
2836  //reco_beam_calo_x[i]
2837  }
2838 
2839  //Get the initial Energy KE
2840  //Assumes it's a pion -- maybe make configurable To do
2841  //double mass = 0.;
2842  double init_KE = 0.;
2843  //std::cout << "Has BI? " << fMCHasBI << " " << evt.isRealData() << std::endl;
2844  if (evt.isRealData() || fMCHasBI) {
2845  double mass = 139.57;
2846 
2847  init_KE = sqrt( 1.e6*beam_inst_P*beam_inst_P + mass*mass ) - mass;
2848  // std::cout << "MC has BI: " << init_KE << std::endl;
2849  }
2850  else{
2851  init_KE = sqrt(1.e6*true_beam_startP*true_beam_startP +
2853  }
2854 
2855  reco_beam_incidentEnergies.push_back( init_KE );
2856  for( size_t i = 0; i < reco_beam_calo_points.size() - 1; ++i ){ //-1 to not count the last slice
2857  //use dedx * pitch or new hit calculation?
2858  if (reco_beam_calo_points[i].calibrated_dEdX < 0.) continue;
2859  double this_energy = reco_beam_incidentEnergies.back() - ( reco_beam_calo_points[i].calibrated_dEdX * reco_beam_calo_points[i].pitch );
2860  reco_beam_incidentEnergies.push_back( this_energy );
2861  }
2863  }
2864  }
2865 
2866  //Uncorrected
2867  auto calo_NoSCE = trackUtil.GetRecoTrackCalorimetry(*thisTrack, evt,
2868  fTrackerTag,
2870  found_calo = false;
2871  index = 0;
2872  for (index = 0; index < calo_NoSCE.size(); ++index) {
2873  if (calo_NoSCE[index].PlaneID().Plane == 2) {
2874  found_calo = true;
2875  break;
2876  }
2877  }
2878 
2879  if (found_calo) {
2880  auto calo_dQdX = calo_NoSCE[index].dQdx();
2881  auto calo_dEdX = calo_NoSCE[index].dEdx();
2882  auto calo_range = calo_NoSCE[index].ResidualRange();
2883  auto TpIndices = calo_NoSCE[index].TpIndices();
2884 
2885  std::vector< size_t > calo_hit_indices;
2886  for( size_t i = 0; i < calo_dQdX.size(); ++i ){
2887  if (fVerbose) std::cout << i << std::endl;
2888  reco_beam_dQdX_NoSCE.push_back( calo_dQdX[i] );
2889  reco_beam_dEdX_NoSCE.push_back( calo_dEdX[i] );
2890  reco_beam_resRange_NoSCE.push_back( calo_range[i] );
2891  reco_beam_TrkPitch_NoSCE.push_back( calo_NoSCE[index].TrkPitchVec()[i] );
2892  calo_hit_indices.push_back( TpIndices[i] );
2893  const recob::Hit & theHit = (*allHits)[ TpIndices[i] ];
2894  reco_beam_dQ_NoSCE.push_back(theHit.Integral());
2895  reco_beam_calo_TPC_NoSCE.push_back(theHit.WireID().TPC);
2896  if (theHit.WireID().TPC == 1) {
2897  reco_beam_calo_wire_NoSCE.push_back( theHit.WireID().Wire );
2898  }
2899  else if (theHit.WireID().TPC == 5) {
2900  reco_beam_calo_wire_NoSCE.push_back( theHit.WireID().Wire + 479);
2901  }
2902  //Need other TPCs?
2903  else {
2904  reco_beam_calo_wire_NoSCE.push_back(theHit.WireID().Wire );
2905  }
2906  reco_beam_calo_wire_z_NoSCE.push_back(
2907  geom->Wire(theHit.WireID()).GetCenter().Z());
2908 
2909  }
2910 
2911  if (fRecalibrate) {
2912  std::vector< float > new_dEdX = calibration_NoSCE.GetCalibratedCalorimetry( *thisTrack, evt, fTrackerTag, fCalorimetryTagNoSCE, 2, -1.);
2913  for( size_t i = 0; i < new_dEdX.size(); ++i ){ reco_beam_calibrated_dEdX_NoSCE.push_back( new_dEdX[i] ); }
2914  }
2915  else {
2916  for (auto dedx : reco_beam_dEdX_NoSCE) {
2917  reco_beam_calibrated_dEdX_NoSCE.push_back(dedx);
2918  }
2919  }
2920  ////////////////////////////////////////////
2921 
2922  std::vector< calo_point > reco_beam_calo_points;
2923  if (reco_beam_calibrated_dEdX_NoSCE.size() &&
2926 
2927  for( size_t i = 0; i < reco_beam_calibrated_dEdX_NoSCE.size(); ++i ){
2928  reco_beam_calo_points.push_back(
2929  calo_point(reco_beam_calo_wire_NoSCE[i], 0.,
2931  reco_beam_dQdX_NoSCE[i], reco_beam_dEdX_NoSCE[i],
2932  reco_beam_dQ_NoSCE[i], 0.,
2934  reco_beam_resRange_NoSCE[i], calo_hit_indices[i],
2936  0., 0., 0., 0.));
2937  }
2938 
2939  //std::cout << "N Calo points: " << reco_beam_calo_points.size() << std::endl;
2940  //Sort
2941  std::sort( reco_beam_calo_points.begin(), reco_beam_calo_points.end(), [](calo_point a, calo_point b) {return ( a.z < b.z );} );
2942 
2943  //And also put these in the right order
2944  for( size_t i = 0; i < reco_beam_calo_points.size(); ++i ){
2945  calo_point thePoint = reco_beam_calo_points[i];
2946  reco_beam_calo_wire_NoSCE[i] = thePoint.wire;
2947  reco_beam_calibrated_dEdX_NoSCE[i] = thePoint.calibrated_dEdX;
2948  reco_beam_TrkPitch_NoSCE[i] = thePoint.pitch;
2949  calo_hit_indices[i] = thePoint.hit_index;
2950  reco_beam_calo_wire_z_NoSCE[i] = thePoint.z;
2951  reco_beam_calo_TPC_NoSCE[i] = thePoint.tpc;
2952  reco_beam_resRange_NoSCE[i] = thePoint.res_range;
2953  reco_beam_dQdX_NoSCE[i] = thePoint.dQdX;
2954  reco_beam_dEdX_NoSCE[i] = thePoint.dEdX;
2955  }
2956  }
2957  }
2958 }
std::vector< double > reco_beam_calo_startDirX
std::vector< double > reco_beam_calo_X
std::pair< double, double > GetVertexMichelScore_weight_by_charge(const recob::Track &track, const art::Event &evt, const std::string trackModule, const std::string hitModule, double min_length=5., double min_x=-200., double max_x=0., double min_y=200., double max_y=500., double min_z=25., bool check_wire=true, double check_x=0, double check_y=0., double check_z=0.)
std::vector< double > reco_beam_spacePts_Y
std::vector< double > reco_beam_dQ_NoSCE
std::vector< double > GetEFieldVector(const recob::Track &track, art::Event const &evt, const std::string trackModule, const std::string caloModule, size_t planeID, double negativeZFix=0.)
protoana::ProtoDUNEBeamCuts beam_cuts
std::vector< double > reco_beam_dEdX_NoSCE
std::vector< double > reco_beam_TrkPitch_NoSCE
std::vector< double > reco_beam_EField_SCE
std::vector< double > reco_beam_calo_wire_NoSCE
std::vector< double > reco_beam_resRange_SCE
geo::WireID WireID() const
Definition: Hit.h:233
const recob::TrackTrajectory & Trajectory() const
Access to the stored recob::TrackTrajectory.
Definition: Track.h:98
art::ServiceHandle< geo::Geometry > geom
std::vector< anab::Calorimetry > GetRecoTrackCalorimetry(const recob::Track &track, art::Event const &evt, const std::string trackModule, const std::string caloModule) const
Get the Calorimetry(s) from a given reco track.
std::vector< double > reco_beam_calo_wire_z
std::vector< double > reco_beam_spacePts_Z
std::vector< double > reco_beam_calo_startDirY
float Integral() const
Integral under the calibrated signal waveform of the hit, in tick x ADC units.
Definition: Hit.h:224
WireID_t Wire
Index of the wire within its plane.
Definition: geo_types.h:580
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double >, ROOT::Math::GlobalCoordinateSystemTag > Vector_t
Type for representation of momenta in 3D space.
Definition: geo_vectors.h:164
string dir
std::vector< double > reco_beam_calo_Y
std::vector< int > reco_beam_calo_TPC_NoSCE
std::vector< double > reco_beam_calo_wire
bool IsBeamlike(const recob::Track &, const art::Event &, std::string)
std::pair< double, int > GetVertexMichelScore(const recob::Track &track, const art::Event &evt, const std::string trackModule, const std::string hitModule, double min_length=5., double min_x=-200., double max_x=0., double min_y=200., double max_y=500., double min_z=25., bool check_wire=true, double check_x=0, double check_y=0., double check_z=0.)
std::vector< double > reco_beam_calibrated_dQdX_SCE
std::vector< double > reco_beam_TrkPitch_SCE
bool isRealData() const
protoana::ProtoDUNECalibration calibration_NoSCE
double reco_beam_vertex_michel_score_weight_by_charge
std::vector< double > reco_beam_spacePts_X
Vector_t StartDirection() const
Access to track direction at different points.
Definition: Track.h:131
double Length(size_t p=0) const
Access to various track properties.
Definition: Track.h:167
static int input(void)
Definition: code.cpp:15695
TVector3 FitLine(const std::vector< TVector3 > &input)
std::vector< int > reco_beam_calo_TPC
T LocationAtPoint(unsigned int p) const
Position at point p. Use e.g. as:
std::vector< double > CalibratedQdX(const recob::Track &track, art::Event const &evt, const std::string trackModule, const std::string caloModule, size_t planeID, double negativeZFix)
const double a
std::vector< double > reco_beam_calibrated_dEdX_SCE
ValidHandle< PROD > getValidHandle(InputTag const &tag) const
Definition: DataViewImpl.h:441
std::vector< double > reco_beam_dQdX_SCE
std::vector< double > reco_beam_calo_wire_z_NoSCE
std::map< int, TProfile * > templates
protoana::ProtoDUNECalibration calibration_SCE
std::pair< double, int > Chi2PID(const std::vector< double > &track_dedx, const std::vector< double > &range, TProfile *profile)
std::vector< double > reco_beam_calibrated_dEdX_NoSCE
std::vector< double > reco_beam_calo_Z
ROOT::Math::PositionVector3D< ROOT::Math::Cartesian3D< double >, ROOT::Math::GlobalCoordinateSystemTag > Point_t
Type for representation of position in physical 3D space.
Definition: geo_vectors.h:184
std::vector< double > reco_beam_calo_endDirX
WireGeo const & Wire(geo::WireID const &wireid) const
Returns the specified wire.
int ID() const
Definition: Track.h:198
protoana::ProtoDUNETrackUtils trackUtil
float PeakTime() const
Time of the signal peak, in tick units.
Definition: Hit.h:218
std::vector< double > reco_beam_calo_endDirY
std::vector< double > reco_beam_incidentEnergies
Vector_t EndDirection() const
Definition: Track.h:133
Point_t const & End() const
Returns the position of the last valid point of the trajectory [cm].
std::vector< double > reco_beam_resRange_NoSCE
std::vector< double > reco_beam_dQ
std::vector< double > reco_beam_dEdX_SCE
static bool * b
Definition: config.cpp:1043
detail::Node< FrameID, bool > PlaneID
Definition: CRTID.h:125
list x
Definition: train.py:276
2D representation of charge deposited in the TDC/wire plane
Definition: Hit.h:48
TPCID_t TPC
Index of the TPC within its cryostat.
Definition: geo_types.h:406
std::vector< double > reco_beam_calo_startDirZ
std::vector< float > GetCalibratedCalorimetry(const recob::Track &track, art::Event const &evt, const std::string trackModule, const std::string caloModule, size_t planeID, double negativeZFix=0.)
std::map< size_t, const recob::Hit * > GetRecoHitsFromTrajPoints(const recob::Track &track, art::Event const &evt, std::string trackModule)
Point_t const & Start() const
Returns the position of the first valid point of the trajectory [cm].
std::vector< double > reco_beam_dQdX_NoSCE
calorimetry
double GetTrackMomentum(double trkrange, int pdg) const
QTextStream & endl(QTextStream &s)
std::vector< double > reco_beam_calo_endDirZ
TFile * ef
Definition: doAna.cpp:25
std::vector< double > reco_beam_calo_tick
void pduneana::PDSPAnalyzer::beginJob ( )
overridevirtual

Reconstructed info

Calorimetry/chi2 planes 0 and 1

Reimplemented from art::EDAnalyzer.

Definition at line 1306 of file PDSPAnalyzer_module.cc.

1306  {
1307 
1308  gROOT->SetBatch(1);
1309 
1311  fTree = tfs->make<TTree>("beamana","beam analysis tree");
1312 
1313  fTree->Branch("run", &run);
1314  fTree->Branch("subrun", &subrun);
1315  fTree->Branch("event", &event);
1316  fTree->Branch("MC", &MC);
1317 
1318 
1319 
1320  ///Reconstructed info
1321  fTree->Branch("reco_reconstructable_beam_event",&reco_reconstructable_beam_event);
1322  fTree->Branch("reco_beam_type", &reco_beam_type);
1323  fTree->Branch("reco_beam_startX", &reco_beam_startX);
1324  fTree->Branch("reco_beam_startY", &reco_beam_startY);
1325  fTree->Branch("reco_beam_startZ", &reco_beam_startZ);
1326  fTree->Branch("reco_beam_endX", &reco_beam_endX);
1327  fTree->Branch("reco_beam_endY", &reco_beam_endY);
1328  fTree->Branch("reco_beam_endZ", &reco_beam_endZ);
1329  fTree->Branch("true_beam_len", &true_beam_len);
1330  fTree->Branch("reco_beam_len", &reco_beam_len);
1331  fTree->Branch("reco_beam_alt_len", &reco_beam_alt_len);
1332  fTree->Branch("reco_beam_alt_len_allTrack", &reco_beam_alt_len_allTrack);
1333  fTree->Branch("reco_beam_calo_startX", &reco_beam_calo_startX);
1334  fTree->Branch("reco_beam_calo_startY", &reco_beam_calo_startY);
1335  fTree->Branch("reco_beam_calo_startZ", &reco_beam_calo_startZ);
1336  fTree->Branch("reco_beam_calo_endX", &reco_beam_calo_endX);
1337  fTree->Branch("reco_beam_calo_endY", &reco_beam_calo_endY);
1338  fTree->Branch("reco_beam_calo_endZ", &reco_beam_calo_endZ);
1339  fTree->Branch("reco_beam_calo_startX_allTrack", &reco_beam_calo_startX_allTrack);
1340  fTree->Branch("reco_beam_calo_startY_allTrack", &reco_beam_calo_startY_allTrack);
1341  fTree->Branch("reco_beam_calo_startZ_allTrack", &reco_beam_calo_startZ_allTrack);
1342  fTree->Branch("reco_beam_calo_endX_allTrack", &reco_beam_calo_endX_allTrack);
1343  fTree->Branch("reco_beam_calo_endY_allTrack", &reco_beam_calo_endY_allTrack);
1344  fTree->Branch("reco_beam_calo_endZ_allTrack", &reco_beam_calo_endZ_allTrack);
1345  fTree->Branch("reco_beam_calo_startDirX", &reco_beam_calo_startDirX);
1346  fTree->Branch("reco_beam_calo_startDirY", &reco_beam_calo_startDirY);
1347  fTree->Branch("reco_beam_calo_startDirZ", &reco_beam_calo_startDirZ);
1348  fTree->Branch("reco_beam_calo_endDirX", &reco_beam_calo_endDirX);
1349  fTree->Branch("reco_beam_calo_endDirY", &reco_beam_calo_endDirY);
1350  fTree->Branch("reco_beam_calo_endDirZ", &reco_beam_calo_endDirZ);
1351 
1352  fTree->Branch("reco_beam_trackDirX", &reco_beam_trackDirX);
1353  fTree->Branch("reco_beam_trackDirY", &reco_beam_trackDirY);
1354  fTree->Branch("reco_beam_trackDirZ", &reco_beam_trackDirZ);
1355  fTree->Branch("reco_beam_trackEndDirX", &reco_beam_trackEndDirX);
1356  fTree->Branch("reco_beam_trackEndDirY", &reco_beam_trackEndDirY);
1357  fTree->Branch("reco_beam_trackEndDirZ", &reco_beam_trackEndDirZ);
1358  fTree->Branch("reco_beam_vertex_nHits", &reco_beam_vertex_nHits);
1359  fTree->Branch("reco_beam_vertex_michel_score", &reco_beam_vertex_michel_score);
1360  fTree->Branch("reco_beam_vertex_nHits_allTrack", &reco_beam_vertex_nHits_allTrack);
1361  fTree->Branch("reco_beam_vertex_michel_score_allTrack", &reco_beam_vertex_michel_score_allTrack);
1362  fTree->Branch("reco_beam_vertex_michel_score_weight_by_charge", &reco_beam_vertex_michel_score_weight_by_charge);
1363  fTree->Branch("reco_beam_vertex_michel_score_weight_by_charge_allTrack", &reco_beam_vertex_michel_score_weight_by_charge_allTrack);
1364  fTree->Branch("reco_beam_trackID", &reco_beam_trackID);
1365  fTree->Branch("n_beam_slices", &n_beam_slices);
1366  fTree->Branch("n_beam_particles", &n_beam_particles);
1367  fTree->Branch("beam_track_IDs", &beam_track_IDs);
1368  fTree->Branch("beam_particle_scores", &beam_particle_scores);
1369 
1370  fTree->Branch("reco_beam_dQdX_SCE", &reco_beam_dQdX_SCE);
1371  fTree->Branch("reco_beam_EField_SCE", &reco_beam_EField_SCE);
1372  fTree->Branch("reco_beam_calo_X", &reco_beam_calo_X);
1373  fTree->Branch("reco_beam_calo_Y", &reco_beam_calo_Y);
1374  fTree->Branch("reco_beam_calo_Z", &reco_beam_calo_Z);
1375  fTree->Branch("reco_beam_calo_X_allTrack", &reco_beam_calo_X_allTrack);
1376  fTree->Branch("reco_beam_calo_Y_allTrack", &reco_beam_calo_Y_allTrack);
1377  fTree->Branch("reco_beam_calo_Z_allTrack", &reco_beam_calo_Z_allTrack);
1378  fTree->Branch("reco_beam_dQ", &reco_beam_dQ);
1379  fTree->Branch("reco_beam_dEdX_SCE", &reco_beam_dEdX_SCE);
1380  fTree->Branch("reco_beam_calibrated_dEdX_SCE", &reco_beam_calibrated_dEdX_SCE);
1381  fTree->Branch("reco_beam_calibrated_dQdX_SCE", &reco_beam_calibrated_dQdX_SCE);
1382  fTree->Branch("reco_beam_resRange_SCE", &reco_beam_resRange_SCE);
1383  fTree->Branch("reco_beam_TrkPitch_SCE", &reco_beam_TrkPitch_SCE);
1384  fTree->Branch("reco_beam_TrkPitch_SCE_allTrack", &reco_beam_TrkPitch_SCE_allTrack);
1385 
1386  fTree->Branch("reco_beam_dQdX_NoSCE", &reco_beam_dQdX_NoSCE);
1387  fTree->Branch("reco_beam_dQ_NoSCE", &reco_beam_dQ_NoSCE);
1388  fTree->Branch("reco_beam_dEdX_NoSCE", &reco_beam_dEdX_NoSCE);
1389  fTree->Branch("reco_beam_calibrated_dEdX_NoSCE", &reco_beam_calibrated_dEdX_NoSCE);
1390  fTree->Branch("reco_beam_resRange_NoSCE", &reco_beam_resRange_NoSCE);
1391  fTree->Branch("reco_beam_TrkPitch_NoSCE", &reco_beam_TrkPitch_NoSCE);
1392 
1393  fTree->Branch("reco_beam_calo_wire", &reco_beam_calo_wire);
1394  fTree->Branch("reco_beam_calo_wire_allTrack", &reco_beam_calo_wire_allTrack);
1395  fTree->Branch("reco_beam_calo_wire_z", &reco_beam_calo_wire_z);
1396  fTree->Branch("reco_beam_calo_wire_NoSCE", &reco_beam_calo_wire_NoSCE);
1397  fTree->Branch("reco_beam_calo_wire_z_NoSCE", &reco_beam_calo_wire_z_NoSCE);
1398  fTree->Branch("reco_beam_calo_tick", &reco_beam_calo_tick);
1399  fTree->Branch("reco_beam_calo_TPC", &reco_beam_calo_TPC);
1400  fTree->Branch("reco_beam_calo_TPC_NoSCE", &reco_beam_calo_TPC_NoSCE);
1401 
1402  fTree->Branch("reco_beam_flipped", &reco_beam_flipped);
1403  fTree->Branch("reco_beam_passes_beam_cuts", &reco_beam_passes_beam_cuts);
1404 
1405  fTree->Branch("reco_beam_PFP_ID", &reco_beam_PFP_ID);
1406  fTree->Branch("reco_beam_PFP_nHits", &reco_beam_PFP_nHits);
1407  fTree->Branch("reco_beam_PFP_trackScore", &reco_beam_PFP_trackScore);
1408  fTree->Branch("reco_beam_PFP_emScore", &reco_beam_PFP_emScore);
1409  fTree->Branch("reco_beam_PFP_michelScore", &reco_beam_PFP_michelScore);
1410  fTree->Branch("reco_beam_PFP_trackScore_collection", &reco_beam_PFP_trackScore_collection);
1411  fTree->Branch("reco_beam_PFP_emScore_collection", &reco_beam_PFP_emScore_collection);
1412  fTree->Branch("reco_beam_PFP_michelScore_collection", &reco_beam_PFP_michelScore_collection);
1413  fTree->Branch("reco_beam_PFP_trackScore_weight_by_charge", &reco_beam_PFP_trackScore_weight_by_charge);
1414  fTree->Branch("reco_beam_PFP_emScore_weight_by_charge", &reco_beam_PFP_emScore_weight_by_charge);
1415  fTree->Branch("reco_beam_PFP_michelScore_weight_by_charge", &reco_beam_PFP_michelScore_weight_by_charge);
1416  fTree->Branch("reco_beam_PFP_trackScore_collection_weight_by_charge", &reco_beam_PFP_trackScore_collection_weight_by_charge);
1417  fTree->Branch("reco_beam_PFP_emScore_collection_weight_by_charge", &reco_beam_PFP_emScore_collection_weight_by_charge);
1418  fTree->Branch("reco_beam_PFP_michelScore_collection_weight_by_charge", &reco_beam_PFP_michelScore_collection_weight_by_charge);
1419 
1420  fTree->Branch("reco_beam_allTrack_ID", &reco_beam_allTrack_ID);
1421  fTree->Branch("reco_beam_allTrack_beam_cuts", &reco_beam_allTrack_beam_cuts);
1422  fTree->Branch("reco_beam_allTrack_flipped", &reco_beam_allTrack_flipped);
1423  fTree->Branch("reco_beam_allTrack_len", &reco_beam_allTrack_len);
1424  fTree->Branch("reco_beam_allTrack_startX", &reco_beam_allTrack_startX);
1425  fTree->Branch("reco_beam_allTrack_startY", &reco_beam_allTrack_startY);
1426  fTree->Branch("reco_beam_allTrack_startZ", &reco_beam_allTrack_startZ);
1427  fTree->Branch("reco_beam_allTrack_endX", &reco_beam_allTrack_endX);
1428  fTree->Branch("reco_beam_allTrack_endY", &reco_beam_allTrack_endY);
1429  fTree->Branch("reco_beam_allTrack_endZ", &reco_beam_allTrack_endZ);
1430  fTree->Branch("reco_beam_allTrack_trackDirX", &reco_beam_allTrack_trackDirX);
1431  fTree->Branch("reco_beam_allTrack_trackDirY", &reco_beam_allTrack_trackDirY);
1432  fTree->Branch("reco_beam_allTrack_trackDirZ", &reco_beam_allTrack_trackDirZ);
1433  fTree->Branch("reco_beam_allTrack_trackEndDirX", &reco_beam_allTrack_trackEndDirX);
1434  fTree->Branch("reco_beam_allTrack_trackEndDirY", &reco_beam_allTrack_trackEndDirY);
1435  fTree->Branch("reco_beam_allTrack_trackEndDirZ", &reco_beam_allTrack_trackEndDirZ);
1436  fTree->Branch("reco_beam_allTrack_resRange", &reco_beam_allTrack_resRange);
1437  fTree->Branch("reco_beam_allTrack_calibrated_dEdX", &reco_beam_allTrack_calibrated_dEdX);
1438  fTree->Branch("reco_beam_allTrack_Chi2_proton", &reco_beam_allTrack_Chi2_proton);
1439  fTree->Branch("reco_beam_allTrack_Chi2_ndof", &reco_beam_allTrack_Chi2_ndof);
1440 
1441  fTree->Branch("reco_track_startX", &reco_track_startX);
1442  fTree->Branch("reco_track_startY", &reco_track_startY);
1443  fTree->Branch("reco_track_startZ", &reco_track_startZ);
1444  fTree->Branch("reco_track_endX", &reco_track_endX);
1445  fTree->Branch("reco_track_endY", &reco_track_endY);
1446  fTree->Branch("reco_track_endZ", &reco_track_endZ);
1447  fTree->Branch("reco_track_michel_score", &reco_track_michel_score);
1448  fTree->Branch("reco_track_michel_score_weight_by_charge", &reco_track_michel_score_weight_by_charge);
1449  fTree->Branch("reco_track_ID", &reco_track_ID);
1450  fTree->Branch("reco_track_nHits", &reco_track_nHits);
1451 
1452  //Alternative reco
1453  fTree->Branch("reco_daughter_PFP_true_byHits_PDG", &reco_daughter_PFP_true_byHits_PDG);
1454  fTree->Branch("reco_daughter_PFP_true_byHits_ID", &reco_daughter_PFP_true_byHits_ID);
1455  fTree->Branch("reco_daughter_PFP_true_byHits_origin", &reco_daughter_PFP_true_byHits_origin);
1456  fTree->Branch("reco_daughter_PFP_true_byHits_parID", &reco_daughter_PFP_true_byHits_parID);
1457  fTree->Branch("reco_daughter_PFP_true_byHits_parPDG", &reco_daughter_PFP_true_byHits_parPDG);
1458  fTree->Branch("reco_daughter_PFP_true_byHits_process", &reco_daughter_PFP_true_byHits_process);
1459  fTree->Branch("reco_daughter_PFP_true_byHits_sharedHits", &reco_daughter_PFP_true_byHits_sharedHits);
1460  fTree->Branch("reco_daughter_PFP_true_byHits_emHits", &reco_daughter_PFP_true_byHits_emHits);
1461 
1462  fTree->Branch("reco_daughter_PFP_true_byHits_len", &reco_daughter_PFP_true_byHits_len);
1463  fTree->Branch("reco_daughter_PFP_true_byHits_startX", &reco_daughter_PFP_true_byHits_startX);
1464  fTree->Branch("reco_daughter_PFP_true_byHits_startY", &reco_daughter_PFP_true_byHits_startY);
1465  fTree->Branch("reco_daughter_PFP_true_byHits_startZ", &reco_daughter_PFP_true_byHits_startZ);
1466  fTree->Branch("reco_daughter_PFP_true_byHits_endX", &reco_daughter_PFP_true_byHits_endX);
1467  fTree->Branch("reco_daughter_PFP_true_byHits_endY", &reco_daughter_PFP_true_byHits_endY);
1468  fTree->Branch("reco_daughter_PFP_true_byHits_endZ", &reco_daughter_PFP_true_byHits_endZ);
1469 
1470  fTree->Branch("reco_daughter_PFP_true_byHits_startPx", &reco_daughter_PFP_true_byHits_startPx);
1471  fTree->Branch("reco_daughter_PFP_true_byHits_startPy", &reco_daughter_PFP_true_byHits_startPy);
1472  fTree->Branch("reco_daughter_PFP_true_byHits_startPz", &reco_daughter_PFP_true_byHits_startPz);
1473  fTree->Branch("reco_daughter_PFP_true_byHits_startP", &reco_daughter_PFP_true_byHits_startP);
1474  fTree->Branch("reco_daughter_PFP_true_byHits_startE", &reco_daughter_PFP_true_byHits_startE);
1475  fTree->Branch("reco_daughter_PFP_true_byHits_endProcess", &reco_daughter_PFP_true_byHits_endProcess);
1476  fTree->Branch("reco_daughter_PFP_true_byHits_purity", &reco_daughter_PFP_true_byHits_purity);
1477  fTree->Branch("reco_daughter_PFP_true_byHits_completeness", &reco_daughter_PFP_true_byHits_completeness);
1478  fTree->Branch("reco_daughter_PFP_true_byE_PDG", &reco_daughter_PFP_true_byE_PDG);
1479  fTree->Branch("reco_daughter_PFP_true_byE_len", &reco_daughter_PFP_true_byE_len);
1480  fTree->Branch("reco_daughter_PFP_true_byE_completeness", &reco_daughter_PFP_true_byE_completeness);
1481  fTree->Branch("reco_daughter_PFP_true_byE_purity", &reco_daughter_PFP_true_byE_purity);
1482 
1483  fTree->Branch("reco_daughter_allTrack_ID", &reco_daughter_allTrack_ID);
1484  fTree->Branch("reco_daughter_allTrack_dQdX_SCE", &reco_daughter_allTrack_dQdX_SCE);
1485  fTree->Branch("reco_daughter_allTrack_calibrated_dQdX_SCE", &reco_daughter_allTrack_calibrated_dQdX_SCE);
1486  fTree->Branch("reco_daughter_allTrack_EField_SCE", &reco_daughter_allTrack_EField_SCE);
1487  fTree->Branch("reco_daughter_allTrack_dEdX_SCE", &reco_daughter_allTrack_dEdX_SCE);
1488  fTree->Branch("reco_daughter_allTrack_resRange_SCE", &reco_daughter_allTrack_resRange_SCE);
1489  fTree->Branch("reco_daughter_allTrack_calibrated_dEdX_SCE", &reco_daughter_allTrack_calibrated_dEdX_SCE);
1490 
1491  fTree->Branch("reco_daughter_allTrack_Chi2_proton", &reco_daughter_allTrack_Chi2_proton);
1492  fTree->Branch("reco_daughter_allTrack_Chi2_pion", &reco_daughter_allTrack_Chi2_pion);
1493  fTree->Branch("reco_daughter_allTrack_Chi2_muon", &reco_daughter_allTrack_Chi2_muon);
1494  fTree->Branch("reco_daughter_allTrack_Chi2_ndof", &reco_daughter_allTrack_Chi2_ndof);
1495  fTree->Branch("reco_daughter_allTrack_Chi2_ndof_pion", &reco_daughter_allTrack_Chi2_ndof_pion);
1496  fTree->Branch("reco_daughter_allTrack_Chi2_ndof_muon", &reco_daughter_allTrack_Chi2_ndof_muon);
1497 
1498 
1499  ///Calorimetry/chi2 planes 0 and 1
1500  fTree->Branch("reco_daughter_allTrack_Chi2_proton_plane0",
1502  fTree->Branch("reco_daughter_allTrack_Chi2_proton_plane1",
1504 
1505  fTree->Branch("reco_daughter_allTrack_Chi2_ndof_plane0",
1507  fTree->Branch("reco_daughter_allTrack_Chi2_ndof_plane1",
1509 
1510  fTree->Branch("reco_daughter_allTrack_calibrated_dEdX_SCE_plane0",
1512  fTree->Branch("reco_daughter_allTrack_calibrated_dEdX_SCE_plane1",
1514  fTree->Branch("reco_daughter_allTrack_resRange_plane0",
1516  fTree->Branch("reco_daughter_allTrack_resRange_plane1",
1518  ///////////////////////////////////
1519 
1520  fTree->Branch("reco_daughter_allTrack_Theta", &reco_daughter_allTrack_Theta);
1521  fTree->Branch("reco_daughter_allTrack_Phi", &reco_daughter_allTrack_Phi);
1522 
1523  fTree->Branch("reco_daughter_allTrack_len", &reco_daughter_allTrack_len);
1524  fTree->Branch("reco_daughter_allTrack_alt_len", &reco_daughter_allTrack_alt_len);
1525  fTree->Branch("reco_daughter_allTrack_startX", &reco_daughter_allTrack_startX);
1526  fTree->Branch("reco_daughter_allTrack_startY", &reco_daughter_allTrack_startY);
1527  fTree->Branch("reco_daughter_allTrack_startZ", &reco_daughter_allTrack_startZ);
1528  fTree->Branch("reco_daughter_allTrack_endX", &reco_daughter_allTrack_endX);
1529  fTree->Branch("reco_daughter_allTrack_endY", &reco_daughter_allTrack_endY);
1530  fTree->Branch("reco_daughter_allTrack_endZ", &reco_daughter_allTrack_endZ);
1531  fTree->Branch("reco_daughter_allTrack_calo_X", &reco_daughter_allTrack_calo_X);
1532  fTree->Branch("reco_daughter_allTrack_calo_Y", &reco_daughter_allTrack_calo_Y);
1533  fTree->Branch("reco_daughter_allTrack_calo_Z", &reco_daughter_allTrack_calo_Z);
1534 
1535  fTree->Branch("reco_daughter_allTrack_vertex_michel_score",
1537  fTree->Branch("reco_daughter_allTrack_vertex_nHits",
1539  //////
1540 
1541  fTree->Branch("reco_daughter_allShower_ID", &reco_daughter_allShower_ID);
1542  fTree->Branch("reco_daughter_allShower_len", &reco_daughter_allShower_len);
1543  fTree->Branch("reco_daughter_allShower_startX", &reco_daughter_allShower_startX);
1544  fTree->Branch("reco_daughter_allShower_startY", &reco_daughter_allShower_startY);
1545  fTree->Branch("reco_daughter_allShower_startZ", &reco_daughter_allShower_startZ);
1546  fTree->Branch("reco_daughter_allShower_dirX", &reco_daughter_allShower_dirX);
1547  fTree->Branch("reco_daughter_allShower_dirY", &reco_daughter_allShower_dirY);
1548  fTree->Branch("reco_daughter_allShower_dirZ", &reco_daughter_allShower_dirZ);
1549  fTree->Branch("reco_daughter_allShower_energy", &reco_daughter_allShower_energy);
1550 
1551 
1552 
1553  fTree->Branch("reco_daughter_PFP_ID", &reco_daughter_PFP_ID);
1554  fTree->Branch("reco_daughter_PFP_nHits", &reco_daughter_PFP_nHits);
1555  fTree->Branch("reco_daughter_PFP_nHits_collection",
1557  fTree->Branch("reco_daughter_PFP_trackScore", &reco_daughter_PFP_trackScore);
1558  fTree->Branch("reco_daughter_PFP_emScore", &reco_daughter_PFP_emScore);
1559  fTree->Branch("reco_daughter_PFP_michelScore", &reco_daughter_PFP_michelScore);
1560  fTree->Branch("reco_daughter_PFP_trackScore_collection", &reco_daughter_PFP_trackScore_collection);
1561  fTree->Branch("reco_daughter_PFP_emScore_collection", &reco_daughter_PFP_emScore_collection);
1562  fTree->Branch("reco_daughter_PFP_michelScore_collection", &reco_daughter_PFP_michelScore_collection);
1563  fTree->Branch("reco_daughter_pandora_type", &reco_daughter_pandora_type);
1564 
1565 
1566  fTree->Branch("true_beam_PDG", &true_beam_PDG);
1567  fTree->Branch("true_beam_mass", &true_beam_mass);
1568  fTree->Branch("true_beam_ID", &true_beam_ID);
1569  fTree->Branch("true_beam_endProcess", &true_beam_endProcess);
1570  fTree->Branch("true_beam_endX", &true_beam_endX);
1571  fTree->Branch("true_beam_endY", &true_beam_endY);
1572  fTree->Branch("true_beam_endZ", &true_beam_endZ);
1573  fTree->Branch("true_beam_endX_SCE", &true_beam_endX_SCE);
1574  fTree->Branch("true_beam_endY_SCE", &true_beam_endY_SCE);
1575  fTree->Branch("true_beam_endZ_SCE", &true_beam_endZ_SCE);
1576  fTree->Branch("true_beam_startX", &true_beam_startX);
1577  fTree->Branch("true_beam_startY", &true_beam_startY);
1578  fTree->Branch("true_beam_startZ", &true_beam_startZ);
1579 
1580  fTree->Branch("true_beam_startPx", &true_beam_startPx);
1581  fTree->Branch("true_beam_startPy", &true_beam_startPy);
1582  fTree->Branch("true_beam_startPz", &true_beam_startPz);
1583  fTree->Branch("true_beam_startP", &true_beam_startP);
1584 
1585  fTree->Branch("true_beam_endPx", &true_beam_endPx);
1586  fTree->Branch("true_beam_endPy", &true_beam_endPy);
1587  fTree->Branch("true_beam_endPz", &true_beam_endPz);
1588  fTree->Branch("true_beam_endP", &true_beam_endP);
1589  fTree->Branch("true_beam_endP2", &true_beam_endP2);
1590  fTree->Branch("true_beam_last_len", &true_beam_last_len);
1591 
1592  fTree->Branch("true_beam_startDirX", &true_beam_startDirX);
1593  fTree->Branch("true_beam_startDirY", &true_beam_startDirY);
1594  fTree->Branch("true_beam_startDirZ", &true_beam_startDirZ);
1595 
1596  fTree->Branch("true_beam_nElasticScatters", &true_beam_nElasticScatters);
1597  fTree->Branch("true_beam_elastic_costheta", &true_beam_elastic_costheta);
1598  fTree->Branch("true_beam_elastic_X", &true_beam_elastic_X);
1599  fTree->Branch("true_beam_elastic_Y", &true_beam_elastic_Y);
1600  fTree->Branch("true_beam_elastic_Z", &true_beam_elastic_Z);
1601  fTree->Branch("true_beam_elastic_deltaE", &true_beam_elastic_deltaE);
1602  fTree->Branch("true_beam_elastic_IDE_edep", &true_beam_elastic_IDE_edep);
1603  fTree->Branch("true_beam_IDE_totalDep", &true_beam_IDE_totalDep);
1604 
1605  fTree->Branch("true_beam_nHits", &true_beam_nHits);
1606  fTree->Branch("true_beam_reco_byHits_PFP_ID", &true_beam_reco_byHits_PFP_ID);
1607  fTree->Branch("true_beam_reco_byHits_PFP_nHits", &true_beam_reco_byHits_PFP_nHits);
1608  fTree->Branch("true_beam_reco_byHits_allTrack_ID", &true_beam_reco_byHits_allTrack_ID);
1609 
1610  fTree->Branch("true_daughter_nPi0", &true_daughter_nPi0);
1611  fTree->Branch("true_daughter_nPiPlus", &true_daughter_nPiPlus);
1612  fTree->Branch("true_daughter_nProton", &true_daughter_nProton);
1613  fTree->Branch("true_daughter_nNeutron", &true_daughter_nNeutron);
1614  fTree->Branch("true_daughter_nPiMinus", &true_daughter_nPiMinus);
1615  fTree->Branch("true_daughter_nNucleus", &true_daughter_nNucleus);
1616 
1617  fTree->Branch("reco_beam_vertex_slice", &reco_beam_vertex_slice);
1618 
1619  fTree->Branch("true_beam_daughter_PDG", &true_beam_daughter_PDG);
1620  fTree->Branch("true_beam_daughter_ID", &true_beam_daughter_ID);
1621  fTree->Branch("true_beam_daughter_len", &true_beam_daughter_len);
1622  fTree->Branch("true_beam_daughter_startX", &true_beam_daughter_startX);
1623  fTree->Branch("true_beam_daughter_startY", &true_beam_daughter_startY);
1624  fTree->Branch("true_beam_daughter_startZ", &true_beam_daughter_startZ);
1625  fTree->Branch("true_beam_daughter_startPx", &true_beam_daughter_startPx);
1626  fTree->Branch("true_beam_daughter_startPy", &true_beam_daughter_startPy);
1627  fTree->Branch("true_beam_daughter_startPz", &true_beam_daughter_startPz);
1628  fTree->Branch("true_beam_daughter_startP", &true_beam_daughter_startP);
1629  fTree->Branch("true_beam_daughter_endX", &true_beam_daughter_endX);
1630  fTree->Branch("true_beam_daughter_endY", &true_beam_daughter_endY);
1631  fTree->Branch("true_beam_daughter_endZ", &true_beam_daughter_endZ);
1632  fTree->Branch("true_beam_daughter_Process", &true_beam_daughter_Process);
1633  fTree->Branch("true_beam_daughter_endProcess", &true_beam_daughter_endProcess);
1634  fTree->Branch("true_beam_daughter_nHits", &true_beam_daughter_nHits);
1635 
1636  fTree->Branch("true_beam_daughter_reco_byHits_PFP_ID", &true_beam_daughter_reco_byHits_PFP_ID);
1637  fTree->Branch("true_beam_daughter_reco_byHits_PFP_nHits", &true_beam_daughter_reco_byHits_PFP_nHits);
1638  fTree->Branch("true_beam_daughter_reco_byHits_PFP_trackScore", &true_beam_daughter_reco_byHits_PFP_trackScore);
1639  fTree->Branch("true_beam_daughter_reco_byHits_allTrack_ID", &true_beam_daughter_reco_byHits_allTrack_ID);
1640  fTree->Branch("true_beam_daughter_reco_byHits_allTrack_startX", &true_beam_daughter_reco_byHits_allTrack_startX);
1641  fTree->Branch("true_beam_daughter_reco_byHits_allTrack_startY", &true_beam_daughter_reco_byHits_allTrack_startY);
1642  fTree->Branch("true_beam_daughter_reco_byHits_allTrack_startZ", &true_beam_daughter_reco_byHits_allTrack_startZ);
1643  fTree->Branch("true_beam_daughter_reco_byHits_allTrack_endX", &true_beam_daughter_reco_byHits_allTrack_endX);
1644  fTree->Branch("true_beam_daughter_reco_byHits_allTrack_endY", &true_beam_daughter_reco_byHits_allTrack_endY);
1645  fTree->Branch("true_beam_daughter_reco_byHits_allTrack_endZ", &true_beam_daughter_reco_byHits_allTrack_endZ);
1646  fTree->Branch("true_beam_daughter_reco_byHits_allTrack_len", &true_beam_daughter_reco_byHits_allTrack_len);
1647 
1648  fTree->Branch("true_beam_daughter_reco_byHits_allShower_ID", &true_beam_daughter_reco_byHits_allShower_ID);
1649  fTree->Branch("true_beam_daughter_reco_byHits_allShower_startX", &true_beam_daughter_reco_byHits_allShower_startX);
1650  fTree->Branch("true_beam_daughter_reco_byHits_allShower_startY", &true_beam_daughter_reco_byHits_allShower_startY);
1651  fTree->Branch("true_beam_daughter_reco_byHits_allShower_startZ", &true_beam_daughter_reco_byHits_allShower_startZ);
1652  fTree->Branch("true_beam_daughter_reco_byHits_allShower_len", &true_beam_daughter_reco_byHits_allShower_len);
1653 
1654  fTree->Branch("true_beam_Pi0_decay_ID", &true_beam_Pi0_decay_ID);
1655  fTree->Branch("true_beam_Pi0_decay_parID", &true_beam_Pi0_decay_parID);
1656  fTree->Branch("true_beam_Pi0_decay_PDG", &true_beam_Pi0_decay_PDG);
1657  fTree->Branch("true_beam_Pi0_decay_startP", &true_beam_Pi0_decay_startP);
1658  fTree->Branch("true_beam_Pi0_decay_startPx", &true_beam_Pi0_decay_startPx);
1659  fTree->Branch("true_beam_Pi0_decay_startPy", &true_beam_Pi0_decay_startPy);
1660  fTree->Branch("true_beam_Pi0_decay_startPz", &true_beam_Pi0_decay_startPz);
1661  fTree->Branch("true_beam_Pi0_decay_startX", &true_beam_Pi0_decay_startX);
1662  fTree->Branch("true_beam_Pi0_decay_startY", &true_beam_Pi0_decay_startY);
1663  fTree->Branch("true_beam_Pi0_decay_startZ", &true_beam_Pi0_decay_startZ);
1664 
1665  fTree->Branch("true_beam_Pi0_decay_len", &true_beam_Pi0_decay_len);
1666  fTree->Branch("true_beam_Pi0_decay_nHits", &true_beam_Pi0_decay_nHits);
1667  fTree->Branch("true_beam_Pi0_decay_reco_byHits_PFP_ID", &true_beam_Pi0_decay_reco_byHits_PFP_ID);
1668  fTree->Branch("true_beam_Pi0_decay_reco_byHits_PFP_nHits", &true_beam_Pi0_decay_reco_byHits_PFP_nHits);
1669  fTree->Branch("true_beam_Pi0_decay_reco_byHits_PFP_trackScore", &true_beam_Pi0_decay_reco_byHits_PFP_trackScore);
1670 
1671  fTree->Branch("true_beam_Pi0_decay_reco_byHits_allTrack_ID", &true_beam_Pi0_decay_reco_byHits_allTrack_ID);
1672  fTree->Branch("true_beam_Pi0_decay_reco_byHits_allTrack_startX", &true_beam_Pi0_decay_reco_byHits_allTrack_startX);
1673  fTree->Branch("true_beam_Pi0_decay_reco_byHits_allTrack_startY", &true_beam_Pi0_decay_reco_byHits_allTrack_startY);
1674  fTree->Branch("true_beam_Pi0_decay_reco_byHits_allTrack_startZ", &true_beam_Pi0_decay_reco_byHits_allTrack_startZ);
1675  fTree->Branch("true_beam_Pi0_decay_reco_byHits_allTrack_endX", &true_beam_Pi0_decay_reco_byHits_allTrack_endX);
1676  fTree->Branch("true_beam_Pi0_decay_reco_byHits_allTrack_endY", &true_beam_Pi0_decay_reco_byHits_allTrack_endY);
1677  fTree->Branch("true_beam_Pi0_decay_reco_byHits_allTrack_endZ", &true_beam_Pi0_decay_reco_byHits_allTrack_endZ);
1678  fTree->Branch("true_beam_Pi0_decay_reco_byHits_allTrack_len", &true_beam_Pi0_decay_reco_byHits_allTrack_len);
1679 
1680  fTree->Branch("true_beam_Pi0_decay_reco_byHits_allShower_ID", &true_beam_Pi0_decay_reco_byHits_allShower_ID);
1681  fTree->Branch("true_beam_Pi0_decay_reco_byHits_allShower_startX", &true_beam_Pi0_decay_reco_byHits_allShower_startX);
1682  fTree->Branch("true_beam_Pi0_decay_reco_byHits_allShower_startY", &true_beam_Pi0_decay_reco_byHits_allShower_startY);
1683  fTree->Branch("true_beam_Pi0_decay_reco_byHits_allShower_startZ", &true_beam_Pi0_decay_reco_byHits_allShower_startZ);
1684  fTree->Branch("true_beam_Pi0_decay_reco_byHits_allShower_len", &true_beam_Pi0_decay_reco_byHits_allShower_len);
1685 
1686  fTree->Branch("true_beam_grand_daughter_ID", &true_beam_grand_daughter_ID);
1687  fTree->Branch("true_beam_grand_daughter_parID", &true_beam_grand_daughter_parID);
1688  fTree->Branch("true_beam_grand_daughter_PDG", &true_beam_grand_daughter_PDG);
1689  fTree->Branch("true_beam_grand_daughter_nHits", &true_beam_grand_daughter_nHits);
1690  fTree->Branch("true_beam_grand_daughter_Process", &true_beam_grand_daughter_Process);
1691  fTree->Branch("true_beam_grand_daughter_endProcess", &true_beam_grand_daughter_endProcess);
1692 
1693  ////Matching reco to truth
1694  fTree->Branch("reco_beam_true_byE_endProcess", &reco_beam_true_byE_endProcess);
1695  fTree->Branch("reco_beam_true_byE_process", &reco_beam_true_byE_process);
1696  fTree->Branch("reco_beam_true_byE_origin", &reco_beam_true_byE_origin);
1697  fTree->Branch("reco_beam_true_byE_PDG", &reco_beam_true_byE_PDG);
1698  fTree->Branch("reco_beam_true_byE_ID", &reco_beam_true_byE_ID);
1699 
1700  fTree->Branch("reco_beam_true_byHits_endProcess", &reco_beam_true_byHits_endProcess);
1701  fTree->Branch("reco_beam_true_byHits_process", &reco_beam_true_byHits_process);
1702  fTree->Branch("reco_beam_true_byHits_origin", &reco_beam_true_byHits_origin);
1703  fTree->Branch("reco_beam_true_byHits_PDG", &reco_beam_true_byHits_PDG);
1704  fTree->Branch("reco_beam_true_byHits_ID", &reco_beam_true_byHits_ID);
1705 
1706  fTree->Branch("reco_beam_true_byE_matched", &reco_beam_true_byE_matched);
1707  fTree->Branch("reco_beam_true_byHits_matched", &reco_beam_true_byHits_matched);
1708  fTree->Branch("reco_beam_true_byHits_purity", &reco_beam_true_byHits_purity);
1709 
1710  fTree->Branch("true_beam_processes", &true_beam_processes);
1711 
1712  fTree->Branch("beam_inst_P", &beam_inst_P);
1713  fTree->Branch("beam_inst_C0", &beam_inst_C0);
1714  fTree->Branch("beam_inst_C1", &beam_inst_C1);
1715  fTree->Branch("beam_inst_C0_pressure", &beam_inst_C0_pressure);
1716  fTree->Branch("beam_inst_C1_pressure", &beam_inst_C1_pressure);
1717  fTree->Branch("beam_inst_TOF", &beam_inst_TOF);
1718  fTree->Branch("beam_inst_TOF_Chan", &beam_inst_TOF_Chan);
1719  fTree->Branch("beam_inst_X", &beam_inst_X);
1720  fTree->Branch("beam_inst_Y", &beam_inst_Y);
1721  fTree->Branch("beam_inst_Z", &beam_inst_Z);
1722  fTree->Branch("beam_inst_dirX", &beam_inst_dirX);
1723  fTree->Branch("beam_inst_dirY", &beam_inst_dirY);
1724  fTree->Branch("beam_inst_dirZ", &beam_inst_dirZ);
1725 
1726  fTree->Branch("beam_inst_nFibersP1", &beam_inst_nFibersP1);
1727  fTree->Branch("beam_inst_nFibersP2", &beam_inst_nFibersP2);
1728  fTree->Branch("beam_inst_nFibersP3", &beam_inst_nFibersP3);
1729  fTree->Branch("beam_inst_PDG_candidates", &beam_inst_PDG_candidates);
1730  fTree->Branch("beam_inst_nTracks", &beam_inst_nTracks);
1731  fTree->Branch("beam_inst_nMomenta", &beam_inst_nMomenta);
1732  fTree->Branch("beam_inst_valid", &beam_inst_valid);
1733  fTree->Branch("beam_inst_trigger", &beam_inst_trigger);
1734 
1735 
1736  fTree->Branch("reco_beam_Chi2_proton", &reco_beam_Chi2_proton);
1737  fTree->Branch("reco_beam_Chi2_ndof", &reco_beam_Chi2_ndof);
1738 
1739 
1740  fTree->Branch("reco_daughter_allTrack_momByRange_proton", &reco_daughter_allTrack_momByRange_proton);
1741  fTree->Branch("reco_daughter_allTrack_momByRange_muon", &reco_daughter_allTrack_momByRange_muon);
1742  fTree->Branch("reco_beam_momByRange_proton", &reco_beam_momByRange_proton);
1743  fTree->Branch("reco_beam_momByRange_muon", &reco_beam_momByRange_muon);
1744 
1745  fTree->Branch("reco_daughter_allTrack_momByRange_alt_proton", &reco_daughter_allTrack_momByRange_alt_proton);
1746  fTree->Branch("reco_daughter_allTrack_momByRange_alt_muon", &reco_daughter_allTrack_momByRange_alt_muon);
1747  fTree->Branch("reco_beam_momByRange_alt_proton", &reco_beam_momByRange_alt_proton);
1748  fTree->Branch("reco_beam_momByRange_alt_muon", &reco_beam_momByRange_alt_muon);
1749 
1750  fTree->Branch("reco_beam_true_byE_endPx", &reco_beam_true_byE_endPx);
1751  fTree->Branch("reco_beam_true_byE_endPy", &reco_beam_true_byE_endPy);
1752  fTree->Branch("reco_beam_true_byE_endPz", &reco_beam_true_byE_endPz);
1753  fTree->Branch("reco_beam_true_byE_endE", &reco_beam_true_byE_endE);
1754  fTree->Branch("reco_beam_true_byE_endP", &reco_beam_true_byE_endP);
1755 
1756  fTree->Branch("reco_beam_true_byE_startPx", &reco_beam_true_byE_startPx);
1757  fTree->Branch("reco_beam_true_byE_startPy", &reco_beam_true_byE_startPy);
1758  fTree->Branch("reco_beam_true_byE_startPz", &reco_beam_true_byE_startPz);
1759  fTree->Branch("reco_beam_true_byE_startE", &reco_beam_true_byE_startE);
1760  fTree->Branch("reco_beam_true_byE_startP", &reco_beam_true_byE_startP);
1761 
1762 
1763  fTree->Branch("reco_beam_true_byHits_endPx", &reco_beam_true_byHits_endPx);
1764  fTree->Branch("reco_beam_true_byHits_endPy", &reco_beam_true_byHits_endPy);
1765  fTree->Branch("reco_beam_true_byHits_endPz", &reco_beam_true_byHits_endPz);
1766  fTree->Branch("reco_beam_true_byHits_endE", &reco_beam_true_byHits_endE);
1767  fTree->Branch("reco_beam_true_byHits_endP", &reco_beam_true_byHits_endP);
1768 
1769  fTree->Branch("reco_beam_true_byHits_startPx", &reco_beam_true_byHits_startPx);
1770  fTree->Branch("reco_beam_true_byHits_startPy", &reco_beam_true_byHits_startPy);
1771  fTree->Branch("reco_beam_true_byHits_startPz", &reco_beam_true_byHits_startPz);
1772  fTree->Branch("reco_beam_true_byHits_startE", &reco_beam_true_byHits_startE);
1773  fTree->Branch("reco_beam_true_byHits_startP", &reco_beam_true_byHits_startP);
1774 
1775  fTree->Branch("reco_beam_incidentEnergies", &reco_beam_incidentEnergies);
1776  fTree->Branch("reco_beam_interactingEnergy", &reco_beam_interactingEnergy);
1777  fTree->Branch("reco_beam_incidentEnergies_allTrack", &reco_beam_incidentEnergies_allTrack);
1778  fTree->Branch("reco_beam_interactingEnergy_allTrack", &reco_beam_interactingEnergy_allTrack);
1779  fTree->Branch("true_beam_incidentEnergies", &true_beam_incidentEnergies);
1780  fTree->Branch("true_beam_interactingEnergy", &true_beam_interactingEnergy);
1781  fTree->Branch("true_beam_slices", &true_beam_slices);
1782  fTree->Branch("true_beam_slices_found", &true_beam_slices_found);
1783  fTree->Branch("true_beam_slices_deltaE", &true_beam_slices_deltaE);
1784  fTree->Branch("em_energy", &em_energy);
1785  fTree->Branch("true_beam_traj_X", &true_beam_traj_X);
1786  fTree->Branch("true_beam_traj_Y", &true_beam_traj_Y);
1787  fTree->Branch("true_beam_traj_Z", &true_beam_traj_Z);
1788  fTree->Branch("true_beam_traj_Px", &true_beam_traj_Px);
1789  fTree->Branch("true_beam_traj_Py", &true_beam_traj_Py);
1790  fTree->Branch("true_beam_traj_Pz", &true_beam_traj_Pz);
1791  fTree->Branch("true_beam_traj_KE", &true_beam_traj_KE);
1792  fTree->Branch("true_beam_traj_X_SCE", &true_beam_traj_X_SCE);
1793  fTree->Branch("true_beam_traj_Y_SCE", &true_beam_traj_Y_SCE);
1794  fTree->Branch("true_beam_traj_Z_SCE", &true_beam_traj_Z_SCE);
1795 
1796  fTree->Branch("g4rw_primary_weights", &g4rw_primary_weights);
1797  fTree->Branch("g4rw_primary_plus_sigma_weight", &g4rw_primary_plus_sigma_weight);
1798  fTree->Branch("g4rw_primary_minus_sigma_weight", &g4rw_primary_minus_sigma_weight);
1799  fTree->Branch("g4rw_primary_var", &g4rw_primary_var);
1800 
1801  fTree->Branch("g4rw_alt_primary_plus_sigma_weight",
1803  fTree->Branch("g4rw_alt_primary_minus_sigma_weight",
1805 
1806  fTree->Branch("g4rw_full_primary_plus_sigma_weight",
1808  fTree->Branch("g4rw_full_primary_minus_sigma_weight",
1810  fTree->Branch("g4rw_full_grid_weights", &g4rw_full_grid_weights);
1811  fTree->Branch("g4rw_full_grid_coeffs", &g4rw_full_grid_coeffs);
1812  fTree->Branch("g4rw_full_grid_piplus_weights", &g4rw_full_grid_piplus_weights);
1813  fTree->Branch("g4rw_full_grid_piplus_coeffs", &g4rw_full_grid_piplus_coeffs);
1814  fTree->Branch("g4rw_full_grid_piplus_weights_fake_data", &g4rw_full_grid_piplus_weights_fake_data);
1815  fTree->Branch("g4rw_full_grid_piminus_weights", &g4rw_full_grid_piminus_weights);
1816  fTree->Branch("g4rw_full_grid_proton_weights", &g4rw_full_grid_proton_weights);
1817  fTree->Branch("g4rw_full_grid_proton_coeffs", &g4rw_full_grid_proton_coeffs);
1818  fTree->Branch("g4rw_full_grid_neutron_weights", &g4rw_full_grid_neutron_weights);
1819  fTree->Branch("g4rw_full_grid_neutron_coeffs", &g4rw_full_grid_neutron_coeffs);
1820  fTree->Branch("g4rw_full_grid_kplus_weights", &g4rw_full_grid_kplus_weights);
1821  fTree->Branch("g4rw_full_grid_kplus_coeffs", &g4rw_full_grid_kplus_coeffs);
1822  fTree->Branch("g4rw_primary_grid_weights", &g4rw_primary_grid_weights);
1823  fTree->Branch("g4rw_primary_grid_pair_weights", &g4rw_primary_grid_pair_weights);
1824 
1825  if( fSaveHits ){
1826  fTree->Branch( "reco_beam_spacePts_X", &reco_beam_spacePts_X );
1827  fTree->Branch( "reco_beam_spacePts_Y", &reco_beam_spacePts_Y );
1828  fTree->Branch( "reco_beam_spacePts_Z", &reco_beam_spacePts_Z );
1829 
1830  fTree->Branch( "reco_daughter_spacePts_X", &reco_daughter_spacePts_X );
1831  fTree->Branch( "reco_daughter_spacePts_Y", &reco_daughter_spacePts_Y );
1832  fTree->Branch( "reco_daughter_spacePts_Z", &reco_daughter_spacePts_Z );
1833 
1834  fTree->Branch( "reco_daughter_shower_spacePts_X", &reco_daughter_shower_spacePts_X );
1835  fTree->Branch( "reco_daughter_shower_spacePts_Y", &reco_daughter_shower_spacePts_Y );
1836  fTree->Branch( "reco_daughter_shower_spacePts_Z", &reco_daughter_shower_spacePts_Z );
1837  }
1838 
1839 }
std::vector< double > true_beam_traj_X_SCE
std::vector< int > beam_inst_TOF_Chan
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_PFP_trackScore
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_startX
std::vector< int > reco_daughter_PFP_true_byE_PDG
double reco_beam_PFP_trackScore_collection_weight_by_charge
std::vector< double > reco_beam_calo_startDirX
std::vector< double > reco_beam_calo_X
std::vector< double > true_beam_incidentEnergies
std::vector< std::vector< double > > reco_daughter_allTrack_calo_X
std::vector< int > reco_daughter_PFP_true_byHits_ID
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_startX
std::vector< double > reco_daughter_allShower_startY
std::vector< double > reco_beam_spacePts_Y
std::vector< double > reco_daughter_PFP_true_byHits_startZ
std::vector< std::vector< double > > g4rw_primary_grid_weights
std::vector< double > reco_beam_dQ_NoSCE
std::vector< int > reco_daughter_allTrack_Chi2_ndof_plane1
std::vector< double > g4rw_full_primary_plus_sigma_weight
std::vector< std::vector< double > > reco_daughter_allTrack_dQdX_SCE
std::vector< double > true_beam_daughter_startPz
std::vector< std::vector< double > > reco_daughter_allTrack_calo_Z
std::string reco_beam_true_byE_endProcess
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_PFP_trackScore
std::vector< double > reco_beam_calo_Z_allTrack
std::vector< std::vector< double > > reco_daughter_shower_spacePts_Z
std::vector< double > reco_daughter_PFP_true_byHits_startX
std::vector< double > reco_daughter_allTrack_Chi2_muon
std::vector< int > true_beam_Pi0_decay_ID
std::vector< double > true_beam_elastic_IDE_edep
std::vector< int > reco_daughter_PFP_true_byHits_parID
std::vector< double > beam_particle_scores
std::vector< double > reco_beam_dEdX_NoSCE
std::vector< double > true_beam_Pi0_decay_len
std::vector< double > reco_track_michel_score_weight_by_charge
std::vector< int > true_beam_slices
std::vector< double > true_beam_slices_deltaE
std::vector< double > reco_beam_TrkPitch_NoSCE
std::vector< double > reco_daughter_allTrack_alt_len
std::vector< double > reco_beam_EField_SCE
std::vector< double > reco_daughter_allTrack_endZ
std::vector< int > reco_daughter_PFP_nHits_collection
std::vector< double > reco_beam_calo_Y_allTrack
std::vector< double > true_beam_Pi0_decay_startZ
std::vector< double > true_beam_Pi0_decay_startPx
std::vector< double > reco_beam_calo_wire_NoSCE
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dQdX_SCE
std::vector< double > reco_beam_resRange_SCE
std::vector< double > g4rw_full_primary_minus_sigma_weight
std::vector< int > beam_inst_PDG_candidates
std::vector< double > reco_daughter_allTrack_startZ
std::vector< std::string > true_beam_grand_daughter_Process
std::vector< double > reco_daughter_allTrack_Chi2_pion
std::vector< double > reco_track_startZ
std::vector< double > reco_track_startX
std::vector< std::string > true_beam_daughter_endProcess
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_startZ
std::vector< std::vector< double > > g4rw_full_grid_piplus_weights
std::vector< int > reco_daughter_PFP_true_byHits_PDG
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_endX
double reco_beam_PFP_emScore_collection_weight_by_charge
std::vector< double > reco_daughter_allTrack_momByRange_proton
std::vector< double > reco_beam_calo_wire_z
std::vector< double > reco_beam_spacePts_Z
std::vector< double > reco_daughter_allTrack_Chi2_proton_plane1
std::vector< double > reco_beam_allTrack_calibrated_dEdX
std::vector< double > true_beam_daughter_startP
std::vector< double > g4rw_primary_minus_sigma_weight
std::vector< double > reco_daughter_allTrack_momByRange_alt_muon
std::vector< int > reco_daughter_allShower_ID
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_startZ
std::vector< double > reco_track_endX
std::vector< double > reco_beam_calo_startDirY
std::vector< std::string > true_beam_daughter_Process
std::vector< int > reco_daughter_allTrack_Chi2_ndof
std::vector< double > reco_daughter_PFP_michelScore
std::vector< double > reco_daughter_PFP_true_byHits_startPy
std::vector< std::vector< int > > true_beam_reco_byHits_PFP_nHits
std::vector< double > reco_track_endZ
std::vector< double > reco_beam_calo_X_allTrack
std::vector< double > reco_beam_incidentEnergies_allTrack
std::vector< double > true_beam_traj_Z_SCE
std::vector< std::vector< double > > g4rw_full_grid_coeffs
std::vector< int > reco_daughter_PFP_nHits
std::vector< double > reco_daughter_PFP_true_byHits_startE
std::vector< double > reco_beam_calo_Y
std::vector< double > g4rw_alt_primary_minus_sigma_weight
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_startX
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_endX
double reco_beam_vertex_michel_score_weight_by_charge_allTrack
std::vector< double > reco_daughter_PFP_true_byE_purity
std::vector< std::vector< double > > g4rw_full_grid_proton_weights
std::vector< int > reco_beam_calo_TPC_NoSCE
std::vector< double > true_beam_daughter_startY
std::string reco_beam_true_byHits_endProcess
std::vector< double > reco_beam_calo_wire
std::vector< std::string > true_beam_processes
std::vector< double > true_beam_traj_Y
std::vector< std::vector< double > > reco_daughter_allTrack_dEdX_SCE
std::vector< double > true_beam_Pi0_decay_startPy
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_endY
std::vector< size_t > reco_daughter_PFP_true_byHits_sharedHits
EDIT: quality.
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_PFP_ID
std::vector< double > reco_beam_TrkPitch_SCE_allTrack
std::vector< std::vector< double > > reco_daughter_allTrack_calo_Y
std::vector< double > reco_daughter_allTrack_Phi
std::vector< size_t > reco_daughter_PFP_true_byHits_emHits
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dEdX_SCE_plane0
std::vector< double > reco_beam_calibrated_dQdX_SCE
std::vector< std::vector< int > > true_beam_reco_byHits_PFP_ID
std::vector< double > true_beam_daughter_startPx
std::vector< std::string > g4rw_primary_var
std::vector< double > true_beam_traj_Y_SCE
std::vector< int > reco_daughter_PFP_true_byHits_parPDG
std::vector< double > reco_daughter_PFP_true_byHits_startPx
std::vector< double > reco_beam_TrkPitch_SCE
std::vector< std::vector< double > > reco_daughter_allTrack_EField_SCE
double reco_beam_vertex_michel_score_weight_by_charge
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_allTrack_ID
std::vector< double > reco_beam_spacePts_X
std::vector< double > true_beam_daughter_startPy
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_len
std::vector< std::vector< double > > g4rw_full_grid_proton_coeffs
std::vector< double > reco_daughter_PFP_true_byHits_len
std::vector< std::vector< double > > g4rw_full_grid_neutron_coeffs
std::vector< double > reco_daughter_allTrack_endY
std::vector< double > reco_track_michel_score
std::vector< double > g4rw_alt_primary_plus_sigma_weight
std::vector< std::vector< int > > true_beam_reco_byHits_allTrack_ID
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dEdX_SCE_plane1
std::vector< double > true_beam_traj_Px
std::vector< int > reco_beam_calo_TPC
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_PFP_ID
std::vector< double > true_beam_elastic_deltaE
std::vector< int > beam_track_IDs
std::vector< double > reco_daughter_allShower_startX
std::vector< double > g4rw_primary_grid_pair_weights
std::vector< std::vector< double > > g4rw_full_grid_piminus_weights
std::vector< double > reco_beam_allTrack_resRange
std::vector< double > reco_daughter_allTrack_endX
std::vector< int > reco_daughter_allTrack_ID
std::vector< double > true_beam_traj_Pz
std::vector< double > true_beam_elastic_costheta
std::vector< std::vector< double > > g4rw_full_grid_weights
std::vector< std::string > true_beam_grand_daughter_endProcess
std::vector< std::vector< double > > g4rw_full_grid_kplus_weights
std::vector< std::vector< double > > reco_daughter_allTrack_resRange_SCE
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_startZ
std::vector< double > g4rw_primary_plus_sigma_weight
std::vector< double > reco_beam_calibrated_dEdX_SCE
std::vector< double > reco_track_endY
std::vector< double > reco_daughter_PFP_true_byHits_completeness
std::vector< double > reco_daughter_PFP_true_byE_completeness
std::vector< double > reco_daughter_allTrack_vertex_michel_score
std::vector< int > reco_daughter_PFP_ID
std::vector< double > true_beam_daughter_endZ
std::vector< double > reco_daughter_allShower_dirY
std::vector< int > reco_track_ID
std::vector< int > reco_daughter_allTrack_vertex_nHits
std::vector< double > reco_daughter_PFP_true_byHits_startY
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_len
std::vector< double > reco_beam_dQdX_SCE
std::vector< double > reco_beam_calo_wire_z_NoSCE
std::vector< double > reco_daughter_PFP_true_byHits_startP
std::vector< int > true_beam_Pi0_decay_nHits
std::vector< std::string > reco_daughter_PFP_true_byHits_endProcess
std::vector< double > true_beam_Pi0_decay_startY
std::vector< double > true_beam_elastic_Y
std::vector< int > true_beam_Pi0_decay_parID
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dEdX_SCE
std::vector< double > reco_daughter_allTrack_Theta
std::vector< std::vector< double > > reco_daughter_spacePts_Y
std::vector< double > reco_track_startY
std::vector< int > reco_daughter_pandora_type
std::vector< std::vector< double > > g4rw_full_grid_piplus_weights_fake_data
std::vector< std::vector< double > > reco_daughter_allTrack_resRange_plane1
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_allTrack_ID
std::vector< double > reco_daughter_PFP_michelScore_collection
std::vector< double > reco_daughter_PFP_true_byHits_endX
std::vector< double > true_beam_daughter_endY
std::vector< double > reco_beam_calo_wire_allTrack
std::vector< double > true_beam_daughter_len
std::vector< std::vector< double > > reco_daughter_spacePts_Z
std::vector< double > true_beam_traj_KE
std::vector< int > true_beam_daughter_PDG
std::vector< double > reco_beam_calibrated_dEdX_NoSCE
std::vector< int > true_beam_grand_daughter_nHits
std::vector< double > reco_beam_calo_Z
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_PFP_nHits
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_startY
std::vector< double > reco_daughter_allTrack_Chi2_proton
std::vector< double > reco_beam_calo_endDirX
std::vector< double > true_beam_daughter_endX
std::vector< double > g4rw_primary_weights
std::vector< int > true_beam_daughter_nHits
std::vector< int > true_beam_Pi0_decay_PDG
std::vector< int > true_beam_daughter_ID
std::vector< double > reco_daughter_allShower_dirX
std::vector< double > true_beam_daughter_startZ
std::vector< double > reco_daughter_allTrack_Chi2_proton_plane0
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_endZ
std::vector< double > true_beam_daughter_startX
std::vector< double > true_beam_traj_Py
std::vector< int > reco_track_nHits
std::vector< std::string > reco_daughter_PFP_true_byHits_process
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_startZ
std::vector< double > reco_daughter_PFP_emScore
std::vector< double > true_beam_traj_Z
std::vector< double > true_beam_Pi0_decay_startPz
std::vector< int > true_beam_grand_daughter_PDG
std::vector< std::vector< double > > reco_daughter_spacePts_X
std::vector< double > reco_daughter_PFP_true_byHits_endY
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_PFP_nHits
std::vector< double > reco_beam_calo_endDirY
std::vector< double > reco_beam_incidentEnergies
std::vector< std::vector< double > > reco_daughter_shower_spacePts_Y
std::vector< std::vector< double > > reco_daughter_allTrack_resRange_plane0
double reco_beam_PFP_michelScore_collection_weight_by_charge
std::vector< int > true_beam_grand_daughter_ID
std::vector< int > true_beam_slices_found
std::vector< double > reco_beam_resRange_NoSCE
std::vector< double > reco_beam_dQ
std::vector< double > reco_beam_dEdX_SCE
std::vector< double > true_beam_Pi0_decay_startX
std::vector< double > reco_daughter_PFP_trackScore
std::vector< double > true_beam_Pi0_decay_startP
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_len
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_allShower_ID
std::vector< std::vector< double > > g4rw_full_grid_neutron_weights
std::vector< double > reco_daughter_allShower_energy
std::vector< double > reco_daughter_allTrack_startX
std::vector< double > reco_daughter_PFP_true_byE_len
std::vector< double > beam_inst_TOF
std::vector< double > true_beam_elastic_Z
std::vector< double > true_beam_traj_X
std::vector< int > reco_daughter_allTrack_Chi2_ndof_plane0
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_startY
std::vector< double > reco_beam_calo_startDirZ
std::vector< std::vector< double > > reco_daughter_shower_spacePts_X
std::vector< double > reco_daughter_allTrack_momByRange_muon
std::vector< double > reco_daughter_PFP_trackScore_collection
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_endZ
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_endY
std::vector< double > reco_daughter_allShower_dirZ
std::vector< int > reco_daughter_PFP_true_byHits_origin
std::vector< double > reco_daughter_allShower_len
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_allShower_ID
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_startX
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_len
std::string reco_beam_true_byHits_process
std::vector< std::vector< double > > g4rw_full_grid_kplus_coeffs
std::vector< int > reco_daughter_allTrack_Chi2_ndof_pion
std::vector< double > reco_daughter_PFP_true_byHits_endZ
std::vector< int > true_beam_grand_daughter_parID
std::vector< double > reco_beam_dQdX_NoSCE
std::vector< double > reco_daughter_allTrack_len
std::vector< double > reco_daughter_PFP_true_byHits_startPz
std::vector< std::vector< double > > g4rw_full_grid_piplus_coeffs
std::vector< double > reco_daughter_PFP_emScore_collection
Event finding and building.
std::vector< double > reco_beam_calo_endDirZ
std::vector< int > reco_daughter_allTrack_Chi2_ndof_muon
std::vector< double > reco_daughter_allShower_startZ
std::vector< double > reco_daughter_allTrack_momByRange_alt_proton
std::vector< double > reco_beam_calo_tick
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_startY
std::vector< double > reco_daughter_PFP_true_byHits_purity
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_startY
std::vector< double > true_beam_elastic_X
std::vector< double > reco_daughter_allTrack_startY
void pduneana::PDSPAnalyzer::DaughterMatchInfo ( const art::Event evt,
const recob::PFParticle daughterPFP,
detinfo::DetectorClocksData const &  clockData 
)
private

Definition at line 4354 of file PDSPAnalyzer_module.cc.

4356  {
4357 
4358  const sim::ParticleList & plist = pi_serv->ParticleList();
4359  protoana::MCParticleSharedHits match = truthUtil.GetMCParticleByHits( clockData, *daughterPFP, evt, fPFParticleTag, fHitTag );
4360  if( match.particle ){
4361 
4362  reco_daughter_PFP_true_byHits_PDG.push_back( match.particle->PdgCode() );
4363  reco_daughter_PFP_true_byHits_ID.push_back( match.particle->TrackId() );
4364  reco_daughter_PFP_true_byHits_parID.push_back( match.particle->Mother() );
4366  ( (match.particle->Mother() > 0) ? plist[ match.particle->Mother() ]->PdgCode() : 0 )
4367  );
4368 
4371  pi_serv->TrackIdToMCTruth_P(match.particle->TrackId())->Origin()
4372  );
4375 
4377  reco_daughter_PFP_true_byHits_startX.push_back( match.particle->Position(0).X() );
4378  reco_daughter_PFP_true_byHits_startY.push_back( match.particle->Position(0).Y() );
4379  reco_daughter_PFP_true_byHits_startZ.push_back( match.particle->Position(0).Z() );
4380 
4381  reco_daughter_PFP_true_byHits_endX.push_back( match.particle->EndPosition().X() );
4382  reco_daughter_PFP_true_byHits_endY.push_back( match.particle->EndPosition().Y() );
4383  reco_daughter_PFP_true_byHits_endZ.push_back( match.particle->EndPosition().Z() );
4384 
4385  reco_daughter_PFP_true_byHits_startPx.push_back( match.particle->Px() );
4386  reco_daughter_PFP_true_byHits_startPy.push_back( match.particle->Py() );
4387  reco_daughter_PFP_true_byHits_startPz.push_back( match.particle->Pz() );
4388  reco_daughter_PFP_true_byHits_startE.push_back( match.particle->E() );
4390  sqrt(match.particle->Px()*match.particle->Px() +
4391  match.particle->Py()*match.particle->Py() +
4392  match.particle->Pz()*match.particle->Pz()) );
4394 
4395  auto list = truthUtil.GetMCParticleListByHits( clockData, *daughterPFP, evt, fPFParticleTag, fHitTag );
4396  double total = 0.;
4397  double matched_hits = 0.;
4398  for( size_t j = 0; j < list.size(); ++j ){
4399  if( list[j].particle == match.particle ){
4400  matched_hits = list[j].nSharedHits + list[j].nSharedDeltaRayHits;
4401  }
4402  total += list[j].nSharedHits + list[j].nSharedDeltaRayHits;
4403  }
4404 
4405  reco_daughter_PFP_true_byHits_purity.push_back( matched_hits / total );
4406 
4407  double totalTruth = truthUtil.GetMCParticleHits( clockData, *match.particle, evt, fHitTag).size();
4408  double sharedHits = truthUtil.GetSharedHits( clockData, *match.particle, *daughterPFP, evt, fPFParticleTag).size();
4409  reco_daughter_PFP_true_byHits_completeness.push_back( sharedHits/totalTruth );
4410  }
4411  else{
4412  reco_daughter_PFP_true_byHits_PDG.push_back( -999 );
4413  reco_daughter_PFP_true_byHits_ID.push_back( -999 );
4414  reco_daughter_PFP_true_byHits_origin.push_back( -999 );
4415  reco_daughter_PFP_true_byHits_parID.push_back( -999 );
4416  reco_daughter_PFP_true_byHits_parPDG.push_back( -999 );
4417  reco_daughter_PFP_true_byHits_process.push_back( "empty" );
4418  reco_daughter_PFP_true_byHits_sharedHits.push_back( -999 );
4419  reco_daughter_PFP_true_byHits_emHits.push_back( -999 );
4420 
4421  reco_daughter_PFP_true_byHits_len.push_back( -999. );
4422  reco_daughter_PFP_true_byHits_startX.push_back( -999. );
4423  reco_daughter_PFP_true_byHits_startY.push_back( -999. );
4424  reco_daughter_PFP_true_byHits_startZ.push_back( -999. );
4425  reco_daughter_PFP_true_byHits_endX.push_back( -999. );
4426  reco_daughter_PFP_true_byHits_endY.push_back( -999. );
4427  reco_daughter_PFP_true_byHits_endZ.push_back( -999. );
4428  reco_daughter_PFP_true_byHits_startPx.push_back( -999. );
4429  reco_daughter_PFP_true_byHits_startPy.push_back( -999. );
4430  reco_daughter_PFP_true_byHits_startPz.push_back( -999. );
4431  reco_daughter_PFP_true_byHits_startP.push_back( -999. );
4432  reco_daughter_PFP_true_byHits_startE.push_back( -999. );
4433  reco_daughter_PFP_true_byHits_endProcess.push_back("empty");
4434  reco_daughter_PFP_true_byHits_purity.push_back( -999. );
4435  reco_daughter_PFP_true_byHits_completeness.push_back( -999. );
4436  }
4437 
4438  //Matching by energy
4439  const simb::MCParticle* true_daughter_byE = truthUtil.GetMCParticleFromPFParticle(clockData, *daughterPFP, evt, fPFParticleTag);
4440  if( true_daughter_byE ){
4441  reco_daughter_PFP_true_byE_PDG.push_back( true_daughter_byE->PdgCode() );
4442  reco_daughter_PFP_true_byE_len.push_back( true_daughter_byE->Trajectory().TotalLength() );
4443  double purity = truthUtil.GetPurity( clockData, *daughterPFP, evt, fPFParticleTag);
4444  double completeness = truthUtil.GetCompleteness( clockData, *daughterPFP, evt, fPFParticleTag, fHitTag );
4445  reco_daughter_PFP_true_byE_purity.push_back( purity );
4446  reco_daughter_PFP_true_byE_completeness.push_back( completeness );
4447  }
4448  else {
4449  reco_daughter_PFP_true_byE_PDG.push_back( -999 );
4450  reco_daughter_PFP_true_byE_len.push_back( -999. );
4451  reco_daughter_PFP_true_byE_purity.push_back( -999. );
4452  reco_daughter_PFP_true_byE_completeness.push_back( -999. );
4453  }
4454 
4455 }
double E(const int i=0) const
Definition: MCParticle.h:233
std::vector< int > reco_daughter_PFP_true_byE_PDG
std::vector< int > reco_daughter_PFP_true_byHits_ID
std::vector< double > reco_daughter_PFP_true_byHits_startZ
const TLorentzVector & Position(const int i=0) const
Definition: MCParticle.h:219
int PdgCode() const
Definition: MCParticle.h:212
std::vector< double > reco_daughter_PFP_true_byHits_startX
double Py(const int i=0) const
Definition: MCParticle.h:231
std::vector< int > reco_daughter_PFP_true_byHits_parID
const TLorentzVector & EndPosition() const
Definition: MCParticle.h:225
const simb::MCTrajectory & Trajectory() const
Definition: MCParticle.h:253
int Mother() const
Definition: MCParticle.h:213
double GetCompleteness(detinfo::DetectorClocksData const &clockData, const T &recobj, const art::Event &evt, std::string recoModule, std::string hitModule) const
std::vector< int > reco_daughter_PFP_true_byHits_PDG
double Px(const int i=0) const
Definition: MCParticle.h:230
std::vector< double > reco_daughter_PFP_true_byHits_startPy
const MCParticleSharedHits GetMCParticleByHits(detinfo::DetectorClocksData const &clockData, const T &recobj, const art::Event &evt, std::string recoModule, std::string hitModule) const
std::vector< double > reco_daughter_PFP_true_byHits_startE
std::string Process() const
Definition: MCParticle.h:215
std::vector< double > reco_daughter_PFP_true_byE_purity
std::vector< size_t > reco_daughter_PFP_true_byHits_sharedHits
EDIT: quality.
int TrackId() const
Definition: MCParticle.h:210
std::vector< size_t > reco_daughter_PFP_true_byHits_emHits
std::vector< const recob::Hit * > GetMCParticleHits(detinfo::DetectorClocksData const &clockData, const simb::MCParticle &mcpart, const art::Event &evt, std::string hitModule, bool use_eve=true) const
std::vector< int > reco_daughter_PFP_true_byHits_parPDG
std::vector< double > reco_daughter_PFP_true_byHits_startPx
std::vector< MCParticleSharedHits > GetMCParticleListByHits(detinfo::DetectorClocksData const &clockData, const T &recobj, const art::Event &evt, std::string recoModule, std::string hitModule) const
std::vector< double > reco_daughter_PFP_true_byHits_len
std::string EndProcess() const
Definition: MCParticle.h:216
double GetPurity(detinfo::DetectorClocksData const &clockData, const recob::PFParticle &pfpart, const art::Event &evt, std::string pfparticleModule) const
const art::Ptr< simb::MCTruth > & TrackIdToMCTruth_P(int id) const
const simb::MCParticle * GetMCParticleFromPFParticle(detinfo::DetectorClocksData const &clockData, const recob::PFParticle &pfpart, art::Event const &evt, std::string pfparticleModule) const
std::vector< double > reco_daughter_PFP_true_byHits_completeness
std::vector< double > reco_daughter_PFP_true_byE_completeness
std::vector< double > reco_daughter_PFP_true_byHits_startY
std::vector< double > reco_daughter_PFP_true_byHits_startP
std::vector< std::string > reco_daughter_PFP_true_byHits_endProcess
std::vector< double > reco_daughter_PFP_true_byHits_endX
const sim::ParticleList & ParticleList() const
art::ServiceHandle< cheat::ParticleInventoryService > pi_serv
protoana::ProtoDUNETruthUtils truthUtil
const simb::MCParticle * particle
std::vector< std::string > reco_daughter_PFP_true_byHits_process
std::vector< double > reco_daughter_PFP_true_byHits_endY
double TotalLength() const
double Pz(const int i=0) const
Definition: MCParticle.h:232
std::vector< double > reco_daughter_PFP_true_byE_len
std::vector< int > reco_daughter_PFP_true_byHits_origin
std::vector< double > reco_daughter_PFP_true_byHits_endZ
std::vector< const recob::Hit * > GetSharedHits(detinfo::DetectorClocksData const &clockData, const simb::MCParticle &mcpart, const recob::PFParticle &pfpart, const art::Event &evt, std::string pfparticleModule, bool delta_ray=false) const
std::vector< double > reco_daughter_PFP_true_byHits_startPz
std::vector< double > reco_daughter_PFP_true_byHits_purity
void pduneana::PDSPAnalyzer::DaughterPFPInfo ( const art::Event evt,
const recob::PFParticle particle,
detinfo::DetectorClocksData const &  clockData,
anab::MVAReader< recob::Hit, 4 > *  hitResults 
)
private

Definition at line 3683 of file PDSPAnalyzer_module.cc.

3686  {
3687 
3688  //Get all PFParticles in the event
3689  auto pfpVec
3690  = evt.getValidHandle<std::vector<recob::PFParticle>>(fPFParticleTag);
3691 
3692  auto sce = lar::providerFrom<spacecharge::SpaceChargeService>();
3693  auto const detProp
3695  evt, clockData);
3696 
3697  //Util for momentum by range calculation
3698  trkf::TrackMomentumCalculator track_p_calc;
3699 
3700  //Iterate over all daughters
3701  for (size_t daughterID : particle->Daughters()) {
3702  const recob::PFParticle * daughterPFP = &(pfpVec->at( daughterID ));
3703  reco_daughter_PFP_ID.push_back( daughterID );
3704 
3705  //Get hits info from daughter pfp
3706  const std::vector< art::Ptr< recob::Hit > > daughterPFP_hits = pfpUtil.GetPFParticleHits_Ptrs( *daughterPFP, evt, fPFParticleTag );
3707  if (fVerbose) std::cout << "Got " << daughterPFP_hits.size() << " hits from daughter " << daughterID << std::endl;
3708 
3709  reco_daughter_PFP_nHits.push_back( daughterPFP_hits.size() );
3710  size_t nHits_coll = 0;
3711  for (size_t i = 0; i < daughterPFP_hits.size(); ++i) {
3712  if (daughterPFP_hits[i]->View() == 2) {
3713  ++nHits_coll;
3714  }
3715  }
3716  reco_daughter_PFP_nHits_collection.push_back(nHits_coll);
3717 
3718  //Get CNN output for the daughter particle
3719  if (!fSkipMVA) {
3720  cnnOutput2D theCNNResults = GetCNNOutputFromPFParticle(
3721  *daughterPFP, evt, *hitResults, pfpUtil, fPFParticleTag);
3722  double track_score = (theCNNResults.nHits > 0 ?
3723  (theCNNResults.track / theCNNResults.nHits) :
3724  -999.);
3725  double em_score = (theCNNResults.nHits > 0 ?
3726  (theCNNResults.em / theCNNResults.nHits) :
3727  -999.);
3728  double michel_score = (theCNNResults.nHits > 0 ?
3729  (theCNNResults.michel / theCNNResults.nHits) :
3730  -999.);
3731  reco_daughter_PFP_trackScore.push_back(track_score);
3732  reco_daughter_PFP_emScore.push_back(em_score);
3733  reco_daughter_PFP_michelScore.push_back(michel_score);
3734 
3735  cnnOutput2D cnn_collection = GetCNNOutputFromPFParticleFromPlane(
3736  *daughterPFP, evt, *hitResults, pfpUtil, fPFParticleTag, 2);
3737  double track_score_collection = (cnn_collection.nHits > 0 ?
3738  (cnn_collection.track / cnn_collection.nHits) :
3739  -999.);
3740  double em_score_collection = (cnn_collection.nHits > 0 ?
3741  (cnn_collection.em / cnn_collection.nHits) :
3742  -999.);
3743  double michel_score_collection = (cnn_collection.nHits > 0 ?
3744  (cnn_collection.michel / cnn_collection.nHits) :
3745  -999.);
3746  reco_daughter_PFP_trackScore_collection.push_back(track_score_collection);
3747  reco_daughter_PFP_emScore_collection.push_back(em_score_collection);
3748  reco_daughter_PFP_michelScore_collection.push_back(michel_score_collection);
3749  }
3750  else{
3751  reco_daughter_PFP_trackScore.push_back( -999. );
3752  reco_daughter_PFP_emScore.push_back( -999. );
3753  reco_daughter_PFP_michelScore.push_back( -999. );
3754  reco_daughter_PFP_trackScore_collection.push_back( -999. );
3755  reco_daughter_PFP_emScore_collection.push_back( -999. );
3756  reco_daughter_PFP_michelScore_collection.push_back( -999. );
3757  }
3758 
3759  //Matching by hits to get true daughter info
3760  if( !evt.isRealData() ){
3761  DaughterMatchInfo(evt, daughterPFP, clockData);
3762  }
3763 
3764 
3765  //Getting the default pandora reconstruction type (shower/track)
3766  const recob::Track * pandoraTrack = pfpUtil.GetPFParticleTrack(
3767  *daughterPFP, evt, fPFParticleTag, "pandoraTrack");
3768  const recob::Shower * pandoraShower = pfpUtil.GetPFParticleShower(
3769  *daughterPFP, evt, fPFParticleTag, "pandoraShower");
3770  if (pandoraTrack != 0x0) {
3771  reco_daughter_pandora_type.push_back(13);
3772  }
3773  else if (pandoraShower != 0x0) {
3774  reco_daughter_pandora_type.push_back(11);
3775  }
3776  else {
3777  reco_daughter_pandora_type.push_back(-1);
3778  }
3779 
3780 
3781  //If it exists (might not need this check anymore), get the forced tracking from pandora
3782  try{
3783  const recob::Track* pandora2Track = pfpUtil.GetPFParticleTrack( *daughterPFP, evt, fPFParticleTag, "pandora2Track" );
3784  if (fVerbose) std::cout << "pandora2 track: " << pandora2Track << std::endl;
3785 
3786  if( pandora2Track ){
3787  reco_daughter_allTrack_ID.push_back( pandora2Track->ID() );
3788 
3789  //Calorimetry info
3790  auto dummy_caloSCE =
3792  *pandora2Track, evt, "pandora2Track", fPandora2CaloSCE);
3793  bool found_calo = false;
3794  size_t index = 0;
3795  for ( index = 0; index < dummy_caloSCE.size(); ++index) {
3796  if (dummy_caloSCE[index].PlaneID().Plane == 2) {
3797  found_calo = true;
3798  break;
3799  }
3800  }
3801 
3802  reco_daughter_allTrack_resRange_SCE.push_back( std::vector<double>() );
3803  reco_daughter_allTrack_dEdX_SCE.push_back( std::vector<double>() );
3804  reco_daughter_allTrack_dQdX_SCE.push_back( std::vector<double>() );
3805  reco_daughter_allTrack_calibrated_dQdX_SCE.push_back( std::vector<double>() );
3806  reco_daughter_allTrack_calibrated_dEdX_SCE.push_back( std::vector<double>() );
3807  reco_daughter_allTrack_EField_SCE.push_back( std::vector<double>() );
3808  reco_daughter_allTrack_calo_X.push_back( std::vector<double>() );
3809  reco_daughter_allTrack_calo_Y.push_back( std::vector<double>() );
3810  reco_daughter_allTrack_calo_Z.push_back( std::vector<double>() );
3811 
3812  if (found_calo) {
3813  auto dummy_dEdx_SCE = dummy_caloSCE[index].dEdx();
3814  auto dummy_dQdx_SCE = dummy_caloSCE[index].dQdx();
3815  auto dummy_Range_SCE = dummy_caloSCE[index].ResidualRange();
3816  auto theXYZPoints = dummy_caloSCE[index].XYZ();
3817 
3818  //Momentum by range calculation using SCE corrected info
3820  track_p_calc.GetTrackMomentum(dummy_caloSCE[index].Range(),
3821  2212));
3823  track_p_calc.GetTrackMomentum(dummy_caloSCE[index].Range(),
3824  13));
3825  reco_daughter_allTrack_alt_len.push_back(dummy_caloSCE[index].Range() );
3826 
3827  for( size_t j = 0; j < dummy_dEdx_SCE.size(); ++j ){
3828  reco_daughter_allTrack_resRange_SCE.back().push_back( dummy_Range_SCE[j] );
3829  reco_daughter_allTrack_dEdX_SCE.back().push_back( dummy_dEdx_SCE[j] );
3830  reco_daughter_allTrack_dQdX_SCE.back().push_back( dummy_dQdx_SCE[j] );
3831  reco_daughter_allTrack_calo_X.back().push_back(theXYZPoints[j].X());
3832  reco_daughter_allTrack_calo_Y.back().push_back(theXYZPoints[j].Y());
3833  reco_daughter_allTrack_calo_Z.back().push_back(theXYZPoints[j].Z());
3834  }
3835 
3836 /*
3837 <<<<<<< HEAD
3838  if (fCalibrateByHand) {
3839  std::vector<float> cali_dEdX_SCE = calibration_SCE.GetCalibratedCalorimetry(*pandora2Track, evt, "pandora2Track", fPandora2CaloSCE, 2);
3840  for( size_t j = 0; j < cali_dEdX_SCE.size(); ++j ){
3841  reco_daughter_allTrack_calibrated_dEdX_SCE.back().push_back( cali_dEdX_SCE[j] );
3842  }
3843  }
3844  else {
3845  for (auto dedx : reco_daughter_allTrack_dEdX_SCE.back()) {
3846  reco_daughter_allTrack_calibrated_dEdX_SCE.back().push_back(dedx);
3847  }
3848  }
3849 
3850 
3851  if (fCalibrateByHand) {
3852 =======*/
3853  if (fRecalibrate) {
3854  std::vector<float> cali_dEdX_SCE
3856  *pandora2Track, evt, "pandora2Track", fPandora2CaloSCE, 2);
3857 
3858  for( size_t j = 0; j < cali_dEdX_SCE.size(); ++j ){
3860  cali_dEdX_SCE[j]);
3861  }
3862 //>>>>>>> 32b542a302943d59e3a1152ef8dcb75d7045bcf0
3863  std::vector<double> new_dQdX = calibration_SCE.CalibratedQdX(
3864  *pandora2Track, evt, "pandora2Track",
3865  fPandora2CaloSCE, 2, -10.);
3866  for (auto dqdx : new_dQdX) {
3867  reco_daughter_allTrack_calibrated_dQdX_SCE.back().push_back(dqdx);
3868  }
3869  std::vector<double> efield = calibration_SCE.GetEFieldVector(
3870  *pandora2Track, evt, "pandora2Track", fPandora2CaloSCE, 2, -10.);
3871  for (auto ef : efield) {
3872  reco_daughter_allTrack_EField_SCE.back().push_back(ef);
3873  }
3874 
3875  }
3876  else {
3877  for (size_t j = 0; j < dummy_dQdx_SCE.size(); ++j) {
3879  dummy_dEdx_SCE[j]);
3881  dummy_dQdx_SCE[j]);
3882  double E_field_nominal = detProp.Efield(); // Electric Field in the drift region in KV/cm
3883  geo::Vector_t E_field_offsets
3884  = (sce->EnableCalEfieldSCE() && fSCE ?
3885  sce->GetCalEfieldOffsets(
3886  geo::Point_t{theXYZPoints[j].X(), theXYZPoints[j].Y(),
3887  theXYZPoints[j].Z()},
3888  dummy_caloSCE[index].PlaneID().TPC) :
3889  geo::Vector_t{0., 0., 0.});
3890  TVector3 E_field_vector
3891  = {E_field_nominal*(1 + E_field_offsets.X()),
3892  E_field_nominal*E_field_offsets.Y(),
3893  E_field_nominal*E_field_offsets.Z()};
3894 
3895  double E_field = E_field_vector.Mag();
3896  reco_daughter_allTrack_EField_SCE.back().push_back(E_field);
3897  }
3898  }
3899 
3900  //Chi2 based PID
3901  std::pair<double, int> this_chi2_ndof = trackUtil.Chi2PID(
3904 
3905  reco_daughter_allTrack_Chi2_proton.push_back(this_chi2_ndof.first);
3906  reco_daughter_allTrack_Chi2_ndof.push_back(this_chi2_ndof.second);
3907 
3908  this_chi2_ndof = trackUtil.Chi2PID(
3911 
3912  reco_daughter_allTrack_Chi2_pion.push_back(this_chi2_ndof.first);
3913  reco_daughter_allTrack_Chi2_ndof_pion.push_back(this_chi2_ndof.second);
3914 
3915  this_chi2_ndof = trackUtil.Chi2PID(
3918 
3919  reco_daughter_allTrack_Chi2_muon.push_back(this_chi2_ndof.first);
3920  reco_daughter_allTrack_Chi2_ndof_muon.push_back(this_chi2_ndof.second);
3921  }
3922  else {
3925  reco_daughter_allTrack_alt_len.push_back(-999.);
3926  reco_daughter_allTrack_Chi2_proton.push_back(-999.);
3927  reco_daughter_allTrack_Chi2_ndof.push_back(-999);
3928 
3929  reco_daughter_allTrack_Chi2_pion.push_back(-999.);
3930  reco_daughter_allTrack_Chi2_ndof_pion.push_back(-999);
3931 
3932  reco_daughter_allTrack_Chi2_muon.push_back(-999.);
3933  reco_daughter_allTrack_Chi2_ndof_muon.push_back(-999);
3934  }
3935 
3936  //Calorimetry + chi2 for planes 0 and 1
3937  size_t plane0_index = 0;
3938  bool found_plane0 = false;
3939  for ( plane0_index = 0; plane0_index < dummy_caloSCE.size(); ++plane0_index) {
3940  if (dummy_caloSCE[plane0_index].PlaneID().Plane == 0) {
3941  found_plane0 = true;
3942  break;
3943  }
3944  }
3945  size_t plane1_index = 0;
3946  bool found_plane1 = false;
3947  for ( plane1_index = 0; plane1_index < dummy_caloSCE.size(); ++plane1_index) {
3948  if (dummy_caloSCE[plane1_index].PlaneID().Plane == 1) {
3949  found_plane1 = true;
3950  break;
3951  }
3952  }
3953  if (fVerbose)
3954  std::cout << "Plane 0, 1 " << plane0_index << " " <<
3955  plane1_index << std::endl;
3956 
3957 
3959  std::vector<double>());
3961  std::vector<double>());
3962 
3963  if (found_plane0) {
3964  auto resRange_plane0 = dummy_caloSCE[plane0_index].ResidualRange();
3965  //auto dEdX_plane0 = dummy_caloSCE[plane0_index].dEdx();
3966 
3967  for (size_t j = 0; j < resRange_plane0.size(); ++j) {
3968  reco_daughter_allTrack_resRange_plane0.back().push_back(
3969  resRange_plane0[j]);
3970  }
3971 
3972 
3973  std::vector<float> dEdX_plane0
3974  = (fRecalibrate ?
3976  *pandora2Track, evt, "pandora2Track", fPandora2CaloSCE, 0) :
3977  dummy_caloSCE[plane0_index].dEdx());
3978  /*
3979  if (fRecalibrate){
3980  std::vector<float> dEdX_plane0 = calibration_SCE.GetCalibratedCalorimetry(
3981  *pandora2Track, evt, "pandora2Track", fPandora2CaloSCE, 0);
3982  for (size_t j = 0; j < dEdX_plane0.size(); ++j) {
3983  reco_daughter_allTrack_calibrated_dEdX_SCE_plane0.back().push_back(dEdX_plane0[j]);
3984  }
3985  }
3986  else{
3987  for (size_t j = 0; j < dEdX_plane0.size(); ++j){
3988  reco_daughter_allTrack_calibrated_dEdX_SCE_plane0.back().push_back(dEdX_plane0[j]);
3989  }
3990  }*/
3991 
3992  std::pair<double, int> plane0_chi2_ndof = trackUtil.Chi2PID(
3996  plane0_chi2_ndof.first);
3998  plane0_chi2_ndof.second);
3999  }
4000  else {
4002  -999.);
4004  -999);
4005  }
4006 
4007 
4009  std::vector<double>());
4010 
4012  std::vector<double>());
4013 
4014  if (found_plane1) {
4015  auto resRange_plane1 = dummy_caloSCE[plane1_index].ResidualRange();
4016  for (size_t j = 0; j < resRange_plane1.size(); ++j) {
4017  reco_daughter_allTrack_resRange_plane1.back().push_back(
4018  resRange_plane1[j]);
4019  }
4020 
4021 
4022  std::vector<float> dEdX_plane1
4023  = (fRecalibrate ?
4025  *pandora2Track, evt, "pandora2Track", fPandora2CaloSCE, 1) :
4026  dummy_caloSCE[plane1_index].dEdx());
4027  for (auto & dedx : dEdX_plane1) {
4029  dedx);
4030  }
4031 
4032  /*
4033  if (fRecalibrate){
4034  std::vector<float> dEdX_plane1 = calibration_SCE.GetCalibratedCalorimetry(
4035  *pandora2Track, evt, "pandora2Track", fPandora2CaloSCE, 1);
4036 
4037  for (size_t j = 0; j < dEdX_plane1.size(); ++j) {
4038  reco_daughter_allTrack_calibrated_dEdX_SCE_plane1.back().push_back(dEdX_plane1[j]);
4039  }
4040  }
4041  else{
4042  auto dEdX_plane1 = dummy_caloSCE[plane1_index].dEdx();
4043  for (size_t j = 0; j < dEdX_plane1.size(); ++j){
4044  reco_daughter_allTrack_calibrated_dEdX_SCE_plane1.back().push_back(dEdX_plane1[j]);
4045  }
4046  } */
4047 
4048  std::pair<double, int> plane1_chi2_ndof = trackUtil.Chi2PID(
4052  plane1_chi2_ndof.first);
4054  plane1_chi2_ndof.second);
4055  }
4056  else {
4058  -999.);
4060  -999);
4061  }
4062  //////////////////////////////////////
4063 
4064  //Spatial + direction stuff from Pandora
4065  reco_daughter_allTrack_Theta.push_back( pandora2Track->Theta() );
4066  reco_daughter_allTrack_Phi.push_back( pandora2Track->Phi() );
4067 
4068  reco_daughter_allTrack_len.push_back( pandora2Track->Length() );
4069  reco_daughter_allTrack_startX.push_back( pandora2Track->Trajectory().Start().X() );
4070  reco_daughter_allTrack_startY.push_back( pandora2Track->Trajectory().Start().Y() );
4071  reco_daughter_allTrack_startZ.push_back( pandora2Track->Trajectory().Start().Z() );
4072  reco_daughter_allTrack_endX.push_back( pandora2Track->Trajectory().End().X() );
4073  reco_daughter_allTrack_endY.push_back( pandora2Track->Trajectory().End().Y() );
4074  reco_daughter_allTrack_endZ.push_back( pandora2Track->Trajectory().End().Z() );
4075 
4076  //Using new michel tagging from Ajib
4077  if (!fSkipMVA) {
4078  std::pair<double, int> vertex_results =
4080  *pandora2Track, evt, "pandora2Track", fHitTag,
4081  0., -500., 500., 0., 500., 0., false,
4083 
4085  vertex_results.first);
4087  vertex_results.second);
4088  }
4089  else {
4091  -999.);
4093  -999);
4094  }
4095 
4096  if (fVerbose) std::cout << "pandora2Length " << pandora2Track->Length() << std::endl;
4097  //Another momentum by range calculation, but using the SCE-uncorrected info
4098  reco_daughter_allTrack_momByRange_proton.push_back( track_p_calc.GetTrackMomentum( pandora2Track->Length(), 2212 ) );
4099  reco_daughter_allTrack_momByRange_muon.push_back( track_p_calc.GetTrackMomentum( pandora2Track->Length(), 13 ) );
4100 
4101  }
4102  else{ //Defaults
4103  reco_daughter_allTrack_ID.push_back( -999 );
4104  reco_daughter_allTrack_resRange_SCE.push_back( std::vector<double>() );
4105  reco_daughter_allTrack_dEdX_SCE.push_back( std::vector<double>() );
4106  reco_daughter_allTrack_dQdX_SCE.push_back( std::vector<double>() );
4107  reco_daughter_allTrack_calibrated_dEdX_SCE.push_back(std::vector<double>());
4108  reco_daughter_allTrack_calibrated_dQdX_SCE.push_back(std::vector<double>());
4109  reco_daughter_allTrack_EField_SCE.push_back(std::vector<double>());
4110  reco_daughter_allTrack_Chi2_proton.push_back( -999. );
4111  reco_daughter_allTrack_Chi2_ndof.push_back( -999 );
4112 
4113  reco_daughter_allTrack_Chi2_pion.push_back( -999. );
4114  reco_daughter_allTrack_Chi2_ndof_pion.push_back( -999 );
4115 
4116  reco_daughter_allTrack_Chi2_muon.push_back( -999. );
4117  reco_daughter_allTrack_Chi2_ndof_muon.push_back( -999 );
4118 
4119  reco_daughter_allTrack_calo_X.push_back( std::vector<double>() );
4120  reco_daughter_allTrack_calo_Y.push_back( std::vector<double>() );
4121  reco_daughter_allTrack_calo_Z.push_back( std::vector<double>() );
4122 
4123  //Calorimetry + chi2 for planes 0 and 1
4125  std::vector<double>());
4127  std::vector<double>());
4129  std::vector<double>());
4131  std::vector<double>());
4132 
4133  reco_daughter_allTrack_Chi2_proton_plane0.push_back( -999. );
4134  reco_daughter_allTrack_Chi2_ndof_plane0.push_back( -999 );
4135  reco_daughter_allTrack_Chi2_proton_plane1.push_back( -999. );
4136  reco_daughter_allTrack_Chi2_ndof_plane1.push_back( -999 );
4137  //////////////////////////////////
4138 
4139  reco_daughter_allTrack_Theta.push_back(-999. );
4140  reco_daughter_allTrack_Phi.push_back(-999.);
4141  reco_daughter_allTrack_len.push_back( -999. );
4142  reco_daughter_allTrack_alt_len.push_back(-999.);
4143  reco_daughter_allTrack_startX.push_back( -999. );
4144  reco_daughter_allTrack_startY.push_back( -999. );
4145  reco_daughter_allTrack_startZ.push_back( -999. );
4146  reco_daughter_allTrack_endX.push_back( -999. );
4147  reco_daughter_allTrack_endY.push_back( -999. );
4148  reco_daughter_allTrack_endZ.push_back( -999. );
4150  reco_daughter_allTrack_momByRange_muon.push_back(-999.);
4151 
4154 
4156  reco_daughter_allTrack_vertex_nHits.push_back(-999);
4157 
4158  }
4159  }
4160  catch( const cet::exception &e ){
4161  MF_LOG_WARNING("PDSPAnalyzer") << "pandora2Track object not found, moving on" << std::endl;
4162  }
4163 
4164 
4165  //If it exists (might not need this check anymore), get the forced shower object from pandora
4166  try{
4167  const recob::Shower* pandora2Shower = pfpUtil.GetPFParticleShower( *daughterPFP, evt, fPFParticleTag, "pandora2Shower" );
4168  if (fVerbose) std::cout << "pandora2 shower: " << pandora2Shower << std::endl;
4169 
4170  if( pandora2Shower ){
4171  reco_daughter_allShower_ID.push_back( pandora2Shower->ID() );
4172  reco_daughter_allShower_len.push_back( pandora2Shower->Length() );
4173  reco_daughter_allShower_startX.push_back( pandora2Shower->ShowerStart().X() );
4174  reco_daughter_allShower_startY.push_back( pandora2Shower->ShowerStart().Y() );
4175  reco_daughter_allShower_startZ.push_back( pandora2Shower->ShowerStart().Z() );
4176 
4177  reco_daughter_allShower_dirX.push_back( pandora2Shower->Direction().X() );
4178  reco_daughter_allShower_dirY.push_back( pandora2Shower->Direction().Y() );
4179  reco_daughter_allShower_dirZ.push_back( pandora2Shower->Direction().Z() );
4180 
4181 
4182  const std::vector<art::Ptr<recob::Hit>> hits =
4184  *pandora2Shower, evt, "pandora2Shower");
4185 
4186  art::FindManyP<recob::SpacePoint> spFromHits(hits, evt, fHitTag);
4187  //double total_shower_energy = 0.;
4188  //need to get average y
4189  std::vector<double> x_vec, y_vec, z_vec;
4190  double total_y = 0.;
4191  int n_good_y = 0;
4192  std::vector<art::Ptr<recob::Hit>> good_hits;
4193 
4194  for (size_t iHit = 0; iHit < hits.size(); ++iHit) {
4195  auto theHit = hits[iHit];
4196  if (theHit->View() != 2) continue; //skip induction planes
4197 
4198  good_hits.push_back(theHit);
4199 
4200  double shower_hit_x = detProp.ConvertTicksToX(
4201  theHit->PeakTime(),
4202  theHit->WireID().Plane,
4203  theHit->WireID().TPC, 0);
4204 
4205  double shower_hit_z = geom->Wire(theHit->WireID()).GetCenter().Z();
4206 
4207  x_vec.push_back(shower_hit_x);
4208  z_vec.push_back(shower_hit_z);
4209 
4210  std::vector<art::Ptr<recob::SpacePoint>> sps = spFromHits.at(iHit);
4211  //std::cout << shower_hit_x << " " << shower_hit_z << " ";
4212  if (!sps.empty()) {
4213  y_vec.push_back(sps[0]->XYZ()[1]);
4214  total_y += y_vec.back();
4215  ++n_good_y;
4216  //std::cout << shower_hit_y_vec.back();
4217  }
4218  else {
4219  y_vec.push_back(-999.);
4220  }
4221  //std::cout << std::endl;
4222  }
4223 
4224  if (n_good_y < 1) {
4225  reco_daughter_allShower_energy.push_back(-999.);
4226  }
4227  else {
4228  double total_shower_energy = 0.;
4229  for (size_t iHit = 0; iHit < good_hits.size(); ++iHit) {
4230  auto theHit = good_hits[iHit];
4231  if (theHit->View() != 2) continue; //skip induction planes
4232 
4233  if (y_vec[iHit] < -100.)
4234  y_vec[iHit] = total_y / n_good_y;
4235 
4236  total_shower_energy += calibration_SCE.HitToEnergy(
4237  good_hits[iHit], x_vec[iHit], y_vec[iHit], z_vec[iHit]);
4238  }
4239  reco_daughter_allShower_energy.push_back(total_shower_energy);
4240  }
4241  }
4242  else{
4243  reco_daughter_allShower_ID.push_back(-999);
4244  reco_daughter_allShower_len.push_back(-999.);
4245  reco_daughter_allShower_startX.push_back(-999.);
4246  reco_daughter_allShower_startY.push_back(-999.);
4247  reco_daughter_allShower_startZ.push_back(-999.);
4248  reco_daughter_allShower_dirX.push_back(-999.);
4249  reco_daughter_allShower_dirY.push_back(-999.);
4250  reco_daughter_allShower_dirZ.push_back(-999.);
4251  reco_daughter_allShower_energy.push_back(-999.);
4252  }
4253 
4254  }
4255  catch( const cet::exception &e ){
4256  MF_LOG_WARNING("PDSPAnalyzer") << "pandora2Shower object not found, moving on" << std::endl;
4257  }
4258  }
4259 }
std::vector< std::vector< double > > reco_daughter_allTrack_calo_X
std::vector< double > reco_daughter_allShower_startY
std::vector< int > reco_daughter_allTrack_Chi2_ndof_plane1
const std::vector< size_t > & Daughters() const
Returns the collection of daughter particles.
Definition: PFParticle.h:114
std::vector< double > GetEFieldVector(const recob::Track &track, art::Event const &evt, const std::string trackModule, const std::string caloModule, size_t planeID, double negativeZFix=0.)
const TVector3 & ShowerStart() const
Definition: Shower.h:192
std::vector< std::vector< double > > reco_daughter_allTrack_dQdX_SCE
std::vector< std::vector< double > > reco_daughter_allTrack_calo_Z
std::vector< double > reco_daughter_allTrack_Chi2_muon
std::vector< double > reco_daughter_allTrack_alt_len
std::vector< double > reco_daughter_allTrack_endZ
std::vector< int > reco_daughter_PFP_nHits_collection
double Length() const
Definition: Shower.h:201
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dQdX_SCE
AdcChannelData::View View
const recob::Shower * GetPFParticleShower(const recob::PFParticle &particle, art::Event const &evt, const std::string particleLabel, const std::string showerLabel) const
Get the shower associated to this particle. Returns a null pointer if not found.
std::vector< double > reco_daughter_allTrack_startZ
std::vector< double > reco_daughter_allTrack_Chi2_pion
const recob::TrackTrajectory & Trajectory() const
Access to the stored recob::TrackTrajectory.
Definition: Track.h:98
art::ServiceHandle< geo::Geometry > geom
std::vector< anab::Calorimetry > GetRecoTrackCalorimetry(const recob::Track &track, art::Event const &evt, const std::string trackModule, const std::string caloModule) const
Get the Calorimetry(s) from a given reco track.
std::vector< double > reco_daughter_allTrack_momByRange_proton
std::vector< double > reco_daughter_allTrack_Chi2_proton_plane1
std::vector< double > reco_daughter_allTrack_momByRange_alt_muon
std::vector< int > reco_daughter_allShower_ID
std::vector< int > reco_daughter_allTrack_Chi2_ndof
std::vector< double > reco_daughter_PFP_michelScore
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double >, ROOT::Math::GlobalCoordinateSystemTag > Vector_t
Type for representation of momenta in 3D space.
Definition: geo_vectors.h:164
std::vector< int > reco_daughter_PFP_nHits
std::vector< std::vector< double > > reco_daughter_allTrack_dEdX_SCE
std::vector< std::vector< double > > reco_daughter_allTrack_calo_Y
std::vector< double > reco_daughter_allTrack_Phi
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dEdX_SCE_plane0
std::pair< double, int > GetVertexMichelScore(const recob::Track &track, const art::Event &evt, const std::string trackModule, const std::string hitModule, double min_length=5., double min_x=-200., double max_x=0., double min_y=200., double max_y=500., double min_z=25., bool check_wire=true, double check_x=0, double check_y=0., double check_z=0.)
bool isRealData() const
double HitToEnergy(const art::Ptr< recob::Hit > hit, double X, double Y, double Z, double recomb_factor=.6417)
std::vector< std::vector< double > > reco_daughter_allTrack_EField_SCE
const std::vector< art::Ptr< recob::Hit > > GetRecoShowerArtHits(const recob::Shower &shower, art::Event const &evt, const std::string showerModule) const
double Phi() const
Definition: Track.h:178
const double e
double Length(size_t p=0) const
Access to various track properties.
Definition: Track.h:167
std::vector< double > reco_daughter_allTrack_endY
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dEdX_SCE_plane1
std::vector< double > CalibratedQdX(const recob::Track &track, art::Event const &evt, const std::string trackModule, const std::string caloModule, size_t planeID, double negativeZFix)
std::vector< double > reco_daughter_allShower_startX
double Theta() const
Access to spherical or geographical angles at vertex or at any point.
Definition: Track.h:176
std::vector< double > reco_daughter_allTrack_endX
const recob::Track * GetPFParticleTrack(const recob::PFParticle &particle, art::Event const &evt, const std::string particleLabel, const std::string trackLabel) const
Get the track associated to this particle. Returns a null pointer if not found.
std::vector< int > reco_daughter_allTrack_ID
std::vector< std::vector< double > > reco_daughter_allTrack_resRange_SCE
ValidHandle< PROD > getValidHandle(InputTag const &tag) const
Definition: DataViewImpl.h:441
std::vector< double > reco_daughter_allTrack_vertex_michel_score
std::vector< int > reco_daughter_PFP_ID
std::vector< double > reco_daughter_allShower_dirY
std::vector< int > reco_daughter_allTrack_vertex_nHits
const TVector3 & Direction() const
Definition: Shower.h:189
std::map< int, TProfile * > templates
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dEdX_SCE
std::vector< double > reco_daughter_allTrack_Theta
protoana::ProtoDUNECalibration calibration_SCE
cnnOutput2D GetCNNOutputFromPFParticle(const recob::PFParticle &part, const art::Event &evt, const anab::MVAReader< recob::Hit, 4 > &CNN_results, protoana::ProtoDUNEPFParticleUtils &pfpUtil, std::string fPFParticleTag)
std::vector< int > reco_daughter_pandora_type
std::vector< std::vector< double > > reco_daughter_allTrack_resRange_plane1
std::vector< double > reco_daughter_PFP_michelScore_collection
std::pair< double, int > Chi2PID(const std::vector< double > &track_dedx, const std::vector< double > &range, TProfile *profile)
std::vector< double > reco_daughter_allTrack_Chi2_proton
ROOT::Math::PositionVector3D< ROOT::Math::Cartesian3D< double >, ROOT::Math::GlobalCoordinateSystemTag > Point_t
Type for representation of position in physical 3D space.
Definition: geo_vectors.h:184
WireGeo const & Wire(geo::WireID const &wireid) const
Returns the specified wire.
int ID() const
Definition: Track.h:198
protoana::ProtoDUNETrackUtils trackUtil
std::vector< double > reco_daughter_allShower_dirX
std::vector< double > reco_daughter_allTrack_Chi2_proton_plane0
void DaughterMatchInfo(const art::Event &evt, const recob::PFParticle *daughterPFP, detinfo::DetectorClocksData const &clockData)
Hierarchical representation of particle flow.
Definition: PFParticle.h:44
std::vector< double > reco_daughter_PFP_emScore
protoana::ProtoDUNEPFParticleUtils pfpUtil
Point_t const & End() const
Returns the position of the last valid point of the trajectory [cm].
std::vector< std::vector< double > > reco_daughter_allTrack_resRange_plane0
const std::vector< art::Ptr< recob::Hit > > GetPFParticleHits_Ptrs(const recob::PFParticle &particle, art::Event const &evt, const std::string particleLabel) const
std::vector< double > reco_daughter_PFP_trackScore
protoana::ProtoDUNEShowerUtils showerUtil
detail::Node< FrameID, bool > PlaneID
Definition: CRTID.h:125
std::vector< double > reco_daughter_allShower_energy
std::vector< double > reco_daughter_allTrack_startX
cnnOutput2D GetCNNOutputFromPFParticleFromPlane(const recob::PFParticle &part, const art::Event &evt, const anab::MVAReader< recob::Hit, 4 > &CNN_results, protoana::ProtoDUNEPFParticleUtils &pfpUtil, std::string fPFParticleTag, size_t planeID)
std::vector< int > reco_daughter_allTrack_Chi2_ndof_plane0
#define MF_LOG_WARNING(category)
std::vector< double > reco_daughter_allTrack_momByRange_muon
std::vector< double > reco_daughter_PFP_trackScore_collection
std::vector< float > GetCalibratedCalorimetry(const recob::Track &track, art::Event const &evt, const std::string trackModule, const std::string caloModule, size_t planeID, double negativeZFix=0.)
std::vector< double > reco_daughter_allShower_dirZ
Point_t const & Start() const
Returns the position of the first valid point of the trajectory [cm].
std::vector< double > reco_daughter_allShower_len
int ID() const
Definition: Shower.h:187
std::vector< int > reco_daughter_allTrack_Chi2_ndof_pion
std::vector< double > reco_daughter_allTrack_len
std::vector< double > reco_daughter_PFP_emScore_collection
Track from a non-cascading particle.A recob::Track consists of a recob::TrackTrajectory, plus additional members relevant for a "fitted" track:
Definition: Track.h:49
double GetTrackMomentum(double trkrange, int pdg) const
cet::coded_exception< error, detail::translate > exception
Definition: exception.h:33
QTextStream & endl(QTextStream &s)
std::vector< int > reco_daughter_allTrack_Chi2_ndof_muon
std::vector< double > reco_daughter_allShower_startZ
std::vector< double > reco_daughter_allTrack_momByRange_alt_proton
TFile * ef
Definition: doAna.cpp:25
std::vector< double > reco_daughter_allTrack_startY
void pduneana::PDSPAnalyzer::endJob ( )
overridevirtual

Reimplemented from art::EDAnalyzer.

Definition at line 1841 of file PDSPAnalyzer_module.cc.

1842 {
1843  dEdX_template_file->Close();
1844 }
void pduneana::PDSPAnalyzer::G4RWGridWeights ( std::vector< std::vector< G4ReweightTraj * >> &  hierarchy,
std::vector< fhicl::ParameterSet > &  pars,
std::vector< std::vector< double >> &  weights,
G4MultiReweighter *  multi_rw 
)
private

Definition at line 4704 of file PDSPAnalyzer_module.cc.

4708  {
4709  std::vector<double> input(pars.size(), 1.);
4710  for (size_t i = 0; i < pars.size(); ++i) {
4711  weights.push_back(std::vector<double>());
4712  for (size_t j = 0; j < fGridPoints.size(); ++j) {
4713  input[i] = fGridPoints[j];
4714  bool set_values = multi_rw->SetAllParameterValues(input);
4715 
4716  if (set_values) {
4717  if (hierarchy.size()) {
4718  std::vector<G4ReweightTraj *> & init_trajs = hierarchy[0];
4719  weights.back().push_back(
4720  GetNTrajWeightFromSetPars(init_trajs, *multi_rw));
4721  for (size_t k = 1; k < hierarchy.size(); ++k) {
4722  std::vector<G4ReweightTraj *> & temp_trajs = hierarchy[k];
4723  weights.back().back()
4724  *= GetNTrajWeightFromSetPars(temp_trajs, *MultiRW);
4725  }
4726  }
4727  }
4728  else {
4729  std::string message = "Could not Get N Traj Weight from set pars";
4730  throw std::runtime_error(message);
4731  }
4732  }
4733 
4734  //Reset to 1.
4735  input[i] = 1.;
4736  }
4737 }
std::string string
Definition: nybbler.cc:12
double GetNTrajWeightFromSetPars(const std::vector< G4ReweightTraj * > &trajs, G4MultiReweighter &rw)
G4MultiReweighter * MultiRW
static int input(void)
Definition: code.cpp:15695
std::vector< double > fGridPoints
void pduneana::PDSPAnalyzer::GetG4RWCoeffs ( std::vector< double > &  weights,
std::vector< double > &  coeffs 
)
private

Definition at line 4824 of file PDSPAnalyzer_module.cc.

4824  {
4825  //Check if there are no weights
4826  if (weights.empty()) return;
4827 
4828  TGraph gr(fGridPoints.size(), &fGridPoints[0], &weights[0]);
4829  gr.Fit("pol9", "Q");
4830  TF1 * fit_func = (TF1*)gr.GetFunction("pol9");
4831  for (int j = 0; j < fit_func->GetNpar(); ++j) {
4832  coeffs.push_back(fit_func->GetParameter(j));
4833  }
4834 }
std::vector< double > fGridPoints
double pduneana::PDSPAnalyzer::lateralDist ( TVector3 &  n,
TVector3 &  x0,
TVector3 &  p 
)

Definition at line 1846 of file PDSPAnalyzer_module.cc.

1846  {
1847  TVector3 x = ( (p - x0)*n )*n;
1848  return (x - (p - x0)).Mag();
1849 }
std::void_t< T > n
p
Definition: test.py:223
list x
Definition: train.py:276
PDSPAnalyzer& pduneana::PDSPAnalyzer::operator= ( PDSPAnalyzer const &  )
delete
PDSPAnalyzer& pduneana::PDSPAnalyzer::operator= ( PDSPAnalyzer &&  )
delete
void pduneana::PDSPAnalyzer::reset ( )

Definition at line 1851 of file PDSPAnalyzer_module.cc.

1852 {
1854  reco_beam_startX = -999;
1855  reco_beam_startY = -999;
1856  reco_beam_startZ = -999;
1857  reco_beam_endX = -999;
1858  reco_beam_endY = -999;
1859  reco_beam_endZ = -999;
1860  reco_beam_flipped = false;
1861  reco_beam_trackEndDirX = -999;
1862  reco_beam_trackEndDirY = -999;
1863  reco_beam_trackEndDirZ = -999;
1864  reco_beam_trackDirX = -999;
1865  reco_beam_trackDirY = -999;
1866  reco_beam_trackDirZ = -999;
1867 
1868  true_beam_len = -999.;
1869  reco_beam_len = -999;
1870  reco_beam_alt_len = -999;
1872  reco_beam_calo_startX = -999;
1873  reco_beam_calo_startY = -999;
1874  reco_beam_calo_startZ = -999;
1875  reco_beam_calo_endX = -999;
1876  reco_beam_calo_endY = -999;
1877  reco_beam_calo_endZ = -999;
1884  reco_beam_calo_startDirX.clear();
1885  reco_beam_calo_startDirY.clear();
1886  reco_beam_calo_startDirZ.clear();
1887  reco_beam_calo_endDirX.clear();
1888  reco_beam_calo_endDirY.clear();
1889  reco_beam_calo_endDirZ.clear();
1890 
1891  reco_track_startX.clear();
1892  reco_track_startY.clear();
1893  reco_track_startZ.clear();
1894  reco_track_endX.clear();
1895  reco_track_endY.clear();
1896  reco_track_endZ.clear();
1897  reco_track_michel_score.clear();
1899  reco_track_ID.clear();
1900  reco_track_nHits.clear();
1901 
1902  reco_beam_type = -999;
1904 
1906 
1907  true_daughter_nPi0 = 0;
1913 
1914  reco_beam_true_byE_PDG = -999;
1915  reco_beam_true_byE_ID = -999;
1917  reco_beam_true_byHits_ID = -999;
1918 
1919  true_beam_PDG = -999;
1920  true_beam_mass = -999.;
1921  true_beam_ID = -999;
1923  true_beam_endX = -999.;
1924  true_beam_endY = -999.;
1925  true_beam_endZ = -999.;
1926  true_beam_endX_SCE = -999.;
1927  true_beam_endY_SCE = -999.;
1928  true_beam_endZ_SCE = -999.;
1929  true_beam_startX = -999.;
1930  true_beam_startY = -999.;
1931  true_beam_startZ = -999.;
1932 
1933  true_beam_startPx = -999.;
1934  true_beam_startPy = -999.;
1935  true_beam_startPz = -999.;
1936  true_beam_startP = -999.;
1937 
1938  true_beam_endPx = -999.;
1939  true_beam_endPy = -999.;
1940  true_beam_endPz = -999.;
1941  true_beam_endP = -999.;
1942  true_beam_endP2 = -999.;
1943  true_beam_last_len = -999.;
1944 
1945  true_beam_startDirX = -999.;
1946  true_beam_startDirY = -999.;
1947  true_beam_startDirZ = -999.;
1948  true_beam_nHits = -999;
1949 
1950 
1951  true_beam_processes.clear();
1954  true_beam_elastic_X.clear();
1955  true_beam_elastic_Y.clear();
1956  true_beam_elastic_Z.clear();
1957  true_beam_elastic_deltaE.clear();
1959  true_beam_IDE_totalDep = -999.;
1960 
1964 
1968 
1969  reco_beam_true_byE_endPx = -999.;
1970  reco_beam_true_byE_endPy = -999.;
1971  reco_beam_true_byE_endPz = -999.;
1972  reco_beam_true_byE_endE = -999.;
1973  reco_beam_true_byE_endP = -999.;
1974 
1978  reco_beam_true_byE_startE = -999.;
1979  reco_beam_true_byE_startP = -999.;
1980 
1984 
1990 
1996 
2000 
2001 
2002  //reco_daughter_true_byE_isPrimary = false;
2003  reco_beam_Chi2_proton = 999.;
2004 
2005 
2006 
2007  beam_inst_P = -999.;
2008  beam_inst_C0 = -999;
2009  beam_inst_C1 = -999;
2010  beam_inst_C0_pressure = -999.;
2011  beam_inst_C1_pressure = -999.;
2012  beam_inst_X = -999.;
2013  beam_inst_Y = -999.;
2014  beam_inst_Z = -999.;
2015  beam_inst_dirX = -999.;
2016  beam_inst_dirY = -999.;
2017  beam_inst_dirZ = -999.;
2018  beam_inst_nFibersP1 = -999;
2019  beam_inst_nFibersP2 = -999;
2020  beam_inst_nFibersP3 = -999;
2021  beam_inst_PDG_candidates.clear();
2022  beam_inst_TOF.clear();
2023  beam_inst_TOF_Chan.clear();
2024  beam_inst_nTracks = -999;
2025  beam_inst_nMomenta = -999;
2026  beam_inst_valid = true;
2027  beam_inst_trigger = -999;
2028 
2029  reco_beam_Chi2_ndof = -999;
2030 
2034  reco_beam_momByRange_muon = -999.;
2035 
2040 
2041  true_beam_daughter_PDG.clear();
2042  true_beam_daughter_len.clear();
2043  true_beam_daughter_startX.clear();
2044  true_beam_daughter_startY.clear();
2045  true_beam_daughter_startZ.clear();
2049  true_beam_daughter_startP.clear();
2050  true_beam_daughter_endX.clear();
2051  true_beam_daughter_endY.clear();
2052  true_beam_daughter_endZ.clear();
2055  true_beam_daughter_nHits.clear();
2056 
2060 
2069 
2075 
2076  true_beam_Pi0_decay_ID.clear();
2077  true_beam_Pi0_decay_parID.clear();
2085  true_beam_Pi0_decay_PDG.clear();
2086  true_beam_Pi0_decay_len.clear();
2087  true_beam_Pi0_decay_nHits.clear();
2091 
2100 
2106 
2113  true_beam_daughter_ID.clear();
2114 
2115  reco_daughter_PFP_ID.clear();
2117  reco_daughter_PFP_nHits.clear();
2120  reco_daughter_PFP_emScore.clear();
2125 
2126  reco_beam_PFP_ID = -999;
2127  reco_beam_PFP_nHits = -999;
2128  reco_beam_PFP_trackScore = -999;
2129  reco_beam_PFP_emScore = -999;
2140 
2141  reco_beam_allTrack_ID = -999;
2144  reco_beam_allTrack_len = -999;
2148  reco_beam_allTrack_endX = -999;
2149  reco_beam_allTrack_endY = -999;
2150  reco_beam_allTrack_endZ = -999;
2161 
2162  reco_beam_dQdX_NoSCE.clear();
2163  reco_beam_dEdX_NoSCE.clear();
2165  reco_beam_resRange_NoSCE.clear();
2166  reco_beam_TrkPitch_NoSCE.clear();
2167 
2168  reco_beam_dQdX_SCE.clear();
2169  reco_beam_EField_SCE.clear();
2170  reco_beam_dQ.clear();
2171  reco_beam_dQ_NoSCE.clear();
2172  reco_beam_dEdX_SCE.clear();
2175  reco_beam_vertex_nHits = -999;
2181 
2182  reco_beam_resRange_SCE.clear();
2183  reco_beam_TrkPitch_SCE.clear();
2185  reco_beam_calo_wire.clear();
2187  reco_beam_calo_wire_z.clear();
2188  reco_beam_calo_X.clear();
2189  reco_beam_calo_Y.clear();
2190  reco_beam_calo_Z.clear();
2191  reco_beam_calo_X_allTrack.clear();
2192  reco_beam_calo_Y_allTrack.clear();
2193  reco_beam_calo_Z_allTrack.clear();
2194  reco_beam_calo_wire_NoSCE.clear();
2196  reco_beam_calo_tick.clear();
2197  reco_beam_calo_TPC.clear();
2198  reco_beam_calo_TPC_NoSCE.clear();
2199 
2200  reco_beam_trackID = -999;
2201 
2202  n_beam_slices = -999;
2203  n_beam_particles = -999;
2204  beam_track_IDs.clear();
2205  beam_particle_scores.clear();
2206 
2212  true_beam_slices.clear();
2213  true_beam_slices_found.clear();
2214  true_beam_slices_deltaE.clear();
2216  em_energy = 0.;
2217  true_beam_traj_X.clear();
2218  true_beam_traj_Y.clear();
2219  true_beam_traj_Z.clear();
2220  true_beam_traj_Px.clear();
2221  true_beam_traj_Py.clear();
2222  true_beam_traj_Pz.clear();
2223  true_beam_traj_KE.clear();
2224  true_beam_traj_X_SCE.clear();
2225  true_beam_traj_Y_SCE.clear();
2226  true_beam_traj_Z_SCE.clear();
2227 
2228  //Alternative Reco
2237 
2245 
2254 
2259 
2260 
2261 
2262  reco_daughter_allTrack_ID.clear();
2268 
2269 
2270  //Calorimetry + chi2 for planes 0 and 1
2273 
2276 
2279 
2282  ///////////////////////////////////////////
2283 
2284 
2285  //reco_daughter_allTrack_calibrated_dEdX.clear();
2287 
2294 
2310 
2316 
2321  ///////
2322 
2323 
2324  //New Hits info
2325  reco_beam_spacePts_X.clear();
2326  reco_beam_spacePts_Y.clear();
2327  reco_beam_spacePts_Z.clear();
2328 
2329  reco_daughter_spacePts_X.clear();
2330  reco_daughter_spacePts_Y.clear();
2331  reco_daughter_spacePts_Z.clear();
2332 
2336  //
2337 
2338  g4rw_primary_weights.clear();
2341  g4rw_primary_var.clear();
2346  g4rw_full_grid_weights.clear();
2347  g4rw_full_grid_coeffs.clear();
2358  g4rw_primary_grid_weights.clear();
2360 }
std::vector< double > true_beam_traj_X_SCE
std::vector< int > beam_inst_TOF_Chan
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_PFP_trackScore
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_startX
std::vector< int > reco_daughter_PFP_true_byE_PDG
double reco_beam_PFP_trackScore_collection_weight_by_charge
std::vector< double > reco_beam_calo_startDirX
std::vector< double > reco_beam_calo_X
std::vector< double > true_beam_incidentEnergies
std::vector< std::vector< double > > reco_daughter_allTrack_calo_X
std::vector< int > reco_daughter_PFP_true_byHits_ID
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_startX
std::vector< double > reco_daughter_allShower_startY
std::vector< double > reco_beam_spacePts_Y
std::vector< double > reco_daughter_PFP_true_byHits_startZ
std::vector< std::vector< double > > g4rw_primary_grid_weights
std::vector< double > reco_beam_dQ_NoSCE
std::vector< int > reco_daughter_allTrack_Chi2_ndof_plane1
std::vector< double > g4rw_full_primary_plus_sigma_weight
std::vector< std::vector< double > > reco_daughter_allTrack_dQdX_SCE
std::vector< double > true_beam_daughter_startPz
std::vector< std::vector< double > > reco_daughter_allTrack_calo_Z
std::string reco_beam_true_byE_endProcess
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_PFP_trackScore
std::vector< double > reco_beam_calo_Z_allTrack
std::vector< std::vector< double > > reco_daughter_shower_spacePts_Z
std::vector< double > reco_daughter_PFP_true_byHits_startX
std::vector< double > reco_daughter_allTrack_Chi2_muon
std::vector< int > true_beam_Pi0_decay_ID
std::vector< double > true_beam_elastic_IDE_edep
std::vector< int > reco_daughter_PFP_true_byHits_parID
std::vector< double > beam_particle_scores
std::vector< double > reco_beam_dEdX_NoSCE
std::vector< double > true_beam_Pi0_decay_len
std::vector< double > reco_track_michel_score_weight_by_charge
std::vector< int > true_beam_slices
std::vector< double > true_beam_slices_deltaE
std::vector< double > reco_beam_TrkPitch_NoSCE
std::vector< double > reco_daughter_allTrack_alt_len
std::vector< double > reco_beam_EField_SCE
std::vector< double > reco_daughter_allTrack_endZ
std::vector< double > reco_beam_calo_Y_allTrack
std::vector< int > reco_daughter_PFP_nHits_collection
std::vector< double > true_beam_Pi0_decay_startZ
std::vector< double > true_beam_Pi0_decay_startPx
std::vector< double > reco_beam_calo_wire_NoSCE
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dQdX_SCE
std::vector< double > reco_beam_resRange_SCE
std::vector< double > g4rw_full_primary_minus_sigma_weight
std::vector< int > beam_inst_PDG_candidates
std::vector< double > reco_daughter_allTrack_startZ
std::vector< std::string > true_beam_grand_daughter_Process
std::vector< double > reco_daughter_allTrack_Chi2_pion
std::vector< double > reco_track_startZ
std::vector< double > reco_track_startX
std::vector< std::string > true_beam_daughter_endProcess
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_startZ
std::vector< std::vector< double > > g4rw_full_grid_piplus_weights
std::vector< int > reco_daughter_PFP_true_byHits_PDG
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_endX
double reco_beam_PFP_emScore_collection_weight_by_charge
std::vector< double > reco_daughter_allTrack_momByRange_proton
std::vector< double > reco_beam_calo_wire_z
std::vector< double > reco_beam_spacePts_Z
std::vector< double > reco_daughter_allTrack_Chi2_proton_plane1
std::vector< double > reco_beam_allTrack_calibrated_dEdX
std::vector< double > true_beam_daughter_startP
std::vector< double > g4rw_primary_minus_sigma_weight
std::vector< double > reco_daughter_allTrack_momByRange_alt_muon
std::vector< int > reco_daughter_allShower_ID
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_startZ
std::vector< double > reco_track_endX
std::vector< double > reco_beam_calo_startDirY
std::vector< std::string > true_beam_daughter_Process
std::vector< int > reco_daughter_allTrack_Chi2_ndof
std::vector< double > reco_daughter_PFP_michelScore
std::vector< double > reco_daughter_PFP_true_byHits_startPy
std::vector< std::vector< int > > true_beam_reco_byHits_PFP_nHits
std::vector< double > reco_track_endZ
std::vector< double > reco_beam_calo_X_allTrack
std::vector< double > reco_beam_incidentEnergies_allTrack
std::vector< double > true_beam_traj_Z_SCE
std::vector< std::vector< double > > g4rw_full_grid_coeffs
std::vector< int > reco_daughter_PFP_nHits
std::vector< double > reco_daughter_PFP_true_byHits_startE
std::vector< double > reco_beam_calo_Y
std::vector< double > g4rw_alt_primary_minus_sigma_weight
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_startX
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_endX
double reco_beam_vertex_michel_score_weight_by_charge_allTrack
std::vector< double > reco_daughter_PFP_true_byE_purity
std::vector< std::vector< double > > g4rw_full_grid_proton_weights
std::vector< int > reco_beam_calo_TPC_NoSCE
std::vector< double > true_beam_daughter_startY
std::string reco_beam_true_byHits_endProcess
std::vector< double > reco_beam_calo_wire
std::vector< std::string > true_beam_processes
std::vector< double > true_beam_traj_Y
std::vector< std::vector< double > > reco_daughter_allTrack_dEdX_SCE
std::vector< double > true_beam_Pi0_decay_startPy
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_endY
std::vector< size_t > reco_daughter_PFP_true_byHits_sharedHits
EDIT: quality.
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_PFP_ID
std::vector< double > reco_beam_TrkPitch_SCE_allTrack
std::vector< std::vector< double > > reco_daughter_allTrack_calo_Y
std::vector< double > reco_daughter_allTrack_Phi
std::vector< size_t > reco_daughter_PFP_true_byHits_emHits
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dEdX_SCE_plane0
std::vector< double > reco_beam_calibrated_dQdX_SCE
std::vector< std::vector< int > > true_beam_reco_byHits_PFP_ID
std::vector< double > true_beam_daughter_startPx
std::vector< std::string > g4rw_primary_var
std::vector< double > true_beam_traj_Y_SCE
std::vector< int > reco_daughter_PFP_true_byHits_parPDG
std::vector< double > reco_daughter_PFP_true_byHits_startPx
std::vector< double > reco_beam_TrkPitch_SCE
std::vector< std::vector< double > > reco_daughter_allTrack_EField_SCE
double reco_beam_vertex_michel_score_weight_by_charge
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_allTrack_ID
std::vector< double > reco_beam_spacePts_X
std::vector< double > true_beam_daughter_startPy
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_len
std::vector< std::vector< double > > g4rw_full_grid_proton_coeffs
std::vector< double > reco_daughter_PFP_true_byHits_len
std::vector< std::vector< double > > g4rw_full_grid_neutron_coeffs
std::vector< double > reco_daughter_allTrack_endY
std::vector< double > reco_track_michel_score
std::vector< double > g4rw_alt_primary_plus_sigma_weight
std::vector< std::vector< int > > true_beam_reco_byHits_allTrack_ID
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dEdX_SCE_plane1
std::vector< double > true_beam_traj_Px
std::vector< int > reco_beam_calo_TPC
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_PFP_ID
std::vector< double > true_beam_elastic_deltaE
std::vector< int > beam_track_IDs
std::vector< double > reco_daughter_allShower_startX
std::vector< double > g4rw_primary_grid_pair_weights
std::vector< std::vector< double > > g4rw_full_grid_piminus_weights
std::vector< double > reco_beam_allTrack_resRange
std::vector< double > reco_daughter_allTrack_endX
std::vector< int > reco_daughter_allTrack_ID
std::vector< double > true_beam_traj_Pz
std::vector< double > true_beam_elastic_costheta
std::vector< std::vector< double > > g4rw_full_grid_weights
std::vector< std::string > true_beam_grand_daughter_endProcess
std::vector< std::vector< double > > g4rw_full_grid_kplus_weights
std::vector< std::vector< double > > reco_daughter_allTrack_resRange_SCE
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_startZ
std::vector< double > g4rw_primary_plus_sigma_weight
std::vector< double > reco_beam_calibrated_dEdX_SCE
std::vector< double > reco_track_endY
std::vector< double > reco_daughter_PFP_true_byHits_completeness
std::vector< double > reco_daughter_PFP_true_byE_completeness
std::vector< double > reco_daughter_allTrack_vertex_michel_score
std::vector< int > reco_daughter_PFP_ID
std::vector< double > reco_daughter_allShower_dirY
std::vector< double > true_beam_daughter_endZ
std::vector< int > reco_track_ID
std::vector< int > reco_daughter_allTrack_vertex_nHits
std::vector< double > reco_daughter_PFP_true_byHits_startY
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_len
std::vector< double > reco_beam_dQdX_SCE
std::vector< double > reco_beam_calo_wire_z_NoSCE
std::vector< double > reco_daughter_PFP_true_byHits_startP
std::vector< int > true_beam_Pi0_decay_nHits
std::vector< std::string > reco_daughter_PFP_true_byHits_endProcess
static int max(int a, int b)
std::vector< double > true_beam_Pi0_decay_startY
std::vector< double > true_beam_elastic_Y
std::vector< int > true_beam_Pi0_decay_parID
std::vector< std::vector< double > > reco_daughter_allTrack_calibrated_dEdX_SCE
std::vector< double > reco_daughter_allTrack_Theta
std::vector< std::vector< double > > reco_daughter_spacePts_Y
std::vector< double > reco_track_startY
std::vector< int > reco_daughter_pandora_type
std::vector< std::vector< double > > g4rw_full_grid_piplus_weights_fake_data
std::vector< std::vector< double > > reco_daughter_allTrack_resRange_plane1
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_allTrack_ID
std::vector< double > reco_daughter_PFP_michelScore_collection
std::vector< double > reco_daughter_PFP_true_byHits_endX
std::vector< double > true_beam_daughter_endY
std::vector< double > reco_beam_calo_wire_allTrack
std::vector< double > true_beam_daughter_len
std::vector< std::vector< double > > reco_daughter_spacePts_Z
std::vector< double > true_beam_traj_KE
std::vector< int > true_beam_daughter_PDG
std::vector< double > reco_beam_calibrated_dEdX_NoSCE
std::vector< int > true_beam_grand_daughter_nHits
std::vector< double > reco_beam_calo_Z
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_PFP_nHits
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_startY
std::vector< double > reco_daughter_allTrack_Chi2_proton
std::vector< double > reco_beam_calo_endDirX
std::vector< double > true_beam_daughter_endX
std::vector< double > g4rw_primary_weights
std::vector< int > true_beam_daughter_nHits
std::vector< int > true_beam_Pi0_decay_PDG
std::vector< int > true_beam_daughter_ID
std::vector< double > reco_daughter_allShower_dirX
std::vector< double > true_beam_daughter_startZ
std::vector< double > reco_daughter_allTrack_Chi2_proton_plane0
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_endZ
std::vector< double > true_beam_daughter_startX
std::vector< double > true_beam_traj_Py
std::vector< int > reco_track_nHits
std::vector< std::string > reco_daughter_PFP_true_byHits_process
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_startZ
std::vector< double > reco_daughter_PFP_emScore
std::vector< double > true_beam_traj_Z
std::vector< double > true_beam_Pi0_decay_startPz
std::vector< int > true_beam_grand_daughter_PDG
std::vector< std::vector< double > > reco_daughter_spacePts_X
std::vector< double > reco_daughter_PFP_true_byHits_endY
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_PFP_nHits
std::vector< double > reco_beam_calo_endDirY
std::vector< double > reco_beam_incidentEnergies
std::vector< std::vector< double > > reco_daughter_shower_spacePts_Y
std::vector< std::vector< double > > reco_daughter_allTrack_resRange_plane0
double reco_beam_PFP_michelScore_collection_weight_by_charge
std::vector< int > true_beam_grand_daughter_ID
std::vector< int > true_beam_slices_found
std::vector< double > reco_beam_resRange_NoSCE
std::vector< double > reco_beam_dQ
std::vector< double > reco_beam_dEdX_SCE
std::vector< double > true_beam_Pi0_decay_startX
std::vector< double > reco_daughter_PFP_trackScore
std::vector< double > true_beam_Pi0_decay_startP
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_len
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_allShower_ID
std::vector< std::vector< double > > g4rw_full_grid_neutron_weights
std::vector< double > reco_daughter_allShower_energy
std::vector< double > reco_daughter_allTrack_startX
std::vector< double > reco_daughter_PFP_true_byE_len
std::vector< double > beam_inst_TOF
std::vector< double > true_beam_elastic_Z
std::vector< double > true_beam_traj_X
std::vector< int > reco_daughter_allTrack_Chi2_ndof_plane0
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_startY
std::vector< double > reco_beam_calo_startDirZ
std::vector< std::vector< double > > reco_daughter_shower_spacePts_X
std::vector< double > reco_daughter_allTrack_momByRange_muon
std::vector< double > reco_daughter_PFP_trackScore_collection
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_endZ
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_endY
std::vector< double > reco_daughter_allShower_dirZ
std::vector< int > reco_daughter_PFP_true_byHits_origin
std::vector< double > reco_daughter_allShower_len
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_allShower_ID
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_startX
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_len
std::string reco_beam_true_byHits_process
std::vector< std::vector< double > > g4rw_full_grid_kplus_coeffs
std::vector< int > reco_daughter_allTrack_Chi2_ndof_pion
std::vector< double > reco_daughter_PFP_true_byHits_endZ
std::vector< int > true_beam_grand_daughter_parID
std::vector< double > reco_beam_dQdX_NoSCE
std::vector< double > reco_daughter_allTrack_len
std::vector< double > reco_daughter_PFP_true_byHits_startPz
std::vector< std::vector< double > > g4rw_full_grid_piplus_coeffs
std::vector< double > reco_daughter_PFP_emScore_collection
std::vector< double > reco_beam_calo_endDirZ
std::vector< int > reco_daughter_allTrack_Chi2_ndof_muon
std::vector< double > reco_daughter_allShower_startZ
std::vector< double > reco_daughter_allTrack_momByRange_alt_proton
std::vector< double > reco_beam_calo_tick
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_startY
std::vector< double > reco_daughter_PFP_true_byHits_purity
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_startY
std::vector< double > true_beam_elastic_X
std::vector< double > reco_daughter_allTrack_startY
void pduneana::PDSPAnalyzer::TrueBeamInfo ( const art::Event evt,
const simb::MCParticle true_beam_particle,
detinfo::DetectorClocksData const &  clockData,
const sim::ParticleList &  plist,
std::map< int, std::vector< int >> &  trueToPFPs,
anab::MVAReader< recob::Hit, 4 > *  hitResults 
)
private

Definition at line 3010 of file PDSPAnalyzer_module.cc.

3015  {
3016  auto pfpVec
3017  = evt.getValidHandle<std::vector<recob::PFParticle>>(fPFParticleTag);
3018  true_beam_endProcess = true_beam_particle->EndProcess();
3019  true_beam_PDG = true_beam_particle->PdgCode();
3020  true_beam_mass = true_beam_particle->Mass()*1.e3;
3021  true_beam_ID = true_beam_particle->TrackId();
3022  true_beam_endX = true_beam_particle->EndX();
3023  true_beam_endY = true_beam_particle->EndY();
3024  true_beam_endZ = true_beam_particle->EndZ();
3025  true_beam_startX = true_beam_particle->Position(0).X();
3026  true_beam_startY = true_beam_particle->Position(0).Y();
3027  true_beam_startZ = true_beam_particle->Position(0).Z();
3028 
3029  auto sce = lar::providerFrom<spacecharge::SpaceChargeService>();
3030  auto offset = sce->GetPosOffsets(
3032  true_beam_endX_SCE = true_beam_endX - offset.X();
3033  true_beam_endY_SCE = true_beam_endY + offset.Y();
3034  true_beam_endZ_SCE = true_beam_endZ + offset.Z();
3035 
3036 
3037  true_beam_startPx = true_beam_particle->Px();
3038  true_beam_startPy = true_beam_particle->Py();
3039  true_beam_startPz = true_beam_particle->Pz();
3040  true_beam_startP = true_beam_particle->P();
3041 
3042  size_t true_np = true_beam_particle->NumberTrajectoryPoints();
3043 
3044  true_beam_endPx = true_beam_particle->Px(true_np-2);
3045  true_beam_endPy = true_beam_particle->Py(true_np-2);
3046  true_beam_endPz = true_beam_particle->Pz(true_np-2);
3047  true_beam_endP = true_beam_particle->P(true_np-2);
3048  true_beam_endP2 = true_beam_particle->P(true_np-1);
3049 
3051  = sqrt(std::pow((true_beam_particle->Position(true_np-2).X() -
3052  true_beam_particle->Position(true_np-1).X()), 2) +
3053  std::pow((true_beam_particle->Position(true_np-2).Y() -
3054  true_beam_particle->Position(true_np-1).Y()), 2) +
3055  std::pow((true_beam_particle->Position(true_np-2).Z() -
3056  true_beam_particle->Position(true_np-1).Z()), 2));
3057 
3061 
3062  true_beam_nHits = truthUtil.GetMCParticleHits( clockData, *true_beam_particle, evt, fHitTag ).size();
3063 
3064  //Checking all reconstructed objects to see what the true beam particle
3065  //contributed to
3066  true_beam_reco_byHits_PFP_ID.push_back( std::vector< int >() );
3067  true_beam_reco_byHits_PFP_nHits.push_back( std::vector< int >() );
3068  true_beam_reco_byHits_allTrack_ID.push_back( std::vector< int >() );
3069  if( fTrueToReco ){
3070  for( size_t i = 0; i < trueToPFPs[ true_beam_ID ].size(); ++i ){
3071  true_beam_reco_byHits_PFP_ID.back().push_back( trueToPFPs[ true_beam_ID ][i] );
3072 
3073  const recob::PFParticle * thePFP = &(pfpVec->at( trueToPFPs[ true_beam_ID ][i] ));
3074  true_beam_reco_byHits_PFP_nHits.back().push_back(
3075  pfpUtil.GetPFParticleHits_Ptrs( *thePFP, evt, fPFParticleTag ).size()
3076  );
3077 
3078  const recob::Track* pandora2Track = 0x0;
3079 
3080  try{
3081  pandora2Track = pfpUtil.GetPFParticleTrack( *thePFP, evt, fPFParticleTag, "pandora2Track" );
3082  }
3083  catch( const cet::exception &e ){
3084  MF_LOG_WARNING("PDSPAnalyzer") << "pandora2Track object not found, moving on" << std::endl;
3085  }
3086 
3087  if( pandora2Track ){
3088  true_beam_reco_byHits_allTrack_ID.back().push_back( pandora2Track->ID() );
3089  }
3090  else{
3091  true_beam_reco_byHits_allTrack_ID.back().push_back( -1 );
3092  }
3093  }
3094  }
3095 
3096  //Truth thin slice info
3097  //Go through the true processes within the MCTrajectory
3098  const simb::MCTrajectory & true_beam_trajectory = true_beam_particle->Trajectory();
3099  auto true_beam_proc_map = true_beam_trajectory.TrajectoryProcesses();
3100  if (fVerbose) std::cout << "Processes: " << std::endl;
3101 
3102  for( auto itProc = true_beam_proc_map.begin(); itProc != true_beam_proc_map.end(); ++itProc ){
3103  int index = itProc->first;
3104  std::string process = true_beam_trajectory.KeyToProcess(itProc->second);
3105  if (fVerbose) std::cout << index << " " << process << std::endl;
3106 
3107  true_beam_processes.push_back( process );
3108 
3109  if( process == "hadElastic" ){
3110 
3112 
3113  double process_X = true_beam_trajectory.X( index );
3114  double process_Y = true_beam_trajectory.Y( index );
3115  double process_Z = true_beam_trajectory.Z( index );
3116 
3117  double PX = true_beam_trajectory.Px( index );
3118  double next_PX = true_beam_trajectory.Px( index + 1 );
3119  double PY = true_beam_trajectory.Py( index );
3120  double next_PY = true_beam_trajectory.Py( index + 1 );
3121  double PZ = true_beam_trajectory.Pz( index );
3122  double next_PZ = true_beam_trajectory.Pz( index + 1 );
3123 
3124  double total_P = sqrt( PX*PX + PY*PY + PZ*PZ );
3125  double total_next_P = sqrt( next_PX*next_PX + next_PY*next_PY + next_PZ*next_PZ );
3126 
3127  //Get the angle between the direction of this step and the next
3128  true_beam_elastic_costheta.push_back(
3129  ( ( PX * next_PX ) + ( PY * next_PY ) + ( PZ * next_PZ ) ) / ( total_P * total_next_P )
3130  );
3131 
3132  double total_E = sqrt(total_P*total_P*1.e6 +
3134  double total_next_E = sqrt(total_next_P*total_next_P*1.e6 +
3136 
3137  true_beam_elastic_X.push_back( process_X );
3138  true_beam_elastic_Y.push_back( process_Y );
3139  true_beam_elastic_Z.push_back( process_Z );
3140 
3141  true_beam_elastic_deltaE.push_back(total_E - total_next_E);
3142 
3143  std::vector<const sim::IDE *> ides_between_points =
3145  *true_beam_particle, true_beam_trajectory.Position(index),
3146  true_beam_trajectory.Position(index +1));
3147 
3148  double total_edep = 0.;
3149  for (size_t i = 0; i < ides_between_points.size(); ++i) {
3150  total_edep += ides_between_points[i]->energy;
3151  }
3152  true_beam_elastic_IDE_edep.push_back(total_edep);
3153 
3154  }
3155  }
3156  if( true_beam_endProcess.find( "Inelastic" ) == std::string::npos ){
3157  true_beam_processes.push_back( true_beam_endProcess );
3158  }
3159 
3160 
3161  //Looking at info from IDEs -- simulated energy depositions
3162  //To do: might remove because the IDEs are 'eaten up' due to various
3163  //changes in the simulation. So their original intent
3164  //(determining slices for thin slice method) was made useless
3165  if (fVerbose) std::cout << "Looking at IDEs" << std::endl;
3166  auto view2_IDEs = bt_serv->TrackIdToSimIDEs_Ps( true_beam_ID, geo::View_t(2) );
3167  if (fVerbose) std::cout << "N view2 IDEs: " << view2_IDEs.size() << std::endl;
3168 
3170  for (size_t i = 0; i < view2_IDEs.size(); ++i) {
3171  const sim::IDE * ide = view2_IDEs[i];
3172 
3174  }
3175  //Sort based on ide z-position
3176  std::sort( view2_IDEs.begin(), view2_IDEs.end(), sort_IDEs );
3177 
3178  //This is an attempt to remove IDEs from things like delta-rays
3179  //that have a large gap in z to the previous
3180  size_t remove_index = 0;
3181  bool do_remove = false;
3182  if( view2_IDEs.size() ){
3183  for( size_t i = 1; i < view2_IDEs.size()-1; ++i ){
3184  const sim::IDE * prev_IDE = view2_IDEs[i-1];
3185  const sim::IDE * this_IDE = view2_IDEs[i];
3186 
3187  if (this_IDE->trackID < 0.) {
3188  em_energy += this_IDE->energy;
3189  }
3190 
3191 
3192  if( this_IDE->trackID < 0 && ( this_IDE->z - prev_IDE->z ) > 5 ){
3193  remove_index = i;
3194  do_remove = true;
3195  break;
3196  }
3197  }
3198  }
3199 
3200  if( do_remove ){
3201  view2_IDEs.erase( view2_IDEs.begin() + remove_index, view2_IDEs.end() );
3202  }
3203 
3204  double init_KE = sqrt(1.e6 * true_beam_startP*true_beam_startP +
3206 
3207  //slice up the view2_IDEs up by the wire pitch
3208  auto sliced_ides = slice_IDEs( view2_IDEs, fZ0, fPitch, true_beam_endZ);
3209  //Get the momentum at the start of the slices.
3210  //Get the first slice
3211  if (fVerbose) std::cout << "size: " << sliced_ides.size() << std::endl;
3212  if (sliced_ides.size()) {
3213  auto first_slice = sliced_ides.begin();
3214  if (fVerbose) std::cout << "Got first slice" << std::endl;
3215 
3216  //Check it has any IDEs
3217  auto theIDEs = first_slice->second;
3218  if (fVerbose) std::cout << "Got ides" << std::endl;
3219  if (theIDEs.size()) {
3220  //Get the first ide z position
3221  double ide_z = theIDEs[0]->z;
3222 
3223  //Go through the trajectory position
3224  //and check for the position that comes immediately before the
3225  //first ide
3226  for (size_t i = 1; i < true_beam_trajectory.size(); ++i) {
3227  double z0 = true_beam_trajectory.Z(i-1);
3228  double z1 = true_beam_trajectory.Z(i);
3229 
3230  double x0 = true_beam_trajectory.X(i-1);
3231  double y0 = true_beam_trajectory.Y(i-1);
3232  double x1 = true_beam_trajectory.X(i);
3233  double y1 = true_beam_trajectory.Y(i);
3234  geo::Point_t test_point{x0, y0, z0};
3235  geo::Point_t test_point_1{x1, y1, z1};
3236  //const TGeoMaterial * mat = geom->Material(test_point);
3237  if (z0 < ide_z && z1 > ide_z) {
3238  //const TGeoMaterial * mat1 = geom->Material(test_point_1);
3239  init_KE = 1.e3 * true_beam_trajectory.E(i-1) - true_beam_mass;
3240  if (fVerbose) {
3241  std::cout << "Found matching position" << z0 << " " << ide_z <<
3242  " " << z1 << std::endl;
3243  std::cout << "init KE: " << init_KE << " " <<
3244  (1.e3*true_beam_trajectory.E(i) - true_beam_mass) << std::endl;
3245  }
3246  break;
3247  }
3248  }
3249  }
3250  }
3251 
3252  //Go through the sliced up IDEs to create the thin targets
3253  true_beam_incidentEnergies.push_back( init_KE );
3254  for( auto it = sliced_ides.begin(); it != sliced_ides.end(); ++it ){
3255 
3256  auto theIDEs = it->second;
3257 
3258  true_beam_slices.push_back( it->first );
3259 
3260  double deltaE = 0.;
3261  for( size_t i = 0; i < theIDEs.size(); ++i ){
3262  deltaE += theIDEs[i]->energy;
3263  }
3264 
3265  true_beam_slices_deltaE.push_back( deltaE );
3266  true_beam_incidentEnergies.push_back( true_beam_incidentEnergies.back() - deltaE );
3267  }
3268  true_beam_incidentEnergies.pop_back();
3270 
3271  //Save the trajectory points
3272  for (size_t i = 0; i < true_beam_trajectory.size(); ++i) {
3273  true_beam_traj_X.push_back(true_beam_trajectory.X(i));
3274  true_beam_traj_Y.push_back(true_beam_trajectory.Y(i));
3275  true_beam_traj_Z.push_back(true_beam_trajectory.Z(i));
3276  true_beam_traj_Px.push_back(true_beam_trajectory.Px(i));
3277  true_beam_traj_Py.push_back(true_beam_trajectory.Py(i));
3278  true_beam_traj_Pz.push_back(true_beam_trajectory.Pz(i));
3279 
3280  true_beam_traj_KE.push_back(true_beam_trajectory.E(i)*1.e3 - true_beam_mass);
3281 
3282  auto offset = sce->GetPosOffsets(
3283  {true_beam_trajectory.X(i), true_beam_trajectory.Y(i),
3284  true_beam_trajectory.Z(i)});
3285  true_beam_traj_X_SCE.push_back(true_beam_trajectory.X(i) - offset.X());
3286  true_beam_traj_Y_SCE.push_back(true_beam_trajectory.Y(i) + offset.Y());
3287  true_beam_traj_Z_SCE.push_back(true_beam_trajectory.Z(i) + offset.Z());
3288  }
3289  true_beam_len = 0;
3290  for (size_t i = 1; i < true_beam_trajectory.size(); ++i) {
3291  true_beam_len += sqrt( pow( true_beam_traj_X.at(i)-true_beam_traj_X.at(i-1), 2)
3292  + pow( true_beam_traj_Y.at(i)-true_beam_traj_Y.at(i-1), 2)
3293  + pow( true_beam_traj_Z.at(i)-true_beam_traj_Z.at(i-1), 2));
3294  }
3295 
3296  //Look through the daughters
3297  for( int i = 0; i < true_beam_particle->NumberDaughters(); ++i ){
3298  int daughterID = true_beam_particle->Daughter(i);
3299 
3300  if (fVerbose) std::cout << "Daughter " << i << " ID: " << daughterID << std::endl;
3301  auto part = plist[ daughterID ];
3302  int pid = part->PdgCode();
3303 
3304  std::string process = part->Process();
3305 
3306  if (process == "muIoni" || process == "hIoni")
3307  continue;
3308 
3309  true_beam_daughter_PDG.push_back(pid);
3310  true_beam_daughter_ID.push_back( part->TrackId() );
3311 
3312  true_beam_daughter_len.push_back( part->Trajectory().TotalLength() );
3313 
3314  true_beam_daughter_startX.push_back( part->Position(0).X() );
3315  true_beam_daughter_startY.push_back( part->Position(0).Y() );
3316  true_beam_daughter_startZ.push_back( part->Position(0).Z() );
3317 
3318  true_beam_daughter_endX.push_back( part->EndX() );
3319  true_beam_daughter_endY.push_back( part->EndY() );
3320  true_beam_daughter_endZ.push_back( part->EndZ() );
3321 
3322  true_beam_daughter_startPx.push_back( part->Px() );
3323  true_beam_daughter_startPy.push_back( part->Py() );
3324  true_beam_daughter_startPz.push_back( part->Pz() );
3325  true_beam_daughter_startP.push_back( part->P() );
3326 
3327  true_beam_daughter_Process.push_back( part->Process() );
3328  true_beam_daughter_endProcess.push_back( part->EndProcess() );
3329 
3330  if (fVerbose) {
3331  std::cout << "Process: " << part->Process() << std::endl;
3332  std::cout << "PID: " << pid << std::endl;
3333  std::cout << "Start: " << part->Position(0).X() << " " << part->Position(0).Y() << " " << part->Position(0).Z() << std::endl;
3334  std::cout << "End: " << part->EndPosition().X() << " " << part->EndPosition().Y() << " " << part->EndPosition().Z() << std::endl;
3335  std::cout << "Len: " << part->Trajectory().TotalLength() << std::endl;
3336  }
3337 
3338  if( part->Process().find( "Inelastic" ) != std::string::npos ){
3339  if( pid == 211 ) ++true_daughter_nPiPlus;
3340  if( pid == -211 ) ++true_daughter_nPiMinus;
3341  if( pid == 111 ) ++true_daughter_nPi0;
3342  if( pid == 2212 ) ++true_daughter_nProton;
3343  if( pid == 2112 ) ++true_daughter_nNeutron;
3344  if( pid > 2212 ) ++true_daughter_nNucleus;
3345  }
3346 
3347  //Look for the gammas coming out of the pi0s
3348  if( pid == 111 ){
3349  //std::cout << "Found pi0. Looking at true daughters" << std::endl;
3350  for( int j = 0; j < part->NumberDaughters(); ++j ){
3351  int pi0_decay_daughter_ID = part->Daughter(j);
3352  auto pi0_decay_part = plist[ pi0_decay_daughter_ID ];
3353  true_beam_Pi0_decay_PDG.push_back( pi0_decay_part->PdgCode() );
3354  true_beam_Pi0_decay_ID.push_back( pi0_decay_part->TrackId() );
3355  true_beam_Pi0_decay_startP.push_back( pi0_decay_part->P() );
3356  true_beam_Pi0_decay_startPx.push_back( pi0_decay_part->Px() );
3357  true_beam_Pi0_decay_startPy.push_back( pi0_decay_part->Py() );
3358  true_beam_Pi0_decay_startPz.push_back( pi0_decay_part->Pz() );
3359  true_beam_Pi0_decay_startX.push_back( pi0_decay_part->Position(0).X() );
3360  true_beam_Pi0_decay_startY.push_back( pi0_decay_part->Position(0).Y() );
3361  true_beam_Pi0_decay_startZ.push_back( pi0_decay_part->Position(0).Z() );
3362  true_beam_Pi0_decay_parID.push_back( pi0_decay_part->Mother() );
3363 
3364  true_beam_Pi0_decay_len.push_back( pi0_decay_part->Trajectory().TotalLength() );
3365  true_beam_Pi0_decay_nHits.push_back( truthUtil.GetMCParticleHits( clockData, *pi0_decay_part, evt, fHitTag ).size() );
3366 
3367  true_beam_Pi0_decay_reco_byHits_PFP_ID.push_back( std::vector<int>() );
3368  true_beam_Pi0_decay_reco_byHits_PFP_nHits.push_back( std::vector<int>() );
3369  true_beam_Pi0_decay_reco_byHits_PFP_trackScore.push_back( std::vector<double>() );
3370 
3371  true_beam_Pi0_decay_reco_byHits_allTrack_ID.push_back( std::vector<int>() );
3372  true_beam_Pi0_decay_reco_byHits_allTrack_startX.push_back( std::vector<double>() );
3373  true_beam_Pi0_decay_reco_byHits_allTrack_startY.push_back( std::vector<double>() );
3374  true_beam_Pi0_decay_reco_byHits_allTrack_startZ.push_back( std::vector<double>() );
3375  true_beam_Pi0_decay_reco_byHits_allTrack_len.push_back( std::vector<double>() );
3376  true_beam_Pi0_decay_reco_byHits_allTrack_endX.push_back( std::vector<double>() );
3377  true_beam_Pi0_decay_reco_byHits_allTrack_endY.push_back( std::vector<double>() );
3378  true_beam_Pi0_decay_reco_byHits_allTrack_endZ.push_back( std::vector<double>() );
3379  true_beam_Pi0_decay_reco_byHits_allShower_ID.push_back( std::vector<int>() );
3380  true_beam_Pi0_decay_reco_byHits_allShower_startX.push_back( std::vector<double>() );
3381  true_beam_Pi0_decay_reco_byHits_allShower_startY.push_back( std::vector<double>() );
3382  true_beam_Pi0_decay_reco_byHits_allShower_startZ.push_back( std::vector<double>() );
3383  true_beam_Pi0_decay_reco_byHits_allShower_len.push_back( std::vector<double>() );
3384  if( fTrueToReco ){
3385  for( size_t k = 0; k < trueToPFPs[ pi0_decay_part->TrackId() ].size(); ++k ){
3386  true_beam_Pi0_decay_reco_byHits_PFP_ID.back().push_back( trueToPFPs[ pi0_decay_part->TrackId() ][k] );
3387 
3388  const recob::PFParticle * thePFP = &(pfpVec->at( trueToPFPs[ pi0_decay_part->TrackId() ][k] ));
3390  pfpUtil.GetPFParticleHits_Ptrs( *thePFP, evt, fPFParticleTag ).size()
3391  );
3392 
3393  if (!fSkipMVA) {
3394  cnnOutput2D theCNNResults = GetCNNOutputFromPFParticle( *thePFP, evt, *hitResults, pfpUtil, fPFParticleTag );
3395  double track_score = ((theCNNResults.nHits > 0) ?
3396  (theCNNResults.track / theCNNResults.nHits) :
3397  -999.);
3398  true_beam_Pi0_decay_reco_byHits_PFP_trackScore.back().push_back(track_score);
3399  }
3400  else {
3401  true_beam_Pi0_decay_reco_byHits_PFP_trackScore.back().push_back(-999.);
3402  }
3403 
3404  const recob::Track* pandora2Track = 0x0;
3405  try{
3406  pandora2Track = pfpUtil.GetPFParticleTrack( *thePFP, evt, fPFParticleTag, "pandora2Track" );
3407  }
3408  catch( const cet::exception &e ){
3409  MF_LOG_WARNING("PDSPAnalyzer") << "pandora2Track object not found, moving on" << std::endl;
3410  }
3411 
3412  if( pandora2Track ){
3413  true_beam_Pi0_decay_reco_byHits_allTrack_ID.back().push_back( pandora2Track->ID() );
3414  true_beam_Pi0_decay_reco_byHits_allTrack_startX.back().push_back( pandora2Track->Trajectory().Start().X() );
3415  true_beam_Pi0_decay_reco_byHits_allTrack_startY.back().push_back( pandora2Track->Trajectory().Start().Y() );
3416  true_beam_Pi0_decay_reco_byHits_allTrack_startZ.back().push_back( pandora2Track->Trajectory().Start().Z() );
3417  true_beam_Pi0_decay_reco_byHits_allTrack_endX.back().push_back( pandora2Track->Trajectory().End().X() );
3418  true_beam_Pi0_decay_reco_byHits_allTrack_endY.back().push_back( pandora2Track->Trajectory().End().Y() );
3419  true_beam_Pi0_decay_reco_byHits_allTrack_endZ.back().push_back( pandora2Track->Trajectory().End().Z() );
3420  true_beam_Pi0_decay_reco_byHits_allTrack_len.back().push_back( pandora2Track->Length() );
3421 
3422  }
3423  else{
3424  true_beam_Pi0_decay_reco_byHits_allTrack_ID.back().push_back( -999 );
3425  true_beam_Pi0_decay_reco_byHits_allTrack_startX.back().push_back( -999. );
3426  true_beam_Pi0_decay_reco_byHits_allTrack_startY.back().push_back( -999. );
3427  true_beam_Pi0_decay_reco_byHits_allTrack_startZ.back().push_back( -999. );
3428  true_beam_Pi0_decay_reco_byHits_allTrack_endX.back().push_back( -999. );
3429  true_beam_Pi0_decay_reco_byHits_allTrack_endY.back().push_back( -999. );
3430  true_beam_Pi0_decay_reco_byHits_allTrack_endZ.back().push_back( -999. );
3431  true_beam_Pi0_decay_reco_byHits_allTrack_len.back().push_back( -999. );
3432  }
3433 
3434  const recob::Shower* pandora2Shower = 0x0;
3435  try{
3436  pandora2Shower = pfpUtil.GetPFParticleShower( *thePFP, evt, fPFParticleTag, "pandora2Shower" );
3437  }
3438  catch( const cet::exception &e ){
3439  MF_LOG_WARNING("PDSPAnalyzer") << "pandora2Shower object not found, moving on" << std::endl;
3440  }
3441 
3442  if( pandora2Shower ){
3443  true_beam_Pi0_decay_reco_byHits_allShower_ID.back().push_back( pandora2Shower->ID() );
3444  true_beam_Pi0_decay_reco_byHits_allShower_startX.back().push_back( pandora2Shower->ShowerStart().X() );
3445  true_beam_Pi0_decay_reco_byHits_allShower_startY.back().push_back( pandora2Shower->ShowerStart().Y() );
3446  true_beam_Pi0_decay_reco_byHits_allShower_startZ.back().push_back( pandora2Shower->ShowerStart().Z() );
3447  true_beam_Pi0_decay_reco_byHits_allShower_len.back().push_back( pandora2Shower->Length() );
3448  }
3449  else{
3450  true_beam_Pi0_decay_reco_byHits_allShower_ID.back().push_back( -999 );
3451  true_beam_Pi0_decay_reco_byHits_allShower_startX.back().push_back( -999. );
3452  true_beam_Pi0_decay_reco_byHits_allShower_startY.back().push_back( -999. );
3453  true_beam_Pi0_decay_reco_byHits_allShower_startZ.back().push_back( -999. );
3454  true_beam_Pi0_decay_reco_byHits_allShower_len.back().push_back( -999. );
3455  }
3456 
3457  }
3458  }
3459  }
3460  }
3461 
3462  //Look another level down
3463  for( int j = 0; j < part->NumberDaughters(); ++j ){
3464  int grand_daughter_ID = part->Daughter(j);
3465  auto grand_daughter_part = plist[ grand_daughter_ID ];
3466  true_beam_grand_daughter_PDG.push_back( grand_daughter_part->PdgCode() );
3467  true_beam_grand_daughter_ID.push_back( grand_daughter_part->TrackId() );
3468  true_beam_grand_daughter_parID.push_back( part->TrackId() );
3469  true_beam_grand_daughter_nHits.push_back( truthUtil.GetMCParticleHits( clockData, *grand_daughter_part, evt, fHitTag ).size() );
3470  true_beam_grand_daughter_Process.push_back( grand_daughter_part->Process() );
3471  true_beam_grand_daughter_endProcess.push_back( grand_daughter_part->EndProcess() );
3472  }
3473 
3474 
3475 
3476  //Same dumb cross checking of true particles to reconstructed objects
3477  //To do: might remove
3478  true_beam_daughter_reco_byHits_PFP_ID.push_back( std::vector<int>() );
3479  true_beam_daughter_reco_byHits_PFP_nHits.push_back( std::vector<int>() );
3480  true_beam_daughter_reco_byHits_PFP_trackScore.push_back( std::vector<double>() );
3481 
3482  true_beam_daughter_reco_byHits_allTrack_ID.push_back( std::vector<int>() );
3483  true_beam_daughter_reco_byHits_allTrack_startX.push_back( std::vector<double>() );
3484  true_beam_daughter_reco_byHits_allTrack_startY.push_back( std::vector<double>() );
3485  true_beam_daughter_reco_byHits_allTrack_startZ.push_back( std::vector<double>() );
3486  true_beam_daughter_reco_byHits_allTrack_len.push_back( std::vector<double>() );
3487  true_beam_daughter_reco_byHits_allTrack_endX.push_back( std::vector<double>() );
3488  true_beam_daughter_reco_byHits_allTrack_endY.push_back( std::vector<double>() );
3489  true_beam_daughter_reco_byHits_allTrack_endZ.push_back( std::vector<double>() );
3490  true_beam_daughter_reco_byHits_allShower_ID.push_back( std::vector<int>() );
3491  true_beam_daughter_reco_byHits_allShower_startX.push_back( std::vector<double>() );
3492  true_beam_daughter_reco_byHits_allShower_startY.push_back( std::vector<double>() );
3493  true_beam_daughter_reco_byHits_allShower_startZ.push_back( std::vector<double>() );
3494  true_beam_daughter_reco_byHits_allShower_len.push_back( std::vector<double>() );
3495  if( fTrueToReco ){
3496  for( size_t j = 0; j < trueToPFPs[ part->TrackId() ].size(); ++j ){
3497  true_beam_daughter_reco_byHits_PFP_ID.back().push_back( trueToPFPs[ part->TrackId() ][j] );
3498 
3499  const recob::PFParticle * thePFP = &(pfpVec->at( trueToPFPs[ part->TrackId() ][j] ));
3501  pfpUtil.GetPFParticleHits_Ptrs( *thePFP, evt, fPFParticleTag ).size()
3502  );
3503 
3504  if (!fSkipMVA) {
3505  cnnOutput2D theCNNResults = GetCNNOutputFromPFParticle( *thePFP, evt, *hitResults, pfpUtil, fPFParticleTag );
3506  double track_score = ((theCNNResults.nHits > 0) ?
3507  (theCNNResults.track / theCNNResults.nHits) :
3508  -999.);
3509  true_beam_daughter_reco_byHits_PFP_trackScore.back().push_back(track_score);
3510  }
3511  else {
3512  true_beam_daughter_reco_byHits_PFP_trackScore.back().push_back(-999.);
3513  }
3514 
3515  //cnnOutput2D theCNNResults = GetCNNOutputFromPFParticle( *thePFP, evt, *hitResults, pfpUtil, fPFParticleTag );
3516  //true_beam_daughter_reco_byHits_PFP_trackScore.back().push_back( ( ( theCNNResults.nHits > 0 ) ? ( theCNNResults.track / theCNNResults.nHits ) : -999. ) );
3517 
3518  const recob::Track* pandora2Track = 0x0;
3519  try{
3520  pandora2Track = pfpUtil.GetPFParticleTrack( *thePFP, evt, fPFParticleTag, "pandora2Track" );
3521  }
3522  catch( const cet::exception &e ){
3523  MF_LOG_WARNING("PDSPAnalyzer") << "pandora2Track object not found, moving on" << std::endl;
3524  }
3525 
3526  if( pandora2Track ){
3527  true_beam_daughter_reco_byHits_allTrack_ID.back().push_back( pandora2Track->ID() );
3528  true_beam_daughter_reco_byHits_allTrack_startX.back().push_back( pandora2Track->Trajectory().Start().X() );
3529  true_beam_daughter_reco_byHits_allTrack_startY.back().push_back( pandora2Track->Trajectory().Start().Y() );
3530  true_beam_daughter_reco_byHits_allTrack_startZ.back().push_back( pandora2Track->Trajectory().Start().Z() );
3531  true_beam_daughter_reco_byHits_allTrack_endX.back().push_back( pandora2Track->Trajectory().End().X() );
3532  true_beam_daughter_reco_byHits_allTrack_endY.back().push_back( pandora2Track->Trajectory().End().Y() );
3533  true_beam_daughter_reco_byHits_allTrack_endZ.back().push_back( pandora2Track->Trajectory().End().Z() );
3534  true_beam_daughter_reco_byHits_allTrack_len.back().push_back( pandora2Track->Length() );
3535 
3536  }
3537  else{
3538  true_beam_daughter_reco_byHits_allTrack_ID.back().push_back( -999 );
3539  true_beam_daughter_reco_byHits_allTrack_startX.back().push_back( -999. );
3540  true_beam_daughter_reco_byHits_allTrack_startY.back().push_back( -999. );
3541  true_beam_daughter_reco_byHits_allTrack_startZ.back().push_back( -999. );
3542  true_beam_daughter_reco_byHits_allTrack_endX.back().push_back( -999. );
3543  true_beam_daughter_reco_byHits_allTrack_endY.back().push_back( -999. );
3544  true_beam_daughter_reco_byHits_allTrack_endZ.back().push_back( -999. );
3545  true_beam_daughter_reco_byHits_allTrack_len.back().push_back( -999. );
3546  }
3547 
3548  const recob::Shower* pandora2Shower = 0x0;
3549  try{
3550  pandora2Shower = pfpUtil.GetPFParticleShower( *thePFP, evt, fPFParticleTag, "pandora2Shower" );
3551  }
3552  catch( const cet::exception &e ){
3553  MF_LOG_WARNING("PDSPAnalyzer") << "pandora2Shower object not found, moving on" << std::endl;
3554  }
3555 
3556  if( pandora2Shower ){
3557  true_beam_daughter_reco_byHits_allShower_ID.back().push_back( pandora2Shower->ID() );
3558  true_beam_daughter_reco_byHits_allShower_startX.back().push_back( pandora2Shower->ShowerStart().X() );
3559  true_beam_daughter_reco_byHits_allShower_startY.back().push_back( pandora2Shower->ShowerStart().Y() );
3560  true_beam_daughter_reco_byHits_allShower_startZ.back().push_back( pandora2Shower->ShowerStart().Z() );
3561  true_beam_daughter_reco_byHits_allShower_len.back().push_back( pandora2Shower->Length() );
3562 
3563  }
3564  else{
3565  true_beam_daughter_reco_byHits_allShower_ID.back().push_back( -999 );
3566  true_beam_daughter_reco_byHits_allShower_startX.back().push_back( -999. );
3567  true_beam_daughter_reco_byHits_allShower_startY.back().push_back( -999. );
3568  true_beam_daughter_reco_byHits_allShower_startZ.back().push_back( -999. );
3569  true_beam_daughter_reco_byHits_allShower_len.back().push_back( -999. );
3570  }
3571 
3572  }
3573  }
3574  true_beam_daughter_nHits.push_back( truthUtil.GetMCParticleHits( clockData, *part, evt, fHitTag ).size() );
3575 
3576  }
3577 }
std::vector< double > true_beam_traj_X_SCE
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_PFP_trackScore
TrackID_t trackID
Geant4 supplied track ID.
Definition: SimChannel.h:112
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_startX
std::vector< double > true_beam_incidentEnergies
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_startX
unsigned int NumberTrajectoryPoints() const
Definition: MCParticle.h:218
const TVector3 & ShowerStart() const
Definition: Shower.h:192
const TLorentzVector & Position(const int i=0) const
Definition: MCParticle.h:219
double Z(const size_type i) const
Definition: MCTrajectory.h:151
double X(const size_type i) const
Definition: MCTrajectory.h:149
std::vector< double > true_beam_daughter_startPz
float z
z position of ionization [cm]
Definition: SimChannel.h:117
int PdgCode() const
Definition: MCParticle.h:212
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_PFP_trackScore
std::vector< int > true_beam_Pi0_decay_ID
double Py(const int i=0) const
Definition: MCParticle.h:231
std::vector< double > true_beam_elastic_IDE_edep
std::vector< double > true_beam_Pi0_decay_len
std::vector< int > true_beam_slices
std::vector< double > true_beam_slices_deltaE
double EndZ() const
Definition: MCParticle.h:228
double E(const size_type i) const
Definition: MCTrajectory.h:156
std::vector< double > true_beam_Pi0_decay_startZ
std::vector< double > true_beam_Pi0_decay_startPx
double Length() const
Definition: Shower.h:201
const recob::Shower * GetPFParticleShower(const recob::PFParticle &particle, art::Event const &evt, const std::string particleLabel, const std::string showerLabel) const
Get the shower associated to this particle. Returns a null pointer if not found.
enum geo::_plane_proj View_t
Enumerate the possible plane projections.
std::string string
Definition: nybbler.cc:12
const simb::MCTrajectory & Trajectory() const
Definition: MCParticle.h:253
std::vector< std::string > true_beam_grand_daughter_Process
const recob::TrackTrajectory & Trajectory() const
Access to the stored recob::TrackTrajectory.
Definition: Track.h:98
std::vector< std::string > true_beam_daughter_endProcess
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_startZ
double Pz(const size_type i) const
Definition: MCTrajectory.h:155
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_endX
double Mass() const
Definition: MCParticle.h:239
constexpr T pow(T x)
Definition: pow.h:72
std::string KeyToProcess(unsigned char const &key) const
std::vector< double > true_beam_daughter_startP
double Px(const int i=0) const
Definition: MCParticle.h:230
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_startZ
art::ServiceHandle< cheat::BackTrackerService > bt_serv
std::vector< std::string > true_beam_daughter_Process
std::vector< const sim::IDE * > TrackIdToSimIDEs_Ps(int const &id) const
std::vector< std::vector< int > > true_beam_reco_byHits_PFP_nHits
std::vector< double > true_beam_traj_Z_SCE
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_startX
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_endX
double EndY() const
Definition: MCParticle.h:227
std::vector< double > true_beam_daughter_startY
std::vector< std::string > true_beam_processes
int NumberDaughters() const
Definition: MCParticle.h:217
std::vector< double > true_beam_traj_Y
std::vector< double > true_beam_Pi0_decay_startPy
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_endY
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_PFP_ID
std::map< int, std::vector< const sim::IDE * > > slice_IDEs(std::vector< const sim::IDE * > ides, double the_z0, double the_pitch, double true_endZ)
int TrackId() const
Definition: MCParticle.h:210
int Daughter(const int i) const
Definition: MCParticle.cxx:112
std::vector< std::vector< int > > true_beam_reco_byHits_PFP_ID
std::vector< double > true_beam_daughter_startPx
std::vector< const recob::Hit * > GetMCParticleHits(detinfo::DetectorClocksData const &clockData, const simb::MCParticle &mcpart, const art::Event &evt, std::string hitModule, bool use_eve=true) const
std::vector< double > true_beam_traj_Y_SCE
def process(f, kind)
Definition: search.py:254
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_allTrack_ID
std::vector< double > true_beam_daughter_startPy
const double e
double Length(size_t p=0) const
Access to various track properties.
Definition: Track.h:167
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_len
double Y(const size_type i) const
Definition: MCTrajectory.h:150
std::string EndProcess() const
Definition: MCParticle.h:216
std::vector< std::vector< int > > true_beam_reco_byHits_allTrack_ID
Ionization at a point of the TPC sensitive volume.
Definition: SimChannel.h:84
std::vector< double > true_beam_traj_Px
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_PFP_ID
std::vector< double > true_beam_elastic_deltaE
double P(const int i=0) const
Definition: MCParticle.h:234
const recob::Track * GetPFParticleTrack(const recob::PFParticle &particle, art::Event const &evt, const std::string particleLabel, const std::string trackLabel) const
Get the track associated to this particle. Returns a null pointer if not found.
float energy
energy deposited by ionization by this track ID and time [MeV]
Definition: SimChannel.h:114
std::vector< double > true_beam_traj_Pz
std::vector< double > true_beam_elastic_costheta
std::vector< std::string > true_beam_grand_daughter_endProcess
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_startZ
ValidHandle< PROD > getValidHandle(InputTag const &tag) const
Definition: DataViewImpl.h:441
std::vector< double > true_beam_daughter_endZ
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_len
std::vector< int > true_beam_Pi0_decay_nHits
std::vector< double > true_beam_Pi0_decay_startY
std::vector< double > true_beam_elastic_Y
bool sort_IDEs(const sim::IDE *i1, const sim::IDE *i2)
std::vector< int > true_beam_Pi0_decay_parID
const TLorentzVector & Position(const size_type) const
The accessor methods described above.
ProcessMap const & TrajectoryProcesses() const
Definition: MCTrajectory.h:188
cnnOutput2D GetCNNOutputFromPFParticle(const recob::PFParticle &part, const art::Event &evt, const anab::MVAReader< recob::Hit, 4 > &CNN_results, protoana::ProtoDUNEPFParticleUtils &pfpUtil, std::string fPFParticleTag)
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_allTrack_ID
std::vector< double > true_beam_daughter_endY
std::vector< double > true_beam_daughter_len
std::vector< double > true_beam_traj_KE
std::vector< int > true_beam_daughter_PDG
std::vector< int > true_beam_grand_daughter_nHits
std::vector< const sim::IDE * > GetSimIDEsBetweenPoints(const simb::MCParticle &mcpart, const TLorentzVector &p1, const TLorentzVector &p2)
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_PFP_nHits
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_startY
ROOT::Math::PositionVector3D< ROOT::Math::Cartesian3D< double >, ROOT::Math::GlobalCoordinateSystemTag > Point_t
Type for representation of position in physical 3D space.
Definition: geo_vectors.h:184
std::vector< double > true_beam_daughter_endX
std::vector< int > true_beam_daughter_nHits
std::vector< int > true_beam_Pi0_decay_PDG
int ID() const
Definition: Track.h:198
protoana::ProtoDUNETruthUtils truthUtil
std::vector< int > true_beam_daughter_ID
std::vector< double > true_beam_daughter_startZ
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_endZ
std::vector< double > true_beam_daughter_startX
std::vector< double > true_beam_traj_Py
Hierarchical representation of particle flow.
Definition: PFParticle.h:44
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_startZ
std::vector< double > true_beam_traj_Z
std::vector< double > true_beam_Pi0_decay_startPz
size_type size() const
Definition: MCTrajectory.h:166
std::vector< int > true_beam_grand_daughter_PDG
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_PFP_nHits
protoana::ProtoDUNEPFParticleUtils pfpUtil
Point_t const & End() const
Returns the position of the last valid point of the trajectory [cm].
double Pz(const int i=0) const
Definition: MCParticle.h:232
std::vector< int > true_beam_grand_daughter_ID
const std::vector< art::Ptr< recob::Hit > > GetPFParticleHits_Ptrs(const recob::PFParticle &particle, art::Event const &evt, const std::string particleLabel) const
std::vector< double > true_beam_Pi0_decay_startX
std::vector< double > true_beam_Pi0_decay_startP
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_len
std::vector< std::vector< int > > true_beam_Pi0_decay_reco_byHits_allShower_ID
double Px(const size_type i) const
Definition: MCTrajectory.h:153
std::vector< double > true_beam_elastic_Z
std::vector< double > true_beam_traj_X
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allShower_startY
#define MF_LOG_WARNING(category)
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_endZ
double EndX() const
Definition: MCParticle.h:226
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_endY
Point_t const & Start() const
Returns the position of the first valid point of the trajectory [cm].
std::vector< std::vector< int > > true_beam_daughter_reco_byHits_allShower_ID
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_startX
double Py(const size_type i) const
Definition: MCTrajectory.h:154
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allTrack_len
int ID() const
Definition: Shower.h:187
std::vector< int > true_beam_grand_daughter_parID
Track from a non-cascading particle.A recob::Track consists of a recob::TrackTrajectory, plus additional members relevant for a "fitted" track:
Definition: Track.h:49
cet::coded_exception< error, detail::translate > exception
Definition: exception.h:33
QTextStream & endl(QTextStream &s)
std::vector< std::vector< double > > true_beam_Pi0_decay_reco_byHits_allShower_startY
std::vector< std::vector< double > > true_beam_daughter_reco_byHits_allTrack_startY
std::vector< double > true_beam_elastic_X

Member Data Documentation

protoana::ProtoDUNEBeamCuts pduneana::PDSPAnalyzer::beam_cuts
private

Definition at line 774 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::beam_inst_C0
private

Definition at line 633 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::beam_inst_C0_pressure
private

Definition at line 634 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::beam_inst_C1
private

Definition at line 633 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::beam_inst_C1_pressure
private

Definition at line 634 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::beam_inst_dirX
private

Definition at line 630 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::beam_inst_dirY
private

Definition at line 630 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::beam_inst_dirZ
private

Definition at line 630 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::beam_inst_nFibersP1
private

Definition at line 631 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::beam_inst_nFibersP2
private

Definition at line 631 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::beam_inst_nFibersP3
private

Definition at line 631 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::beam_inst_nMomenta
private

Definition at line 632 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::beam_inst_nTracks
private

Definition at line 632 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::beam_inst_P
private

Definition at line 624 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::beam_inst_PDG_candidates
private

Definition at line 628 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::beam_inst_TOF
private

Definition at line 627 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::beam_inst_TOF_Chan
private

Definition at line 628 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::beam_inst_trigger
private

Definition at line 626 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::beam_inst_valid
private

Definition at line 625 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::beam_inst_X
private

Definition at line 629 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::beam_inst_Y
private

Definition at line 629 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::beam_inst_Z
private

Definition at line 629 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::beam_particle_scores
private

Definition at line 506 of file PDSPAnalyzer_module.cc.

std::vector<int> pduneana::PDSPAnalyzer::beam_track_IDs
private

Definition at line 505 of file PDSPAnalyzer_module.cc.

fhicl::ParameterSet pduneana::PDSPAnalyzer::BeamCuts
private

Definition at line 773 of file PDSPAnalyzer_module.cc.

fhicl::ParameterSet pduneana::PDSPAnalyzer::BeamPars
private

Definition at line 772 of file PDSPAnalyzer_module.cc.

art::ServiceHandle<cheat::BackTrackerService> pduneana::PDSPAnalyzer::bt_serv
private

Definition at line 775 of file PDSPAnalyzer_module.cc.

protoana::ProtoDUNECalibration pduneana::PDSPAnalyzer::calibration_NoSCE
private

Definition at line 783 of file PDSPAnalyzer_module.cc.

protoana::ProtoDUNECalibration pduneana::PDSPAnalyzer::calibration_SCE
private

Definition at line 782 of file PDSPAnalyzer_module.cc.

TFile* pduneana::PDSPAnalyzer::dEdX_template_file
private

Definition at line 770 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::dEdX_template_name
private

Definition at line 769 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::em_energy
private

Definition at line 588 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::event
private

Definition at line 359 of file PDSPAnalyzer_module.cc.

G4MultiReweighter * pduneana::PDSPAnalyzer::FakeDataMultiRW
private

Definition at line 804 of file PDSPAnalyzer_module.cc.

G4ReweightParameterMaker pduneana::PDSPAnalyzer::FakeDataParameterMaker
private

Definition at line 803 of file PDSPAnalyzer_module.cc.

std::vector<fhicl::ParameterSet> pduneana::PDSPAnalyzer::FakeDataParSet
private

Definition at line 800 of file PDSPAnalyzer_module.cc.

protoana::ProtoDUNEBeamlineUtils pduneana::PDSPAnalyzer::fBeamlineUtils
private

Definition at line 766 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::fBeamModuleLabel
private

Definition at line 765 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::fBeamPIDMomentum
private

Definition at line 768 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::fCalorimetryTagNoSCE
private

Definition at line 759 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::fCalorimetryTagSCE
private

Definition at line 757 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::fCheckSlicesForBeam
private

Definition at line 792 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::fDoProtReweight
private

Definition at line 788 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::fDoReweight
private

Definition at line 787 of file PDSPAnalyzer_module.cc.

protoana::ProtoDUNEEmptyEventFinder pduneana::PDSPAnalyzer::fEmptyEventFinder
private

Definition at line 767 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::fGeneratorTag
private

Definition at line 764 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::fGetTrackMichel
private

Definition at line 789 of file PDSPAnalyzer_module.cc.

std::pair<double, double> pduneana::PDSPAnalyzer::fGridPair
private

Definition at line 802 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::fGridPoints
private

Definition at line 801 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::fHitTag
private

Definition at line 761 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::fMCHasBI
private

Definition at line 790 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::fPandora2CaloSCE
private

Definition at line 758 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::fPFParticleTag
private

Definition at line 763 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::fPitch
private

Definition at line 795 of file PDSPAnalyzer_module.cc.

TFile* pduneana::PDSPAnalyzer::FracsFile
private

Definition at line 798 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::fRecalibrate
private

Definition at line 791 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::fSaveHits
private

Definition at line 784 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::fSCE
private

Definition at line 793 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::fShowerTag
private

Definition at line 762 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::fSkipMVA
private

Definition at line 785 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::fTrackerTag
private

Definition at line 760 of file PDSPAnalyzer_module.cc.

const art::InputTag pduneana::PDSPAnalyzer::fTrackModuleLabel
private

Definition at line 353 of file PDSPAnalyzer_module.cc.

TTree* pduneana::PDSPAnalyzer::fTree
private

Definition at line 355 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::fTrueToReco
private

Definition at line 786 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::fVerbose
private

Definition at line 771 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::fZ0
private

Definition at line 795 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::g4rw_alt_primary_minus_sigma_weight
private

Definition at line 533 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::g4rw_alt_primary_plus_sigma_weight
private

Definition at line 532 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::g4rw_full_grid_coeffs
private

Definition at line 537 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::g4rw_full_grid_kplus_coeffs
private

Definition at line 550 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::g4rw_full_grid_kplus_weights
private

Definition at line 550 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::g4rw_full_grid_neutron_coeffs
private

Definition at line 548 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::g4rw_full_grid_neutron_weights
private

Definition at line 548 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::g4rw_full_grid_piminus_weights
private

Definition at line 545 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::g4rw_full_grid_piplus_coeffs
private

Definition at line 542 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::g4rw_full_grid_piplus_weights
private

Definition at line 542 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::g4rw_full_grid_piplus_weights_fake_data
private

Definition at line 544 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::g4rw_full_grid_proton_coeffs
private

Definition at line 546 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::g4rw_full_grid_proton_weights
private

Definition at line 546 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::g4rw_full_grid_weights
private

Definition at line 537 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::g4rw_full_primary_minus_sigma_weight
private

Definition at line 535 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::g4rw_full_primary_plus_sigma_weight
private

Definition at line 534 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::g4rw_primary_grid_pair_weights
private

Definition at line 540 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::g4rw_primary_grid_weights
private

Definition at line 539 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::g4rw_primary_minus_sigma_weight
private

Definition at line 529 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::g4rw_primary_plus_sigma_weight
private

Definition at line 528 of file PDSPAnalyzer_module.cc.

std::vector<std::string> pduneana::PDSPAnalyzer::g4rw_primary_var
private

Definition at line 530 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::g4rw_primary_weights
private

Definition at line 527 of file PDSPAnalyzer_module.cc.

art::ServiceHandle<geo::Geometry> pduneana::PDSPAnalyzer::geom
private

Definition at line 781 of file PDSPAnalyzer_module.cc.

G4MultiReweighter * pduneana::PDSPAnalyzer::KPlusMultiRW
private

Definition at line 804 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::MC
private

Definition at line 360 of file PDSPAnalyzer_module.cc.

G4MultiReweighter* pduneana::PDSPAnalyzer::MultiRW
private

Definition at line 804 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::n_beam_particles
private

Definition at line 504 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::n_beam_slices
private

Definition at line 504 of file PDSPAnalyzer_module.cc.

G4MultiReweighter * pduneana::PDSPAnalyzer::NeutronMultiRW
private

Definition at line 804 of file PDSPAnalyzer_module.cc.

G4ReweightParameterMaker pduneana::PDSPAnalyzer::ParMaker
private

Definition at line 803 of file PDSPAnalyzer_module.cc.

std::vector<fhicl::ParameterSet> pduneana::PDSPAnalyzer::ParSet
private

Definition at line 800 of file PDSPAnalyzer_module.cc.

protoana::ProtoDUNEPFParticleUtils pduneana::PDSPAnalyzer::pfpUtil
private

Definition at line 780 of file PDSPAnalyzer_module.cc.

art::ServiceHandle< cheat::ParticleInventoryService > pduneana::PDSPAnalyzer::pi_serv
private

Definition at line 776 of file PDSPAnalyzer_module.cc.

G4MultiReweighter * pduneana::PDSPAnalyzer::PiMinusMultiRW
private

Definition at line 804 of file PDSPAnalyzer_module.cc.

TFile* pduneana::PDSPAnalyzer::ProtFracsFile
private

Definition at line 799 of file PDSPAnalyzer_module.cc.

G4MultiReweighter * pduneana::PDSPAnalyzer::ProtMultiRW
private

Definition at line 804 of file PDSPAnalyzer_module.cc.

G4ReweightParameterMaker pduneana::PDSPAnalyzer::ProtParMaker
private

Definition at line 803 of file PDSPAnalyzer_module.cc.

std::vector<fhicl::ParameterSet> pduneana::PDSPAnalyzer::ProtParSet
private

Definition at line 800 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::reco_beam_allTrack_beam_cuts
private

Definition at line 610 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_beam_allTrack_calibrated_dEdX
private

Definition at line 617 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_allTrack_Chi2_ndof
private

Definition at line 619 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_Chi2_proton
private

Definition at line 618 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_endX
private

Definition at line 613 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_endY
private

Definition at line 613 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_endZ
private

Definition at line 613 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::reco_beam_allTrack_flipped
private

Definition at line 610 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_allTrack_ID
private

Definition at line 609 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_len
private

Definition at line 611 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_beam_allTrack_resRange
private

Definition at line 616 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_startX
private

Definition at line 612 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_startY
private

Definition at line 612 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_startZ
private

Definition at line 612 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_trackDirX
private

Definition at line 614 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_trackDirY
private

Definition at line 614 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_trackDirZ
private

Definition at line 614 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_trackEndDirX
private

Definition at line 615 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_trackEndDirY
private

Definition at line 615 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_allTrack_trackEndDirZ
private

Definition at line 615 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_alt_len
private

Definition at line 468 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_alt_len_allTrack
private

Definition at line 469 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calibrated_dEdX_NoSCE
private

Definition at line 496 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calibrated_dEdX_SCE
private

Definition at line 493 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calibrated_dQdX_SCE
private

Definition at line 493 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_endDirX
private

Definition at line 484 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_endDirY
private

Definition at line 485 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_endDirZ
private

Definition at line 486 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_calo_endX
private

Definition at line 479 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_calo_endX_allTrack
private

Definition at line 481 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_calo_endY
private

Definition at line 479 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_calo_endY_allTrack
private

Definition at line 481 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_calo_endZ
private

Definition at line 479 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_calo_endZ_allTrack
private

Definition at line 481 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_startDirX
private

Definition at line 484 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_startDirY
private

Definition at line 485 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_startDirZ
private

Definition at line 486 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_calo_startX
private

Definition at line 478 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_calo_startX_allTrack
private

Definition at line 480 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_calo_startY
private

Definition at line 478 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_calo_startY_allTrack
private

Definition at line 480 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_calo_startZ
private

Definition at line 478 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_calo_startZ_allTrack
private

Definition at line 480 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_tick
private

Definition at line 498 of file PDSPAnalyzer_module.cc.

std::vector<int> pduneana::PDSPAnalyzer::reco_beam_calo_TPC
private

Definition at line 501 of file PDSPAnalyzer_module.cc.

std::vector<int> pduneana::PDSPAnalyzer::reco_beam_calo_TPC_NoSCE
private

Definition at line 501 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_wire
private

Definition at line 498 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_wire_allTrack
private

Definition at line 499 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_wire_NoSCE
private

Definition at line 500 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_wire_z
private

Definition at line 498 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_wire_z_NoSCE
private

Definition at line 500 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_X
private

Definition at line 482 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_X_allTrack
private

Definition at line 483 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_Y
private

Definition at line 482 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_Y_allTrack
private

Definition at line 483 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_Z
private

Definition at line 482 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_calo_Z_allTrack
private

Definition at line 483 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_Chi2_ndof
private

Definition at line 514 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_Chi2_proton
private

Definition at line 513 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_dEdX_NoSCE
private

Definition at line 495 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_dEdX_SCE
private

Definition at line 491 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_dQ
private

Definition at line 493 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_dQ_NoSCE
private

Definition at line 500 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_dQdX_NoSCE
private

Definition at line 495 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_dQdX_SCE
private

Definition at line 491 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_EField_SCE
private

Definition at line 491 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_endX
private

Definition at line 466 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_endY
private

Definition at line 466 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_endZ
private

Definition at line 466 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::reco_beam_flipped
private

Definition at line 507 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_beam_incidentEnergies
private

Definition at line 580 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_beam_incidentEnergies_allTrack
private

Definition at line 582 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_interactingEnergy
private

Definition at line 581 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_interactingEnergy_allTrack
private

Definition at line 583 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_len
private

Definition at line 468 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_momByRange_alt_muon
private

Definition at line 743 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_momByRange_alt_proton
private

Definition at line 742 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_momByRange_muon
private

Definition at line 738 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_momByRange_proton
private

Definition at line 737 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::reco_beam_passes_beam_cuts
private

Definition at line 510 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_PFP_emScore
private

Definition at line 603 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_PFP_emScore_collection
private

Definition at line 606 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_PFP_emScore_collection_weight_by_charge
private

Definition at line 606 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_PFP_emScore_weight_by_charge
private

Definition at line 603 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_PFP_ID
private

Definition at line 600 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_PFP_michelScore
private

Definition at line 604 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_PFP_michelScore_collection
private

Definition at line 607 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_PFP_michelScore_collection_weight_by_charge
private

Definition at line 607 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_PFP_michelScore_weight_by_charge
private

Definition at line 604 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_PFP_nHits
private

Definition at line 601 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_PFP_trackScore
private

Definition at line 602 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_PFP_trackScore_collection
private

Definition at line 605 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_PFP_trackScore_collection_weight_by_charge
private

Definition at line 605 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_PFP_trackScore_weight_by_charge
private

Definition at line 602 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_resRange_NoSCE
private

Definition at line 495 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_resRange_SCE
private

Definition at line 491 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_beam_spacePts_X
private

Definition at line 746 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_beam_spacePts_Y
private

Definition at line 746 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_beam_spacePts_Z
private

Definition at line 746 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_startX
private

Definition at line 465 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_startY
private

Definition at line 465 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_startZ
private

Definition at line 465 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_trackDirX
private

Definition at line 488 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_trackDirY
private

Definition at line 488 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_trackDirZ
private

Definition at line 488 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_trackEndDirX
private

Definition at line 489 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_trackEndDirY
private

Definition at line 489 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_trackEndDirZ
private

Definition at line 489 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_trackID
private

Definition at line 503 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_TrkPitch_NoSCE
private

Definition at line 495 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_TrkPitch_SCE
private

Definition at line 491 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_beam_TrkPitch_SCE_allTrack
private

Definition at line 492 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byE_endE
private

Definition at line 568 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byE_endP
private

Definition at line 569 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::reco_beam_true_byE_endProcess
private

Definition at line 555 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byE_endPx
private

Definition at line 565 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byE_endPy
private

Definition at line 566 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byE_endPz
private

Definition at line 567 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_true_byE_ID
private

Definition at line 558 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::reco_beam_true_byE_matched
private

Definition at line 559 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_true_byE_origin
private

Definition at line 562 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_true_byE_PDG
private

Definition at line 557 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::reco_beam_true_byE_process
private

Definition at line 556 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byE_startE
private

Definition at line 574 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byE_startP
private

Definition at line 575 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byE_startPx
private

Definition at line 571 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byE_startPy
private

Definition at line 572 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byE_startPz
private

Definition at line 573 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byHits_endE
private

Definition at line 568 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byHits_endP
private

Definition at line 569 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::reco_beam_true_byHits_endProcess
private

Definition at line 555 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byHits_endPx
private

Definition at line 565 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byHits_endPy
private

Definition at line 566 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byHits_endPz
private

Definition at line 567 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_true_byHits_ID
private

Definition at line 558 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::reco_beam_true_byHits_matched
private

Definition at line 559 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_true_byHits_origin
private

Definition at line 562 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_true_byHits_PDG
private

Definition at line 557 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::reco_beam_true_byHits_process
private

Definition at line 556 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byHits_purity
private

Definition at line 577 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byHits_startE
private

Definition at line 574 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byHits_startP
private

Definition at line 575 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byHits_startPx
private

Definition at line 571 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byHits_startPy
private

Definition at line 572 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_true_byHits_startPz
private

Definition at line 573 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_type
private

Definition at line 512 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_vertex_michel_score
private

Definition at line 470 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_vertex_michel_score_allTrack
private

Definition at line 472 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_vertex_michel_score_weight_by_charge
private

Definition at line 474 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::reco_beam_vertex_michel_score_weight_by_charge_allTrack
private

Definition at line 475 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_vertex_nHits
private

Definition at line 471 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_vertex_nHits_allTrack
private

Definition at line 473 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::reco_beam_vertex_slice
private

Definition at line 459 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allShower_dirX
private

Definition at line 725 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allShower_dirY
private

Definition at line 725 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allShower_dirZ
private

Definition at line 725 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allShower_energy
private

Definition at line 725 of file PDSPAnalyzer_module.cc.

std::vector<int> pduneana::PDSPAnalyzer::reco_daughter_allShower_ID
private

Definition at line 724 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allShower_len
private

Definition at line 725 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allShower_startX
private

Definition at line 725 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allShower_startY
private

Definition at line 725 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allShower_startZ
private

Definition at line 725 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_allTrack_alt_len
private

Definition at line 718 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_allTrack_calibrated_dEdX_SCE
private

Definition at line 695 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::reco_daughter_allTrack_calibrated_dEdX_SCE_plane0
private

Definition at line 701 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::reco_daughter_allTrack_calibrated_dEdX_SCE_plane1
private

Definition at line 701 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_allTrack_calibrated_dQdX_SCE
private

Definition at line 695 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_allTrack_calo_X
private

Definition at line 695 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_allTrack_calo_Y
private

Definition at line 695 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_allTrack_calo_Z
private

Definition at line 695 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_allTrack_Chi2_muon
private

Definition at line 696 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::reco_daughter_allTrack_Chi2_ndof
private

Definition at line 697 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::reco_daughter_allTrack_Chi2_ndof_muon
private

Definition at line 697 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::reco_daughter_allTrack_Chi2_ndof_pion
private

Definition at line 697 of file PDSPAnalyzer_module.cc.

std::vector<int> pduneana::PDSPAnalyzer::reco_daughter_allTrack_Chi2_ndof_plane0
private

Definition at line 711 of file PDSPAnalyzer_module.cc.

std::vector<int> pduneana::PDSPAnalyzer::reco_daughter_allTrack_Chi2_ndof_plane1
private

Definition at line 711 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_allTrack_Chi2_pion
private

Definition at line 696 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_allTrack_Chi2_proton
private

Definition at line 696 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allTrack_Chi2_proton_plane0
private

Definition at line 708 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allTrack_Chi2_proton_plane1
private

Definition at line 708 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_allTrack_dEdX_SCE
private

Definition at line 694 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_allTrack_dQdX_SCE
private

Definition at line 694 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_allTrack_EField_SCE
private

Definition at line 695 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_allTrack_endX
private

Definition at line 715 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_allTrack_endY
private

Definition at line 716 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_allTrack_endZ
private

Definition at line 717 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::reco_daughter_allTrack_ID
private

Definition at line 691 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_allTrack_len
private

Definition at line 718 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allTrack_momByRange_alt_muon
private

Definition at line 741 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allTrack_momByRange_alt_proton
private

Definition at line 740 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allTrack_momByRange_muon
private

Definition at line 736 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allTrack_momByRange_proton
private

Definition at line 735 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_allTrack_Phi
private

Definition at line 693 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::reco_daughter_allTrack_resRange_plane0
private

Definition at line 705 of file PDSPAnalyzer_module.cc.

std::vector<std::vector<double> > pduneana::PDSPAnalyzer::reco_daughter_allTrack_resRange_plane1
private

Definition at line 705 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_allTrack_resRange_SCE
private

Definition at line 694 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_allTrack_startX
private

Definition at line 715 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_allTrack_startY
private

Definition at line 716 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_allTrack_startZ
private

Definition at line 717 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_allTrack_Theta
private

Definition at line 692 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_daughter_allTrack_vertex_michel_score
private

Definition at line 720 of file PDSPAnalyzer_module.cc.

std::vector<int> pduneana::PDSPAnalyzer::reco_daughter_allTrack_vertex_nHits
private

Definition at line 721 of file PDSPAnalyzer_module.cc.

std::vector<int> pduneana::PDSPAnalyzer::reco_daughter_pandora_type
private

Definition at line 642 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_emScore
private

Definition at line 646 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_emScore_collection
private

Definition at line 649 of file PDSPAnalyzer_module.cc.

std::vector<int> pduneana::PDSPAnalyzer::reco_daughter_PFP_ID
private

Definition at line 641 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_michelScore
private

Definition at line 647 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_michelScore_collection
private

Definition at line 650 of file PDSPAnalyzer_module.cc.

std::vector<int> pduneana::PDSPAnalyzer::reco_daughter_PFP_nHits
private

Definition at line 643 of file PDSPAnalyzer_module.cc.

std::vector<int> pduneana::PDSPAnalyzer::reco_daughter_PFP_nHits_collection
private

Definition at line 643 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_trackScore
private

Definition at line 645 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_trackScore_collection
private

Definition at line 648 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byE_completeness
private

Definition at line 683 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byE_len
private

Definition at line 682 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byE_PDG
private

Definition at line 681 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byE_purity
private

Definition at line 684 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_completeness
private

Definition at line 663 of file PDSPAnalyzer_module.cc.

std::vector< size_t > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_emHits
private

Definition at line 662 of file PDSPAnalyzer_module.cc.

std::vector< std::string > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_endProcess
private

Definition at line 679 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_endX
private

Definition at line 669 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_endY
private

Definition at line 670 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_endZ
private

Definition at line 671 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_ID
private

Definition at line 656 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_len
private

Definition at line 665 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_origin
private

Definition at line 657 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_parID
private

Definition at line 658 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_parPDG
private

Definition at line 659 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_PDG
private

Definition at line 655 of file PDSPAnalyzer_module.cc.

std::vector< std::string > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_process
private

Definition at line 660 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_purity
private

Definition at line 661 of file PDSPAnalyzer_module.cc.

std::vector< size_t > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_sharedHits
private

EDIT: quality.

Definition at line 662 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_startE
private

Definition at line 676 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_startP
private

Definition at line 677 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_startPx
private

Definition at line 673 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_startPy
private

Definition at line 674 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_startPz
private

Definition at line 675 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_startX
private

Definition at line 666 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_startY
private

Definition at line 667 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::reco_daughter_PFP_true_byHits_startZ
private

Definition at line 668 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_shower_spacePts_X
private

Definition at line 748 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_shower_spacePts_Y
private

Definition at line 748 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_shower_spacePts_Z
private

Definition at line 748 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_spacePts_X
private

Definition at line 747 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_spacePts_Y
private

Definition at line 747 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::reco_daughter_spacePts_Z
private

Definition at line 747 of file PDSPAnalyzer_module.cc.

bool pduneana::PDSPAnalyzer::reco_reconstructable_beam_event
private

Definition at line 637 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_track_endX
private

Definition at line 519 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_track_endY
private

Definition at line 519 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_track_endZ
private

Definition at line 519 of file PDSPAnalyzer_module.cc.

std::vector<int> pduneana::PDSPAnalyzer::reco_track_ID
private

Definition at line 522 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_track_michel_score
private

Definition at line 519 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_track_michel_score_weight_by_charge
private

Definition at line 519 of file PDSPAnalyzer_module.cc.

std::vector<int> pduneana::PDSPAnalyzer::reco_track_nHits
private

Definition at line 522 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_track_startX
private

Definition at line 519 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_track_startY
private

Definition at line 519 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::reco_track_startZ
private

Definition at line 519 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::run
private

Definition at line 357 of file PDSPAnalyzer_module.cc.

G4ReweightManager* pduneana::PDSPAnalyzer::RWManager
private

Definition at line 806 of file PDSPAnalyzer_module.cc.

protoana::ProtoDUNEShowerUtils pduneana::PDSPAnalyzer::showerUtil
private

Definition at line 778 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::subrun
private

Definition at line 358 of file PDSPAnalyzer_module.cc.

std::map< int, TProfile* > pduneana::PDSPAnalyzer::templates
private

Definition at line 754 of file PDSPAnalyzer_module.cc.

protoana::ProtoDUNETrackUtils pduneana::PDSPAnalyzer::trackUtil
private

Definition at line 777 of file PDSPAnalyzer_module.cc.

std::vector< std::string > pduneana::PDSPAnalyzer::true_beam_daughter_endProcess
private

Definition at line 413 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_daughter_endX
private

Definition at line 417 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_daughter_endY
private

Definition at line 417 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_daughter_endZ
private

Definition at line 417 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::true_beam_daughter_ID
private

Definition at line 411 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_daughter_len
private

Definition at line 412 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::true_beam_daughter_nHits
private

Definition at line 418 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::true_beam_daughter_PDG
private

Definition at line 410 of file PDSPAnalyzer_module.cc.

std::vector< std::string > pduneana::PDSPAnalyzer::true_beam_daughter_Process
private

Definition at line 413 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< int > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_allShower_ID
private

Definition at line 422 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_allShower_len
private

Definition at line 429 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_allShower_startX
private

Definition at line 428 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_allShower_startY
private

Definition at line 428 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_allShower_startZ
private

Definition at line 428 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_allTrack_endX
private

Definition at line 426 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_allTrack_endY
private

Definition at line 426 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_allTrack_endZ
private

Definition at line 426 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< int > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_allTrack_ID
private

Definition at line 422 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_allTrack_len
private

Definition at line 427 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_allTrack_startX
private

Definition at line 425 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_allTrack_startY
private

Definition at line 425 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_allTrack_startZ
private

Definition at line 425 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< int > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_PFP_ID
private

Definition at line 422 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< int > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_PFP_nHits
private

Definition at line 422 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_daughter_reco_byHits_PFP_trackScore
private

Definition at line 424 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_daughter_startP
private

Definition at line 416 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_daughter_startPx
private

Definition at line 416 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_daughter_startPy
private

Definition at line 416 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_daughter_startPz
private

Definition at line 416 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_daughter_startX
private

Definition at line 415 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_daughter_startY
private

Definition at line 415 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_daughter_startZ
private

Definition at line 415 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_elastic_costheta
private

Definition at line 395 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_elastic_deltaE
private

Definition at line 395 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_elastic_IDE_edep
private

Definition at line 395 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_elastic_X
private

Definition at line 395 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_elastic_Y
private

Definition at line 395 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_elastic_Z
private

Definition at line 395 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_endP
private

Definition at line 391 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_endP2
private

Definition at line 391 of file PDSPAnalyzer_module.cc.

std::string pduneana::PDSPAnalyzer::true_beam_endProcess
private

Definition at line 368 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_endPx
private

Definition at line 388 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_endPy
private

Definition at line 389 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_endPz
private

Definition at line 390 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_endX
private

Definition at line 369 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_endX_SCE
private

Definition at line 372 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_endY
private

Definition at line 370 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_endY_SCE
private

Definition at line 373 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_endZ
private

Definition at line 371 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_endZ_SCE
private

Definition at line 374 of file PDSPAnalyzer_module.cc.

std::vector< std::string > pduneana::PDSPAnalyzer::true_beam_grand_daughter_endProcess
private

Definition at line 451 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::true_beam_grand_daughter_ID
private

Definition at line 449 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::true_beam_grand_daughter_nHits
private

Definition at line 450 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::true_beam_grand_daughter_parID
private

Definition at line 449 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::true_beam_grand_daughter_PDG
private

Definition at line 449 of file PDSPAnalyzer_module.cc.

std::vector< std::string > pduneana::PDSPAnalyzer::true_beam_grand_daughter_Process
private

Definition at line 451 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::true_beam_ID
private

Definition at line 367 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_IDE_totalDep
private

Definition at line 399 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_incidentEnergies
private

Definition at line 584 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_interactingEnergy
private

Definition at line 587 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_last_len
private

Definition at line 391 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_len
private

Definition at line 467 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_mass
private

Definition at line 366 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::true_beam_nElasticScatters
private

Definition at line 393 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::true_beam_nHits
private

Definition at line 394 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::true_beam_PDG
private

Definition at line 365 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_ID
private

Definition at line 434 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_len
private

Definition at line 447 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_nHits
private

Definition at line 437 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_parID
private

Definition at line 434 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_PDG
private

Definition at line 434 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< int > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_allShower_ID
private

Definition at line 438 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_allShower_len
private

Definition at line 445 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_allShower_startX
private

Definition at line 444 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_allShower_startY
private

Definition at line 444 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_allShower_startZ
private

Definition at line 444 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_allTrack_endX
private

Definition at line 442 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_allTrack_endY
private

Definition at line 442 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_allTrack_endZ
private

Definition at line 442 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< int > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_allTrack_ID
private

Definition at line 438 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_allTrack_len
private

Definition at line 443 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_allTrack_startX
private

Definition at line 441 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_allTrack_startY
private

Definition at line 441 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_allTrack_startZ
private

Definition at line 441 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< int > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_PFP_ID
private

Definition at line 438 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< int > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_PFP_nHits
private

Definition at line 438 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< double > > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_reco_byHits_PFP_trackScore
private

Definition at line 440 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_startP
private

Definition at line 435 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_startPx
private

Definition at line 435 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_startPy
private

Definition at line 435 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_startPz
private

Definition at line 435 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_startX
private

Definition at line 436 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_startY
private

Definition at line 436 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_Pi0_decay_startZ
private

Definition at line 436 of file PDSPAnalyzer_module.cc.

std::vector< std::string > pduneana::PDSPAnalyzer::true_beam_processes
private

Definition at line 400 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< int > > pduneana::PDSPAnalyzer::true_beam_reco_byHits_allTrack_ID
private

Definition at line 403 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< int > > pduneana::PDSPAnalyzer::true_beam_reco_byHits_PFP_ID
private

Definition at line 403 of file PDSPAnalyzer_module.cc.

std::vector< std::vector< int > > pduneana::PDSPAnalyzer::true_beam_reco_byHits_PFP_nHits
private

Definition at line 403 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::true_beam_slices
private

Definition at line 585 of file PDSPAnalyzer_module.cc.

std::vector< double > pduneana::PDSPAnalyzer::true_beam_slices_deltaE
private

Definition at line 586 of file PDSPAnalyzer_module.cc.

std::vector< int > pduneana::PDSPAnalyzer::true_beam_slices_found
private

Definition at line 585 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_startDirX
private

Definition at line 379 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_startDirY
private

Definition at line 380 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_startDirZ
private

Definition at line 381 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_startP
private

Definition at line 386 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_startPx
private

Definition at line 383 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_startPy
private

Definition at line 384 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_startPz
private

Definition at line 385 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_startX
private

Definition at line 375 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_startY
private

Definition at line 376 of file PDSPAnalyzer_module.cc.

double pduneana::PDSPAnalyzer::true_beam_startZ
private

Definition at line 377 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::true_beam_traj_KE
private

Definition at line 595 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::true_beam_traj_Px
private

Definition at line 592 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::true_beam_traj_Py
private

Definition at line 593 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::true_beam_traj_Pz
private

Definition at line 594 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::true_beam_traj_X
private

Definition at line 589 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::true_beam_traj_X_SCE
private

Definition at line 596 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::true_beam_traj_Y
private

Definition at line 590 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::true_beam_traj_Y_SCE
private

Definition at line 597 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::true_beam_traj_Z
private

Definition at line 591 of file PDSPAnalyzer_module.cc.

std::vector<double> pduneana::PDSPAnalyzer::true_beam_traj_Z_SCE
private

Definition at line 598 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::true_daughter_nNeutron
private

Definition at line 455 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::true_daughter_nNucleus
private

Definition at line 455 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::true_daughter_nPi0
private

Definition at line 454 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::true_daughter_nPiMinus
private

Definition at line 454 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::true_daughter_nPiPlus
private

Definition at line 454 of file PDSPAnalyzer_module.cc.

int pduneana::PDSPAnalyzer::true_daughter_nProton
private

Definition at line 455 of file PDSPAnalyzer_module.cc.

protoana::ProtoDUNETruthUtils pduneana::PDSPAnalyzer::truthUtil
private

Definition at line 779 of file PDSPAnalyzer_module.cc.


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