5 #ifndef RawEVD35tTree_module 6 #define RawEVD35tTree_module 31 #include "art_root_io/TFileService.h" 33 #include "canvas/Persistency/Common/FindManyP.h" 41 #include "TLorentzVector.h" 58 #pragma link C++ class vector<vector<int> >+; 113 std::vector<unsigned int>
fAPA;
115 std::vector<std::vector<int> >
fADC;
116 std::vector<std::vector<int> >
fTDC;
148 auto const *fDetProp = lar::providerFrom<detinfo::DetectorPropertiesService>();
149 fNticks = fDetProp->NumberTimeSamples();
169 tRD = tfs->make<TTree>(
"RawData",
"Raw Data Display");
170 tRD->Branch(
"Run",&
fRun,
"Run/i");
178 tRD->Branch(
"NofUChan",&
fNUCh,
"NofUChan/i");
179 tRD->Branch(
"NofVChan",&
fNVCh,
"NofVChan/i");
180 tRD->Branch(
"NofZ0Chan",&
fNZ0Ch,
"NofZ0Chan/i");
181 tRD->Branch(
"NofZ1Chan",&
fNZ1Ch,
"NofZ1Chan/i");
232 fEvent =
event.id().event();
244 try { RawTPC->size(); }
246 try { RawSSP->size(); }
250 std::vector< art::Ptr<raw::RawDigit> > RawDigits;
252 std::vector< art::Ptr<raw::OpDetPulse> > RawPulses;
273 for(
size_t d = 0;
d < RawDigits.size();
d++) {
276 digit = RawDigits.at(
d);
280 int nSamples = digit->
Samples();
290 std::vector<short> uncompressed(digit->
Samples());
293 std::vector<int> tmpADC;
294 std::vector<int> tmpTDC;
295 for (
int i=0; i<nSamples; i++) {
296 short adc = uncompressed[i];
298 tmpADC.push_back(
int(adc));
299 tmpTDC.push_back(
int(i));
303 fADC.push_back(tmpADC);
304 fTDC.push_back(tmpTDC);
305 fChan.push_back(chan);
316 for(
size_t p = 0;
p < RawPulses.size();
p++) {
319 pulsePtr = RawPulses.at(
p);
322 unsigned short opchan = pulse.
OpChannel();
323 unsigned short nsamples = pulse.
Samples();
324 std::vector<short> waveform = pulse.
Waveform();
325 unsigned int PMTFrame = pulse.
PMTFrame();
327 std::vector<int> tmpWaveform;
328 for (
int i=0; i<nsamples; i++) {
329 short adc = waveform[i];
330 tmpWaveform.push_back(
int(adc));
345 #endif // RawEVD35tTree_module
Store parameters for running LArG4.
const ADCvector_t & ADCs() const
Reference to the compressed ADC count vector.
std::vector< int > fPMTFrame
ULong64_t Samples() const
Number of samples in the uncompressed ADC data.
std::vector< std::vector< int > > fWaveform
RawEVD35tTree(fhicl::ParameterSet const &pset)
std::vector< unsigned int > fPlane
Declaration of signal hit object.
unsigned short OpChannel() const
ChannelID_t Channel() const
DAQ channel this raw data was read from.
std::vector< geo::WireID > ChannelToWire(raw::ChannelID_t const channel) const
Returns a list of wires connected to the specified TPC channel.
Definition of basic raw digits.
Planes which measure Z direction.
EDAnalyzer(fhicl::ParameterSet const &pset)
unsigned int Ncryostats() const
Returns the number of cryostats in the detector.
const std::vector< short > & Waveform() const
unsigned int Nchannels() const
Returns the number of TPC readout channels in the detector.
void reconfigure(fhicl::ParameterSet const &pset)
unsigned short Samples() const
std::string fRawDigitLabel
#define DEFINE_ART_MODULE(klass)
Collect all the RawData header files together.
T get(std::string const &key) const
void analyzeRCE(const std::vector< art::Ptr< raw::RawDigit > > RawDigits)
unsigned int fChansPerAPA
Declaration of cluster object.
View_t View(geo::PlaneID const &pid) const
Returns the view (wire orientation) on the channels of specified TPC plane.
Definition of data types for geometry description.
unsigned int NTPC(unsigned int cstat=0) const
Returns the total number of TPCs in the specified cryostat.
raw::Compress_t Compression() const
Compression algorithm used to store the ADC counts.
std::vector< std::vector< int > > fADC
void analyzeSSP(const std::vector< art::Ptr< raw::OpDetPulse > > RawPulses)
object containing MC truth information necessary for making RawDigits and doing back tracking ...
void analyze(const art::Event &evt)
std::vector< unsigned int > fChan
std::vector< std::vector< int > > fTDC
std::vector< unsigned int > fAPA
std::vector< int > fOpChannel
void fill_ptr_vector(std::vector< Ptr< T >> &ptrs, H const &h)
void Uncompress(const std::vector< short > &adc, std::vector< short > &uncompressed, raw::Compress_t compress)
Uncompresses a raw data buffer.
recob::tracking::Plane Plane
art::ServiceHandle< geo::Geometry > fGeom
unsigned int PMTFrame() const
cet::coded_exception< error, detail::translate > exception
Event finding and building.
void beginRun(const art::Run &run)