LArSoft  v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
FeatureVertexFinderAna_module.cc
Go to the documentation of this file.
1 //
3 // FeatureVertexFinder designed to analyze 2d & 3d verticies found in the TPC
4 //
5 // jaasaadi@syr.edu
6 //
7 // Note: This ana module will utilize MC truth information for verticies and is not (yet)
8 // intended as a unit test for data...though many of the same methods will likely be used
9 // for real data (when the time comes)
11 
12 // LArSoft
19 
20 // C++
21 #include <string>
22 
23 // Framework
29 #include "art_root_io/TFileService.h"
32 #include "fhiclcpp/ParameterSet.h"
34 
35 // ROOT
36 #include "TH1F.h"
37 #include "TH2D.h"
38 
39 namespace vertex {
40 
42  public:
43  explicit FeatureVertexFinderAna(fhicl::ParameterSet const& pset);
44 
45  private:
46  void analyze(const art::Event& evt) override;
47  void beginJob() override;
48 
49  std::string fLArG4ModuleLabel;
50  std::string fGenieModuleLabel;
51  std::string fVertexModuleLabel;
52  std::string fEndPoint2dModuleLabel; //<---2d Vertex Module Label (EndPoint2d)
53 
54  // Outputting histograms for analysis
55 
56  TH1F* fRun;
57  TH1F* fEvt;
73 
77 
90 
94 
99 
104 
109 
110  TH1F* fRecoVtxN3d;
114 
118 
122 
123  }; // End class VertexFinderAna
124 
126  {
127  fLArG4ModuleLabel = pset.get<std::string>("LArGeantModuleLabel");
128  fGenieModuleLabel = pset.get<std::string>("GenieModuleLabel");
129  fVertexModuleLabel = pset.get<std::string>("VertexModuleLabel");
130  fEndPoint2dModuleLabel = pset.get<std::string>("EndPoint2dModuleLabel");
131  }
132 
134  {
135  // get access to the TFile service
137 
138  // Outputting TH1F Histograms
139  fRun = tfs->make<TH1F>("fRun", "Run Number", 1000, 0, 1000);
140  fEvt = tfs->make<TH1F>("fEvt", "Event Number", 1000, 0, 1000);
141  fTruthVtxXPos = tfs->make<TH1F>("fTruthVtxXPos", "Truth Vertex X Position", 400, 0, 200);
142  fTruthVtxYPos = tfs->make<TH1F>("fTruthVtxYPos", "Truth Vertex Y Position", 400, -100, 100);
143  fTruthVtxZPos = tfs->make<TH1F>("fTruthVtxZPos", "Truth Vertex Z Position", 2000, 0, 1000);
145  tfs->make<TH1F>("fTruthWireNumberPlane0", "Truth Wire Number Plane 0", 3000, 0, 3000);
147  tfs->make<TH1F>("fTruthTimeTickPlane0", "Truth Time Tick Plane 0", 3200, 0, 3200);
149  tfs->make<TH1F>("fTruthWireNumberPlane1", "Truth Wire Number Plane 1", 3000, 0, 3000);
151  tfs->make<TH1F>("fTruthTimeTickPlane1", "Truth Time Tick Plane 1", 3200, 0, 3200);
153  tfs->make<TH1F>("fTruthWireNumberPlane2", "Truth Wire Number Plane 2", 3000, 0, 3000);
155  tfs->make<TH1F>("fTruthTimeTickPlane2", "Truth Time Tick Plane 2", 3200, 0, 3200);
157  tfs->make<TH1F>("fTruthWireInCmPlane0", "Truth Wire In CM Plane 0", 2000, 0, 1000);
159  tfs->make<TH1F>("fTruthTimeInCmPlane0", "Truth Time In Cm Plane 0", 2000, 0, 1000);
161  tfs->make<TH1F>("fTruthWireInCmPlane1", "Truth Wire In CM Plane 1", 2000, 0, 1000);
163  tfs->make<TH1F>("fTruthTimeInCmPlane1", "Truth Time In Cm Plane 1", 2000, 0, 1000);
165  tfs->make<TH1F>("fTruthWireInCmPlane2", "Truth Wire In CM Plane 2", 2000, 0, 1000);
167  tfs->make<TH1F>("fTruthTimeInCmPlane2", "Truth Time In Cm Plane 2", 2000, 0, 1000);
168 
170  tfs->make<TH1F>("fTwoDNVtxPlane0", "TwoD Number of Verticies Found in Plane 0", 400, 0, 200);
172  tfs->make<TH1F>("fTwoDNVtxPlane1", "TwoD Number of Verticies Found in Plane 1", 400, 0, 200);
174  tfs->make<TH1F>("fTwoDNVtxPlane2", "TwoD Number of Verticies Found in Plane 2", 400, 0, 200);
175 
177  tfs->make<TH1F>("fTwoDWireNumberPlane0", "TwoD Wire Number Plane 0", 3000, 0, 3000);
179  tfs->make<TH1F>("fTwoDTimeTickPlane0", "TwoD Time Tick Plane 0", 3200, 0, 3200);
181  tfs->make<TH1F>("fTwoDWireNumberPlane1", "TwoD Wire Number Plane 1", 3000, 0, 3000);
183  tfs->make<TH1F>("fTwoDTimeTickPlane1", "TwoD Time Tick Plane 1", 3200, 0, 3200);
185  tfs->make<TH1F>("fTwoDWireNumberPlane2", "TwoD Wire Number Plane 2", 3000, 0, 3000);
187  tfs->make<TH1F>("fTwoDTimeTickPlane2", "TwoD Time Tick Plane 2", 3200, 0, 3200);
189  tfs->make<TH1F>("fTwoDWireInCmPlane0", "TwoD Wire In CM Plane 0", 2000, 0, 1000);
191  tfs->make<TH1F>("fTwoDTimeInCmPlane0", "TwoD Time In Cm Plane 0", 2000, 0, 1000);
193  tfs->make<TH1F>("fTwoDWireInCmPlane1", "TwoD Wire In CM Plane 1", 2000, 0, 1000);
195  tfs->make<TH1F>("fTwoDTimeInCmPlane1", "TwoD Time In Cm Plane 1", 2000, 0, 1000);
197  tfs->make<TH1F>("fTwoDWireInCmPlane2", "TwoD Wire In CM Plane 2", 2000, 0, 1000);
199  tfs->make<TH1F>("fTwoDTimeInCmPlane2", "TwoD Time In Cm Plane 2", 2000, 0, 1000);
200 
202  tfs->make<TH1F>("fTwoDStrengthPlane0", "TwoD Strength Plane 0", 1000, 0, 500);
204  tfs->make<TH1F>("fTwoDStrengthPlane1", "TwoD Strength Plane 1", 1000, 0, 500);
206  tfs->make<TH1F>("fTwoDStrengthPlane2", "TwoD Strength Plane 2", 1000, 0, 500);
207 
208  fRecoCheck2dWireNumPlane0 = tfs->make<TH1F>(
209  "fRecoCheck2dWireNumPlane0", "Reco Wire Number - True Wire Number Plane 0", 400, -200, 200);
210  fRecoCheck2dTimeTickPlane0 = tfs->make<TH1F>(
211  "fRecoCheck2dTimeTickPlane0", "Reco Time Tick - True Time Tick Plane 0", 1000, -500, 500);
212  fRecoCheck2dWireInCmPlane0 = tfs->make<TH1F>(
213  "fRecoCheck2dWireInCmPlane0", "Reco Wire in CM - True Wire in CM Plane 0", 200, -50, 50);
214  fRecoCheck2dTimeInCmPlane0 = tfs->make<TH1F>(
215  "fRecoCheck2dTimeInCmPlane0", "Reco Time in CM - True Time in CM Plane 0", 200, -50, 50);
216 
217  fRecoCheck2dWireNumPlane1 = tfs->make<TH1F>(
218  "fRecoCheck2dWireNumPlane1", "Reco Wire Number - True Wire Number Plane 1", 400, -200, 200);
219  fRecoCheck2dTimeTickPlane1 = tfs->make<TH1F>(
220  "fRecoCheck2dTimeTickPlane1", "Reco Time Tick - True Time Tick Plane 1", 1000, -500, 500);
221  fRecoCheck2dWireInCmPlane1 = tfs->make<TH1F>(
222  "fRecoCheck2dWireInCmPlane1", "Reco Wire in CM - True Wire in CM Plane 1", 200, -50, 50);
223  fRecoCheck2dTimeInCmPlane1 = tfs->make<TH1F>(
224  "fRecoCheck2dTimeInCmPlane1", "Reco Time in CM - True Time in CM Plane 1", 200, -50, 50);
225 
226  fRecoCheck2dWireNumPlane2 = tfs->make<TH1F>(
227  "fRecoCheck2dWireNumPlane2", "Reco Wire Number - True Wire Number Plane 2", 400, -200, 200);
228  fRecoCheck2dTimeTickPlane2 = tfs->make<TH1F>(
229  "fRecoCheck2dTimeTickPlane2", "Reco Time Tick - True Time Tick Plane 2", 1000, -500, 500);
230  fRecoCheck2dWireInCmPlane2 = tfs->make<TH1F>(
231  "fRecoCheck2dWireInCmPlane2", "Reco Wire in CM - True Wire in CM Plane 2", 200, -50, 50);
232  fRecoCheck2dTimeInCmPlane2 = tfs->make<TH1F>(
233  "fRecoCheck2dTimeInCmPlane2", "Reco Time in CM - True Time in CM Plane 2", 200, -50, 50);
234 
235  fRecoVtxN3d = tfs->make<TH1F>("fRecoVtxN3d", "Number of 3d-Reco Verticies", 400, 0, 200);
236  fRecoVtxXPos = tfs->make<TH1F>("fRecoVtxXPos", "Reco Vertex X Position", 400, -10, 200);
237  fRecoVtxYPos = tfs->make<TH1F>("fRecoVtxYPos", "Reco Vertex Y Position", 400, -100, 100);
238  fRecoVtxZPos = tfs->make<TH1F>("fRecoVtxZPos", "Reco Vertex Z Position", 2000, -10, 1000);
239 
241  tfs->make<TH1F>("fRecoCheck3dVtxX", "Reco X Position - True X Postion", 800, -100, 100);
243  tfs->make<TH1F>("fRecoCheck3dVtxY", "Reco Y Position - True Y Postion", 800, -100, 100);
245  tfs->make<TH1F>("fRecoCheck3dVtxZ", "Reco Z Position - True Z Postion", 800, -100, 100);
246 
247  fRecoCheck3dVtxXvsX = tfs->make<TH2D>(
248  "fRecoCheck3dVtxXvsX", "(Reco X - True X)/True X vs True X", 400, -10, 200, 120, -20, 20);
249  fRecoCheck3dVtxYvsY = tfs->make<TH2D>(
250  "fRecoCheck3dVtxYvsY", "(Reco Y - True Y)/True Y vs True Y", 400, -100, 100, 120, -20, 20);
251  fRecoCheck3dVtxZvsZ = tfs->make<TH2D>(
252  "fRecoCheck3dVtxZvsZ", "(Reco Z - True Z)/True Z vs True Z", 1000, -10, 1000, 120, -20, 20);
253  }
254 
256  {
257  // Filling Run/Event Histo
258  fRun->Fill(evt.run());
259  fEvt->Fill(evt.id().event());
260 
261  // Getting the Geant Information Directly
263  evt.getByLabel(fLArG4ModuleLabel, mcParticleHandle);
264 
265  // Getting MC Truth Info from simb
266  auto const& mctruthList = *evt.getValidHandle<std::vector<simb::MCTruth>>(fGenieModuleLabel);
267 
268  // Getting information from BackTrackerService
270 
272  auto const clock_data =
274  auto const det_prop =
276 
277  // Getting 2d Vertex information (vertex2dHandle)
279  evt.getByLabel(fEndPoint2dModuleLabel, vertex2dHandle);
280 
281  // Getting the 3d Vertex (vertex3dListHandle)
282  art::Handle<std::vector<recob::Vertex>> vertex3dListHandle;
283  evt.getByLabel(fVertexModuleLabel, vertex3dListHandle);
284 
285  // Detector numbers that are useful (to be set later)
286  std::vector<double> WirePitch_CurrentPlane(geom->Views().size(),
287  0.); //<---Setting the Wire pitch for each plane
288  // Right now assuming only 3 planes
289  // get the wire pitch for each view
290  size_t vn = 0;
291  for (auto v : geom->Views()) {
292  WirePitch_CurrentPlane[vn] = geom->WirePitch(v);
293  ++vn;
294  }
295 
296  // Calculating the Timetick to CM conversion
297  float TimeTick =
298  sampling_rate(clock_data) / 1000.; //<---To get units of microsecond...not nanosec
299  float DriftVelocity = det_prop.DriftVelocity(det_prop.Efield(), det_prop.Temperature());
300  float TimetoCm = TimeTick * DriftVelocity;
301 
302  // Looping over MC information
303 
304  // Variables for truth vertex information
305  geo::Point_t truth_vertex{}; //<---Truth x,y,z information
306 
307  uint32_t VtxWireNum[3] = {0}; //<---Wire number in each plane ( WireNum[plane#] )
308  double VtxTimeTick[3] = {0.}; //<---Time tick in each plane ( TimeTick[plane#] )
309 
310  double VtxWireNum_InCM[3] = {0.}; //<---Wire number in each plane in CM ( WireNum[plane#] )
311  double VtxTimeTick_InCM[3] = {0.}; //<---Time tick in each plane in CM ( TimeTick[plane#] )
312 
313  // Finding the MC truth vertex
314 
315  // FIXME: Can this be right? We're looping over all of the
316  // MCTruth particles just so that we can use the last one
317  // (i.e. truth_vertex is set each time but only the last
318  // iteration is relevant)?
319  for (std::size_t i = 0; i != mctruthList.size(); ++i) {
320  auto const& neut = mctruthList[i].GetParticle(i);
321  truth_vertex.SetX(neut.Vx());
322  truth_vertex.SetY(neut.Vy());
323  truth_vertex.SetZ(neut.Vz());
324  } // end i loop
325 
326  // Filling Histograms
327  fTruthVtxXPos->Fill(truth_vertex.X());
328  fTruthVtxYPos->Fill(truth_vertex.Y());
329  fTruthVtxZPos->Fill(truth_vertex.Z());
330 
331  // Looping over geo::PlaneIDs
332  for (auto const& pid : geom->Iterate<geo::PlaneID>()) {
333  // Calculating the nearest wire the vertex corresponds to in each plane
334  try {
335  VtxWireNum[pid.Plane] = geom->NearestWireID(truth_vertex, pid).Wire;
336  }
337  catch (...) {
338  mf::LogWarning("FeatureVertexFinderAna") << "Can't find nearest wire";
339  continue;
340  }
341  VtxTimeTick[pid.Plane] =
342  det_prop.ConvertXToTicks(truth_vertex.X(), pid) + det_prop.GetXTicksOffset(pid);
343 
344  // Translating each of these in cm
345  VtxWireNum_InCM[pid.Plane] = VtxWireNum[pid.Plane] * WirePitch_CurrentPlane[pid.Plane];
346  VtxTimeTick_InCM[pid.Plane] = VtxTimeTick[pid.Plane] * TimetoCm;
347  } //<---End pid loop
348 
349  // Filling Histograms
350  fTruthWireNumberPlane0->Fill(VtxWireNum[0]);
351  fTruthTimeTickPlane0->Fill(VtxTimeTick[0]);
352  fTruthWireNumberPlane1->Fill(VtxWireNum[1]);
353  fTruthTimeTickPlane1->Fill(VtxTimeTick[1]);
354  fTruthWireNumberPlane2->Fill(VtxWireNum[2]);
355  fTruthTimeTickPlane2->Fill(VtxTimeTick[2]);
356 
357  fTruthWireInCmPlane0->Fill(VtxWireNum_InCM[0]);
358  fTruthTimeInCmPlane0->Fill(VtxTimeTick_InCM[0]);
359  fTruthWireInCmPlane1->Fill(VtxWireNum_InCM[1]);
360  fTruthTimeInCmPlane1->Fill(VtxTimeTick_InCM[1]);
361  fTruthWireInCmPlane2->Fill(VtxWireNum_InCM[2]);
362  fTruthTimeInCmPlane2->Fill(VtxTimeTick_InCM[2]);
363 
364  // Looping over EndPoint2d information
365 
367 
368  // Variables for Vertex2d
369  double Vertex2d_TimeTick[10000] = {
370  0.}; //<---Vertex2d Time Tick for the current plane ( TimeTick[#2d] )
371  double Vertex2d_Wire[10000] = {0.}; //<---Veretx2d Wire # ( Wire[#2d] )
372 
373  double Vertex2d_TimeTick_InCM[10000] = {0.}; //<---Vertex 2d Time tick in CM ( TimeTick[#2d] )
374  double Vertex2d_Wire_InCM[10000] = {0.}; //<---Veretx2d Wire in CM ( Wire[#2d] )
375  int n2dVtx = 0;
376 
377  int n2dVtxPlane0 = 0, n2dVtxPlane1 = 0, n2dVtxPlane2 = 0;
378 
379  bool vertexWstrengthplane0 = false,
380  vertexWstrengthplane1 =
381  false; //, vertexWstrengthplane2 = false; //commented out, Wes, 12.4.13
382 
383  // Loop over the EndPoint2d List
384  for (size_t ii = 0; ii < vertex2dHandle->size(); ++ii) {
385  art::Ptr<recob::EndPoint2D> vertex(vertex2dHandle, ii);
386  vert2d.push_back(vertex);
387  }
388 
389  // If we have 2d vertex, loop over them
390  if (vert2d.size() > 0) {
391 
392  // Looping over geo::PlaneIDs
393  for (auto const& pid : geom->Iterate<geo::PlaneID>()) {
394  for (size_t ww = 0; ww < vert2d.size(); ++ww) {
395  // Only look at this 2d vertex if it is in the current plane
396  if (vert2d[ww]->WireID().planeID() != pid) { continue; }
397 
398  Vertex2d_TimeTick[n2dVtx] = vert2d[ww]->DriftTime();
399  Vertex2d_Wire[n2dVtx] = vert2d[ww]->WireID().Wire;
400 
401  // Translating each of these in cm
402  Vertex2d_Wire_InCM[n2dVtx] = Vertex2d_Wire[n2dVtx] * WirePitch_CurrentPlane[pid.Plane];
403  Vertex2d_TimeTick_InCM[n2dVtx] = Vertex2d_TimeTick[n2dVtx] * TimetoCm;
404 
405  // Checking how well we did in reconstructing the vertex (Reco - True)
406 
407  float RecoCheck_TimeTick = Vertex2d_TimeTick[n2dVtx] - VtxTimeTick[pid.Plane];
408  float RecoCheck_WireNum = Vertex2d_Wire[n2dVtx] - VtxWireNum[pid.Plane];
409 
410  float RecoCheck_TimeInCm = Vertex2d_TimeTick_InCM[n2dVtx] - VtxTimeTick_InCM[pid.Plane];
411  float RecoCheck_WireInCm = Vertex2d_Wire_InCM[n2dVtx] - VtxWireNum_InCM[pid.Plane];
412 
413  if (vert2d[ww]->Strength() > -1) {
414  if (pid.Plane == 0) {
415  vertexWstrengthplane0 = true;
416 
417  fTwoDWireNumberPlane0->Fill(Vertex2d_Wire[n2dVtx]);
418  fTwoDTimeTickPlane0->Fill(Vertex2d_TimeTick[n2dVtx]);
419  fTwoDWireInCmPlane0->Fill(Vertex2d_Wire_InCM[n2dVtx]);
420  fTwoDTimeInCmPlane0->Fill(Vertex2d_TimeTick_InCM[n2dVtx]);
421 
422  fTwoDStrengthPlane0->Fill(vert2d[ww]->Strength());
423 
424  fRecoCheck2dWireNumPlane0->Fill(RecoCheck_WireNum);
425  fRecoCheck2dTimeTickPlane0->Fill(RecoCheck_TimeTick);
426  fRecoCheck2dWireInCmPlane0->Fill(RecoCheck_WireInCm);
427  fRecoCheck2dTimeInCmPlane0->Fill(RecoCheck_TimeInCm);
428 
429  n2dVtxPlane0++;
430 
431  } //<---End Plane 0
432 
433  if (pid.Plane == 1) {
434  vertexWstrengthplane1 = true;
435  fTwoDWireNumberPlane1->Fill(Vertex2d_Wire[n2dVtx]);
436  fTwoDTimeTickPlane1->Fill(Vertex2d_TimeTick[n2dVtx]);
437  fTwoDWireInCmPlane1->Fill(Vertex2d_Wire_InCM[n2dVtx]);
438  fTwoDTimeInCmPlane1->Fill(Vertex2d_TimeTick_InCM[n2dVtx]);
439 
440  fTwoDStrengthPlane1->Fill(vert2d[ww]->Strength());
441 
442  fRecoCheck2dWireNumPlane1->Fill(RecoCheck_WireNum);
443  fRecoCheck2dTimeTickPlane1->Fill(RecoCheck_TimeTick);
444  fRecoCheck2dWireInCmPlane1->Fill(RecoCheck_WireInCm);
445  fRecoCheck2dTimeInCmPlane1->Fill(RecoCheck_TimeInCm);
446 
447  n2dVtxPlane1++;
448 
449  } //<---End Plane 1
450 
451  if (pid.Plane == 2) {
452  fTwoDWireNumberPlane2->Fill(Vertex2d_Wire[n2dVtx]);
453  fTwoDTimeTickPlane2->Fill(Vertex2d_TimeTick[n2dVtx]);
454  fTwoDWireInCmPlane2->Fill(Vertex2d_Wire_InCM[n2dVtx]);
455  fTwoDTimeInCmPlane2->Fill(Vertex2d_TimeTick_InCM[n2dVtx]);
456 
457  fTwoDStrengthPlane2->Fill(vert2d[ww]->Strength());
458 
459  fRecoCheck2dWireNumPlane2->Fill(RecoCheck_WireNum);
460  fRecoCheck2dTimeTickPlane2->Fill(RecoCheck_TimeTick);
461  fRecoCheck2dWireInCmPlane2->Fill(RecoCheck_WireInCm);
462  fRecoCheck2dTimeInCmPlane2->Fill(RecoCheck_TimeInCm);
463 
464  n2dVtxPlane2++;
465 
466  } //<---End Plane 2
467  }
468 
469  ++n2dVtx;
470  } //<--end ww loop
471 
472  } //<---End plane ID
473 
474  } //<--End checking if we have 2d end points
475 
476  fTwoDNVtxPlane0->Fill(n2dVtxPlane0);
477  fTwoDNVtxPlane1->Fill(n2dVtxPlane1);
478  fTwoDNVtxPlane2->Fill(n2dVtxPlane2);
479 
480  // Looping over 3dVertex information
482 
483  double xyz[3] = {0.};
484 
485  for (unsigned int ii = 0; ii < vertex3dListHandle->size(); ++ii) {
486  art::Ptr<recob::Vertex> vertex3d(vertex3dListHandle, ii);
487  Vertexlist.push_back(vertex3d); // class member
488 
489  } //<---End ii loop
490 
491  if (Vertexlist.size() > 0 && vertexWstrengthplane0 && vertexWstrengthplane1) {
492 
493  fRecoVtxN3d->Fill(Vertexlist.size());
494  for (unsigned int ww = 0; ww < Vertexlist.size(); ww++) {
495  Vertexlist[ww]->XYZ(xyz);
496 
497  // Checking how well we did in reconstructing the vertex (Reco - True)
498 
499  // Finding the Delta X, Y, Z between Reco vtx and truth
500  double DeltaX = xyz[0] - truth_vertex.X();
501  double DeltaY = xyz[1] - truth_vertex.Y();
502  double DeltaZ = xyz[2] - truth_vertex.Z();
503 
504  double DeltaXoverTrueX = DeltaX / truth_vertex.X();
505  double DeltaYoverTrueY = DeltaY / truth_vertex.X();
506  double DeltaZoverTrueZ = DeltaZ / truth_vertex.X();
507 
508  fRecoVtxXPos->Fill(xyz[0]);
509  fRecoVtxYPos->Fill(xyz[1]);
510  fRecoVtxZPos->Fill(xyz[2]);
511 
512  fRecoCheck3dVtxX->Fill(DeltaX);
513  fRecoCheck3dVtxY->Fill(DeltaY);
514  fRecoCheck3dVtxZ->Fill(DeltaZ);
515 
516  fRecoCheck3dVtxXvsX->Fill(xyz[0], DeltaXoverTrueX);
517  fRecoCheck3dVtxYvsY->Fill(xyz[1], DeltaYoverTrueY);
518  fRecoCheck3dVtxZvsZ->Fill(xyz[2], DeltaZoverTrueZ);
519  }
520  }
521  } //<---End access the event
522 
524 
525 } // end of vertex namespace
details::range_type< T > Iterate() const
Initializes the specified ID with the ID of the first cryostat.
Definition: GeometryCore.h:541
The data type to uniquely identify a Plane.
Definition: geo_types.h:463
void analyze(const art::Event &evt) override
WireID_t Wire
Index of the wire within its plane.
Definition: geo_types.h:563
EDAnalyzer(fhicl::ParameterSet const &pset)
Definition: EDAnalyzer.cc:6
FeatureVertexFinderAna(fhicl::ParameterSet const &pset)
#define DEFINE_ART_MODULE(klass)
Definition: ModuleMacros.h:65
IDparameter< geo::WireID > WireID
Member type of validated geo::WireID parameter.
void push_back(Ptr< U > const &p)
Definition: PtrVector.h:435
T get(std::string const &key) const
Definition: ParameterSet.h:314
size_type size() const
Definition: PtrVector.h:302
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:180
ValidHandle< PROD > getValidHandle(InputTag const &tag) const
WireID NearestWireID(Point_t const &point, PlaneID const &planeid) const
Returns the ID of wire closest to position in the specified TPC.
bool getByLabel(std::string const &label, std::string const &instance, Handle< PROD > &result) const
MaybeLogger_< ELseverityLevel::ELsev_warning, false > LogWarning
std::set< View_t > const & Views() const
Returns a list of possible views in the detector.
EventNumber_t event() const
Definition: EventID.h:116
TCEvent evt
Definition: DataStructs.cxx:8
RunNumber_t run() const
Definition: Event.cc:29
double sampling_rate(DetectorClocksData const &data)
Returns the period of the TPC readout electronics clock.
Length_t WirePitch(PlaneID const &planeid=plane_zero) const
Returns the distance between two consecutive wires.
Definition: fwd.h:26
EventID id() const
Definition: Event.cc:23
art framework interface to geometry description
vertex reconstruction