LArSoft  v06_85_00
Liquid Argon Software toolkit - http://larsoft.org/
EventWritingAlgorithm.h
Go to the documentation of this file.
1 
8 #ifndef LAR_EVENT_WRITING_ALGORITHM_H
9 #define LAR_EVENT_WRITING_ALGORITHM_H 1
10 
11 #include "Pandora/Algorithm.h"
12 
13 #include "Persistency/PandoraIO.h"
14 
15 namespace pandora {class FileWriter;}
16 
17 //------------------------------------------------------------------------------------------------------------------------------------------
18 
19 namespace lar_content
20 {
21 
25 class EventWritingAlgorithm : public pandora::Algorithm
26 {
27 public:
32 
37 
38 private:
39  pandora::StatusCode Initialize();
40  pandora::StatusCode Run();
41 
47  bool PassNuanceCodeFilter() const;
48 
54  bool PassMCParticleFilter() const;
55 
61  bool PassNeutrinoVertexFilter() const;
62 
63  pandora::StatusCode ReadSettings(const pandora::TiXmlHandle xmlHandle);
64 
65  pandora::FileType m_geometryFileType;
66  pandora::FileType m_eventFileType;
67 
68  pandora::FileWriter *m_pEventFileWriter;
69  pandora::FileWriter *m_pGeometryFileWriter;
70 
73  std::string m_geometryFileName;
74 
76  std::string m_eventFileName;
77 
80 
83 
86 
89 
92  unsigned int m_matchingMinPrimaryHits;
93  unsigned int m_nNonNeutrons;
94  unsigned int m_nMuons;
95  unsigned int m_nElectrons;
96  unsigned int m_nProtons;
97  unsigned int m_nPhotons;
98  unsigned int m_nChargedPions;
99 
110 };
111 
112 } // namespace lar_content
113 
114 #endif // #ifndef LAR_EVENT_WRITING_ALGORITHM_H
float m_detectorHalfLengthZ
Half length of detector in z dimension.
unsigned int m_matchingMinPrimaryHits
The minimum number of mc primary hits used in matching scheme.
bool m_shouldWriteMCRelationships
Whether to write mc relationship information to the events file.
pandora::FileWriter * m_pEventFileWriter
Address of the event file writer.
EventWritingAlgorithm class.
bool m_shouldFilterByMCParticles
Whether to filter output by mc particle constituents.
bool m_shouldWriteEvents
Whether to write events to a specified file.
bool m_useLArCaloHits
Whether to write lar calo hits, or standard pandora calo hits.
float m_coordinateOffsetY
Origin offset (from detector corner) in y dimension.
void Initialize()
Definition: errprop.cc:101
bool m_neutrinoInducedOnly
Whether to consider only mc particles that were neutrino induced.
unsigned int m_nPhotons
The requested number of mc primaries that are photons.
unsigned int m_nProtons
The requested number of mc primaries that are protons.
float m_selectedBorderY
Required distance from detector edge in y dimension.
float m_detectorHalfLengthY
Half length of detector in y dimension.
float m_selectedBorderZ
Required distance from detector edge in z dimension.
std::string m_eventFileName
Name of the output event file.
pandora::FileType m_geometryFileType
The geometry file type.
unsigned int m_nChargedPions
The requested number of mc primaries that are charged pions.
bool m_shouldWriteTrackRelationships
Whether to write track relationship information to the events file.
bool m_useLArMCParticles
Whether to write lar mc particles, or standard pandora mc particles.
pandora::FileWriter * m_pGeometryFileWriter
Address of the geometry file writer.
unsigned int m_nNonNeutrons
The requested number of mc primaries that are not neutrons.
float m_selectedBorderX
Required distance from detector edge in x dimension.
bool m_shouldFilterByNeutrinoVertex
Whether to filter output by neutrino vertex position (e.g. fiducial volume cut)
int m_filterNuanceCode
The filter nuance code (required if specify filter by nuance code)
float m_detectorHalfLengthX
Half length of detector in x dimension.
unsigned int m_nElectrons
The requested number of mc primaries that are electrons.
std::string m_geometryFileName
Name of the output geometry file.
pandora::FileType m_eventFileType
The event file type.
bool m_shouldFilterByNuanceCode
Whether to filter output by nuance code.
bool m_shouldOverwriteEventFile
Whether to overwrite existing event file with specified name, or append.
unsigned int m_nMuons
The requested number of mc primaries that are muons.
bool m_shouldWriteGeometry
Whether to write geometry to a specified file.
bool m_shouldOverwriteGeometryFile
Whether to overwrite existing geometry file with specified name, or append.
float m_coordinateOffsetZ
Origin offset (from detector corner) in z dimension.
bool m_writtenGeometry
Whether geometry has been written.
float m_coordinateOffsetX
Origin offset (from detector corner) in x dimension.