Public Types | Public Member Functions | Protected Member Functions | Private Attributes | List of all members
beamlinereco::WCTrackReco Class Reference
Inheritance diagram for beamlinereco::WCTrackReco:
art::EDProducer art::detail::Producer art::detail::LegacyModule art::Modifier art::ModuleBase art::ProductRegistryHelper

Public Types

using ModuleType = EDProducer
 
using WorkerType = WorkerT< EDProducer >
 
template<typename UserConfig , typename KeysToIgnore = void>
using Table = Modifier::Table< UserConfig, KeysToIgnore >
 

Public Member Functions

 WCTrackReco (const fhicl::ParameterSet &pset)
 
void reconfigure (const fhicl::ParameterSet &pset)
 
void beginJob ()
 
void produce (art::Event &evt)
 
std::string workerType () const
 
void doBeginJob ()
 
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)
 
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< TconsumesView (InputTag const &tag)
 
template<typename T , BranchType BT>
ViewToken< TmayConsumeView (InputTag const &tag)
 

Protected Member Functions

ConsumesCollector & consumesCollector ()
 
template<typename T , BranchType = InEvent>
ProductToken< Tconsumes (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< TmayConsume (InputTag const &)
 
template<typename Element , BranchType = InEvent>
ViewToken< Element > mayConsumeView (InputTag const &)
 
template<typename T , BranchType = InEvent>
void mayConsumeMany ()
 

Private Attributes

art::InputTag fRawWCDataLabel
 
art::InputTag fRawBeamlineConfigLabel
 
art::InputTag fMCenterDataLabel
 
bool fVerbose
 
bool fPickyTracks
 
bool fUseIFDB
 
double fVertexTime
 
TH1F * fReco_P
 
TH1F * fY_Kink
 
TH1F * fX_Dist
 
TH1F * fY_Dist
 
TH1F * fZ_Dist
 
TH1F * fX_Mag_Int
 
TH1F * fY_Mag_Int
 
TH1F * fZ_Mag_Int
 
TH1F * fDist_to_Mag_Axis
 
TH1F * fX_Face_Dist
 
TH1F * fY_Face_Dist
 
TH1F * fTheta_Dist
 
TH1F * fPhi_Dist
 
TH1F * fTrack_Type
 
TH1F * fWCDist
 
WCHitFinderAlg fWCHitFinderAlg
 
WCTrackAlg fWCTrackAlg
 
art::ServiceHandle< beamlineutil::BeamlineMagneticFieldfMagneticField
 

Detailed Description

Definition at line 43 of file WCTrackReco_module.cc.

Member Typedef Documentation

Definition at line 17 of file EDProducer.h.

template<typename UserConfig , typename KeysToIgnore = void>
using art::detail::Producer::Table = Modifier::Table<UserConfig, KeysToIgnore>
inherited

Definition at line 25 of file Producer.h.

using art::EDProducer::WorkerType = WorkerT<EDProducer>
inherited

Definition at line 18 of file EDProducer.h.

Constructor & Destructor Documentation

beamlinereco::WCTrackReco::WCTrackReco ( const fhicl::ParameterSet pset)
explicit

Definition at line 95 of file WCTrackReco_module.cc.

References reconfigure().

95  :
96  EDProducer(pset),
97  fWCHitFinderAlg(pset.get<fhicl::ParameterSet>("WCHitFinderAlg")),
98  fWCTrackAlg(pset.get<fhicl::ParameterSet>("WCTrackAlg")) {
99 
100  this->reconfigure(pset);
101  produces<std::vector<brb::WCTrack> >();
102  produces<art::Assns<brb::WCTrack, rawdata::RawBeamlineWC> >();
103  produces<std::vector<rb::Vertex> > ();
104  produces<art::Assns<rb::Vertex, brb::WCTrack> > ();
105 }
EDProducer(fhicl::ParameterSet const &pset)
Definition: EDProducer.h:20
void reconfigure(const fhicl::ParameterSet &pset)
T get(std::string const &key) const
Definition: ParameterSet.h:231

Member Function Documentation

void beamlinereco::WCTrackReco::beginJob ( )
virtual

Reimplemented from art::EDProducer.

Definition at line 118 of file WCTrackReco_module.cc.

References fDist_to_Mag_Axis, fPhi_Dist, fReco_P, fTheta_Dist, fTrack_Type, fWCDist, fX_Dist, fX_Face_Dist, fX_Mag_Int, fY_Dist, fY_Face_Dist, fY_Kink, fY_Mag_Int, fZ_Dist, and fZ_Mag_Int.

118  {
120 
121  fWCDist = tfs->make<TH1F>("WCCond","WC Conditions",7,0,7);
122  fReco_P = tfs->make<TH1F>("Reco_P","Reconstructed momentum", 180, 0, 1800);
123  fY_Kink = tfs->make<TH1F>("Y_Kink","Angle between US/DS tracks in Y direction (degrees)",200,-10*3.1415926/180,10*3.141592654/180);
124  fX_Dist = tfs->make<TH1F>("X_Dist","X distance between US/DS tracks at midplane (mm)",1200,-60,1260); //Do not trust these values
125  fY_Dist = tfs->make<TH1F>("Y_Dist","Y distance between US/DS tracks at midplane (mm)",1200,-600,600); //Do not trust these values
126  fZ_Dist = tfs->make<TH1F>("Z_Dist","Z distance between US/DS tracks at midplane (mm)",1200,-60,1260); //Do not trust these values
127  fX_Mag_Int = tfs->make<TH1F>("X_Mag_Int","X intercept of WC track with magnet front face (cm)",100,-150,-100);
128  fX_Mag_Int->GetXaxis()->SetTitle("X intercept [cm]");
129  fX_Mag_Int->GetYaxis()->SetTitle("Tracks per 2 cm");
130  fY_Mag_Int = tfs->make<TH1F>("Y_Mag_Int","Y intercept of WC track with magnet front face (cm)",100,-10,10);
131  fY_Mag_Int->GetXaxis()->SetTitle("Y intercept [cm]");
132  fY_Mag_Int->GetYaxis()->SetTitle("Tracks per 0.22 cm");
133  fZ_Mag_Int = tfs->make<TH1F>("Z_Mag_Int","Z intercept of WC track with magnet front face (cm)",100,415,425);
134  fZ_Mag_Int->GetXaxis()->SetTitle("Z intercept [cm]");
135  fZ_Mag_Int->GetYaxis()->SetTitle("Tracks per 0.1 cm");
136  fDist_to_Mag_Axis = tfs->make<TH1F>("Dist_to_Mag_Axis","Transverse distance to central axis of magnet [cm]",80,-20,20);
137  fDist_to_Mag_Axis->GetXaxis()->SetTitle("Transverse distance from WC track to central axis of magnet [cm]");
138  fDist_to_Mag_Axis->GetXaxis()->SetTitle("Tracks per 0.5 cm");
139  fX_Face_Dist = tfs->make<TH1F>("X_Face","X Location of Track's Detector Entry (mm)",1600,-200,1400);
140  fY_Face_Dist = tfs->make<TH1F>("Y_Face","Y Location of Track's Detector Entry (mm)",800,-400,400);
141  fTheta_Dist = tfs->make<TH1F>("Theta","Track Theta (w.r.t. Detector Z axis), (radians),",400,-.4,0.4);
142  fPhi_Dist = tfs->make<TH1F>("Phi","Track Phi (w.r.t. Detector X axis), (radians)",2000,-6.28318,6.28318);
143  fReco_P->GetXaxis()->SetTitle("Reconstructed momentum (MeV/c)");
144  fReco_P->GetYaxis()->SetTitle("Tracks per 10 MeV/c");
145  fY_Kink->GetXaxis()->SetTitle("Reconstructed y_kink (radians)");
146  fY_Kink->GetYaxis()->SetTitle("Tracks per 0.000872 radians");
147  fX_Dist->GetXaxis()->SetTitle("X distance between US and DS track ends");
148  fX_Dist->GetYaxis()->SetTitle("Tracks per 1 mm - DO NOT TRUST THESE VALUES");
149  fY_Dist->GetXaxis()->SetTitle("Y distance between US and DS track ends");
150  fY_Dist->GetYaxis()->SetTitle("Tracks per 1 mm - DO NOT TRUST THESE VALUES");
151  fZ_Dist->GetXaxis()->SetTitle("Z distance between US and DS track ends");
152  fZ_Dist->GetYaxis()->SetTitle("Tracks per 1 mm - DO NOT TRUST THESE VALUES");
153  fX_Face_Dist->GetXaxis()->SetTitle("X (mm)");
154  fX_Face_Dist->GetYaxis()->SetTitle("Tracks per 1 mm");
155  fY_Face_Dist->GetXaxis()->SetTitle("Y (mm)");
156  fY_Face_Dist->GetYaxis()->SetTitle("Tracks per 1 mm");
157  fTheta_Dist->GetXaxis()->SetTitle("Theta (radians)");
158  fTheta_Dist->GetYaxis()->SetTitle("Tracks per .002 radians");
159  fPhi_Dist->GetXaxis()->SetTitle("Phi (radians)");
160  fPhi_Dist->GetYaxis()->SetTitle("Tracks per 0.00628 radians");
161  fTrack_Type = tfs->make<TH1F>("TrackType","WCTrack conditions: 1=missHit,2=uniqueHits,3=lonelyHit,4=socialHits",4,0,4);
162  fTrack_Type->GetYaxis()->SetTitle("# Events");
163  fTrack_Type->GetXaxis()->SetTitle("Track Conditions");
164 
165 }
template<typename T , BranchType BT>
ProductToken< T > art::ModuleBase::consumes ( InputTag const &  tag)
protectedinherited

Definition at line 55 of file ModuleBase.h.

References art::ModuleBase::collector_, art::ConsumesCollector::consumes(), T, and getGoodRuns4SAM::tag.

56  {
57  return collector_.consumes<T, BT>(tag);
58  }
ConsumesCollector collector_
Definition: ModuleBase.h:50
ProductToken< T > consumes(InputTag const &)
double T
Definition: Xdiff_gwt.C:5
ConsumesCollector& art::ModuleBase::consumesCollector ( )
protectedinherited
template<typename T , BranchType BT>
void art::ModuleBase::consumesMany ( )
protectedinherited

Definition at line 69 of file ModuleBase.h.

References art::ModuleBase::collector_, art::ConsumesCollector::consumesMany(), and T.

70  {
71  collector_.consumesMany<T, BT>();
72  }
ConsumesCollector collector_
Definition: ModuleBase.h:50
double T
Definition: Xdiff_gwt.C:5
template<typename Element , BranchType = InEvent>
ViewToken<Element> art::ModuleBase::consumesView ( InputTag const &  )
protectedinherited
template<typename T , BranchType BT>
ViewToken<T> art::ModuleBase::consumesView ( InputTag const &  tag)
inherited

Definition at line 62 of file ModuleBase.h.

References art::ModuleBase::collector_, art::ConsumesCollector::consumesView(), T, and getGoodRuns4SAM::tag.

63  {
64  return collector_.consumesView<T, BT>(tag);
65  }
ConsumesCollector collector_
Definition: ModuleBase.h:50
ViewToken< Element > consumesView(InputTag const &)
double T
Definition: Xdiff_gwt.C:5
void art::detail::Producer::doBeginJob ( )
inherited
bool art::detail::Producer::doBeginRun ( RunPrincipal rp,
ModuleContext const &  mc 
)
inherited
bool art::detail::Producer::doBeginSubRun ( SubRunPrincipal srp,
ModuleContext const &  mc 
)
inherited
void art::detail::Producer::doEndJob ( )
inherited
bool art::detail::Producer::doEndRun ( RunPrincipal rp,
ModuleContext const &  mc 
)
inherited
bool art::detail::Producer::doEndSubRun ( SubRunPrincipal srp,
ModuleContext const &  mc 
)
inherited
bool art::detail::Producer::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 
)
inherited
void art::detail::Producer::doRespondToCloseInputFile ( FileBlock const &  fb)
inherited
void art::detail::Producer::doRespondToCloseOutputFiles ( FileBlock const &  fb)
inherited
void art::detail::Producer::doRespondToOpenInputFile ( FileBlock const &  fb)
inherited
void art::detail::Producer::doRespondToOpenOutputFiles ( FileBlock const &  fb)
inherited
std::array<std::vector<ProductInfo>, NumBranchTypes> const& art::ModuleBase::getConsumables ( ) const
inherited
template<typename T , BranchType BT>
ProductToken< T > art::ModuleBase::mayConsume ( InputTag const &  tag)
protectedinherited

Definition at line 76 of file ModuleBase.h.

References art::ModuleBase::collector_, art::ConsumesCollector::mayConsume(), T, and getGoodRuns4SAM::tag.

77  {
78  return collector_.mayConsume<T, BT>(tag);
79  }
ProductToken< T > mayConsume(InputTag const &)
ConsumesCollector collector_
Definition: ModuleBase.h:50
double T
Definition: Xdiff_gwt.C:5
template<typename T , BranchType BT>
void art::ModuleBase::mayConsumeMany ( )
protectedinherited

Definition at line 90 of file ModuleBase.h.

References art::ModuleBase::collector_, art::ConsumesCollector::mayConsumeMany(), and T.

91  {
93  }
ConsumesCollector collector_
Definition: ModuleBase.h:50
double T
Definition: Xdiff_gwt.C:5
template<typename Element , BranchType = InEvent>
ViewToken<Element> art::ModuleBase::mayConsumeView ( InputTag const &  )
protectedinherited
template<typename T , BranchType BT>
ViewToken<T> art::ModuleBase::mayConsumeView ( InputTag const &  tag)
inherited

Definition at line 83 of file ModuleBase.h.

References art::ModuleBase::collector_, art::ConsumesCollector::mayConsumeView(), T, and getGoodRuns4SAM::tag.

84  {
85  return collector_.mayConsumeView<T, BT>(tag);
86  }
ConsumesCollector collector_
Definition: ModuleBase.h:50
ViewToken< Element > mayConsumeView(InputTag const &)
double T
Definition: Xdiff_gwt.C:5
ModuleDescription const& art::ModuleBase::moduleDescription ( ) const
inherited
void beamlinereco::WCTrackReco::produce ( art::Event evt)
virtual

Implements art::EDProducer.

Definition at line 168 of file WCTrackReco_module.cc.

References rawdata::RawBeamlineConfig::BeamlineRun(), util::CreateAssn(), beamlinereco::WCHitFinderAlg::createHits(), e, allTimeWatchdog::endl, fDist_to_Mag_Axis, beamlineutil::BeamlineMagneticField::FieldFromCurrent(), art::fill_ptr_vector(), fMagneticField, fMCenterDataLabel, fPhi_Dist, fRawBeamlineConfigLabel, fRawWCDataLabel, fReco_P, fTheta_Dist, fUseIFDB, fVerbose, fVertexTime, fWCDist, fWCHitFinderAlg, fWCTrackAlg, fX_Dist, fX_Face_Dist, fX_Mag_Int, fY_Dist, fY_Face_Dist, fY_Kink, fY_Mag_Int, fZ_Dist, fZ_Mag_Int, art::DataViewImpl::getByLabel(), art::Handle< T >::isValid(), beamlineutil::BeamlineMagneticField::MagneticField(), sumdata::MCenterData::mc7magnet, art::DataViewImpl::put(), beamlinereco::WCTrackAlg::reconstructTracks(), beamlinereco::WCTrackAlg::setMagneticField(), novaddt::Theta(), X, Y, and Z.

168  {
169 
170  // data products to be made
171  std::unique_ptr<std::vector<brb::WCTrack> > wc_reco(new std::vector<brb::WCTrack>);
172  std::unique_ptr<art::Assns<brb::WCTrack, rawdata::RawBeamlineWC> >
174  std::unique_ptr<std::vector<rb::Vertex> > wc_vtx(new std::vector<rb::Vertex>);
175  std::unique_ptr<art::Assns<rb::Vertex, brb::WCTrack> >
176  vtx_to_wc_trk(new art::Assns<rb::Vertex, brb::WCTrack>);
177 
178  // get the raw WC digits
180  std::vector<art::Ptr<rawdata::RawBeamlineWC> > wcs;
181  if (evt.getByLabel(fRawWCDataLabel, wcHandle))
182  art::fill_ptr_vector(wcs, wcHandle);
183 
185  evt.getByLabel(fMCenterDataLabel, ifdb);
186  // get the magnetic field
187  float b_field = 0.;
188  // If spill is not found, magnet current will be set to -1e10.
189  // In this case, fallback on final else to use beamline run to find magnet current in fcl.
190  if ( fUseIFDB && ifdb.isValid() && ifdb->mc7magnet!=-1e10 )
191  b_field = fMagneticField->FieldFromCurrent(ifdb->mc7magnet);
192  else if ( fUseIFDB && !ifdb.isValid() ) {
193  mf::LogInfo("TBSpillInfo") << "MW: Change in reconstruction, March 27.\n"
194  << "The magnet information is now obtained from IFDB via the TBSpillInfo module, which need to be run first.\n"
195  << "Be sure to have run this module before WCTrackReco. (Alternatively, turn off the fUseIFDB flag (temporary))."
196  << std::endl;
197  abort();
198  }
199  else {
201  unsigned int beamline_run = 0;
202  //float b_field = -1.;
203  if (evt.getByLabel(fRawBeamlineConfigLabel, blConfigHandle)) {
204  //b_field = blConfigHandle->BField();
205  beamline_run = blConfigHandle->BeamlineRun();
206  }
207  try {
208  b_field = fMagneticField->MagneticField(beamline_run);
209  }
210  catch (cet::exception& e) {
211  e.what();
212  }
213  }
214  fWCTrackAlg.setMagneticField(b_field);
215 
216  // Find hits
217  std::vector<std::vector<WCHitList> > good_hits; // Two vectors: WC#, axis
219  good_hits,
220  fVerbose);
221 
222  // Find tracks
223  std::vector<double> reco_p_list;
224  std::vector<TVector3> mag_int_list;
225  std::vector<double> dist_to_mag_axis_list;
226  std::vector<TVector2> face_list;
227  std::vector<std::vector<TVector3> > wc_hit_pos_list;
228  std::vector<TVector3> dir_list;
229  std::vector<double> y_kink_list;
230  std::vector<TVector3> dist_list;
231  std::vector<WCHitList> final_tracks;
232  float residual;
233  int WCMissed;
234  fWCTrackAlg.reconstructTracks(reco_p_list,
235  mag_int_list,
236  dist_to_mag_axis_list,
237  face_list,
238  wc_hit_pos_list,
239  dir_list,
240  final_tracks,
241  good_hits,
242  y_kink_list,
243  dist_list,
244  WCMissed,
245  fWCDist,
246  residual);
247 
248  for (unsigned int iNewTrack = 0; iNewTrack < final_tracks.size(); ++iNewTrack) {
249 
250  WCHitList final_track = final_tracks[iNewTrack];
251 
252  // std::cout << "Making track with p " << reco_p_list[iNewTrack] << std::endl
253  // << "y kink " << y_kink_list[iNewTrack] << std::endl
254  // << "dist (" << dist_list[iNewTrack].X() << ", " << dist_list[iNewTrack].Y() << ", " << dist_list[iNewTrack].Z() << ")" << std::endl
255  // << "face (" << face_list[iNewTrack].X() << ", " << face_list[iNewTrack].Y() << ")" << std::endl
256  // << "wc 0 hit " << wc_hit_pos_list[iNewTrack][0].X() << ", " << wc_hit_pos_list[iNewTrack][0].Y() << ", " << wc_hit_pos_list[iNewTrack][0].Z() << ")" << std::endl
257  // << "wc 1 hit " << wc_hit_pos_list[iNewTrack][1].X() << ", " << wc_hit_pos_list[iNewTrack][1].Y() << ", " << wc_hit_pos_list[iNewTrack][1].Z() << ")" << std::endl
258  // << "wc 2 hit " << wc_hit_pos_list[iNewTrack][2].X() << ", " << wc_hit_pos_list[iNewTrack][2].Y() << ", " << wc_hit_pos_list[iNewTrack][2].Z() << ")" << std::endl
259  // << "wc 3 hit " << wc_hit_pos_list[iNewTrack][3].X() << ", " << wc_hit_pos_list[iNewTrack][3].Y() << ", " << wc_hit_pos_list[iNewTrack][3].Z() << ")" << std::endl
260  // << "dir " << dir_list[iNewTrack].X() << ", " << dir_list[iNewTrack].Y() << ", " << dir_list[iNewTrack].Z() << ")" << std::endl
261  // << "theta " << dir_list[iNewTrack].Theta() << std::endl
262  // << "phi " << dir_list[iNewTrack].Phi() << std::endl
263  // << "residual " << residual << std::endl;
264 
265  brb::WCTrack the_track(reco_p_list[iNewTrack],
266  y_kink_list[iNewTrack],
267  dist_list[iNewTrack],
268  mag_int_list[iNewTrack],
269  dist_to_mag_axis_list[iNewTrack],
270  face_list[iNewTrack],
271  wc_hit_pos_list[iNewTrack],
272  dir_list[iNewTrack],
273  dir_list[iNewTrack].Theta(),
274  dir_list[iNewTrack].Phi(),
275  residual);
276 
277  fReco_P->Fill(reco_p_list[iNewTrack]);
278  fY_Kink->Fill(y_kink_list[iNewTrack]);
279  fX_Dist->Fill(dist_list[iNewTrack].X());
280  fY_Dist->Fill(dist_list[iNewTrack].Y());
281  fZ_Dist->Fill(dist_list[iNewTrack].Z());
282  fX_Mag_Int->Fill(mag_int_list[iNewTrack].X());
283  fY_Mag_Int->Fill(mag_int_list[iNewTrack].Y());
284  fZ_Mag_Int->Fill(mag_int_list[iNewTrack].Z());
285  fDist_to_Mag_Axis->Fill(dist_to_mag_axis_list[iNewTrack]);
286  fX_Face_Dist->Fill(face_list[iNewTrack].X());
287  fY_Face_Dist->Fill(face_list[iNewTrack].Y());
288  fTheta_Dist->Fill(dir_list[iNewTrack].Theta());
289  fPhi_Dist->Fill(dir_list[iNewTrack].Phi());
290 
291  // create vertex for detector
292  rb::Vertex vtx(face_list[iNewTrack].X(),face_list[iNewTrack].Y(),0,fVertexTime);
293 
294  // add to output data product and make associations
295  (*wc_reco).push_back(the_track);
296  util::CreateAssn(evt, *(wc_reco.get()), wcs, *(wc_assn.get()));
297  (*wc_vtx).push_back(vtx);
298  util::CreateAssn(evt, *(vtx_to_wc_trk.get()), *(wc_vtx.get()), *(wc_reco.get()));
299 
300  }
301 
302  evt.put(std::move(wc_reco));
303  evt.put(std::move(wc_assn));
304  evt.put(std::move(wc_vtx));
305  evt.put(std::move(vtx_to_wc_trk));
306 
307  return;
308 
309 }
A 3D position and time representing an interaction vertex.
Definition: Vertex.h:15
static bool CreateAssn(art::EDProducer const &prod, art::Event &evt, std::vector< T > &a, art::Ptr< U > b, art::Assns< T, U > &assn, size_t indx=UINT_MAX, std::string const &instance=std::string())
Create a 1 to 1 association between a new product and one already in the event.
void createHits(const std::vector< art::Ptr< rawdata::RawBeamlineWC > > &wcs, std::vector< std::vector< WCHitList > > &good_hits, bool verbose)
MaybeLogger_< ELseverityLevel::ELsev_info, false > LogInfo
void setMagneticField(float field)
Definition: WCTrackAlg.cxx:517
unsigned int BeamlineRun() const
Definition: RawBeamline.cxx:30
::xsd::cxx::tree::exception< char > exception
Definition: Database.h:225
This module reads IFDB DB and then stores BNB spill info.
art::ServiceHandle< beamlineutil::BeamlineMagneticField > fMagneticField
Float_t Y
Definition: plot.C:38
Float_t Z
Definition: plot.C:38
bool isValid() const
Definition: Handle.h:183
bool getByLabel(std::string const &label, std::string const &instance, Handle< PROD > &result) const
Definition: DataViewImpl.h:446
float FieldFromCurrent(float magnet_current)
Convert magnet current to magnetic field using field mapping information.
double mc7magnet
Tertiary beamline magnet current [Amps].
Definition: MCenterData.h:29
float MagneticField(unsigned int beamline_run)
Return the magnetic field for a given beamline data run.
void fill_ptr_vector(std::vector< Ptr< T >> &ptrs, H const &h)
Definition: Ptr.h:291
Float_t e
Definition: plot.C:35
ProductID put(std::unique_ptr< PROD > &&edp, FullSemantic< Level::Run > const semantic)
Definition: DataViewImpl.h:730
Float_t X
Definition: plot.C:38
void reconstructTracks(std::vector< double > &reco_p_list, std::vector< TVector3 > &mag_int_list, std::vector< double > &dist_to_mag_axis_list, std::vector< TVector2 > &face_list, std::vector< std::vector< TVector3 > > &wc_hit_pos_list, std::vector< TVector3 > &dir_list, std::vector< WCHitList > &event_final_tracks, std::vector< std::vector< WCHitList > > &good_hits, std::vector< double > &y_kink_list, std::vector< TVector3 > &dist_list, int &WCMissed, TH1F *&WCdistribution, float &residual)
Main function called for each event.
Definition: WCTrackAlg.cxx:63
const float Theta() const
Definition: HoughPeak.h:88
void beamlinereco::WCTrackReco::reconfigure ( const fhicl::ParameterSet pset)

Definition at line 108 of file WCTrackReco_module.cc.

References fMCenterDataLabel, fRawBeamlineConfigLabel, fRawWCDataLabel, fUseIFDB, fVerbose, fVertexTime, fhicl::ParameterSet::get(), and string.

Referenced by WCTrackReco().

108  {
109  fRawWCDataLabel = pset.get<art::InputTag>("RawWCDataLabel");
110  fRawBeamlineConfigLabel = pset.get<std::string> ("RawBeamlineConfigLabel");
111  fMCenterDataLabel = pset.get<std::string> ("MCenterDataLabel");
112  fVerbose = pset.get<bool> ("Verbose", false);
113  fUseIFDB = pset.get<bool> ("UseIFDB");
114  fVertexTime = pset.get<double> ("VertexTime");
115 }
T get(std::string const &key) const
Definition: ParameterSet.h:231
enum BeamMode string
void art::ModuleBase::setModuleDescription ( ModuleDescription const &  )
inherited
void art::ModuleBase::sortConsumables ( std::string const &  current_process_name)
inherited
std::string art::EDProducer::workerType ( ) const
inherited

Member Data Documentation

TH1F* beamlinereco::WCTrackReco::fDist_to_Mag_Axis
private

Definition at line 75 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().

art::ServiceHandle<beamlineutil::BeamlineMagneticField> beamlinereco::WCTrackReco::fMagneticField
private

Definition at line 86 of file WCTrackReco_module.cc.

Referenced by produce().

art::InputTag beamlinereco::WCTrackReco::fMCenterDataLabel
private

Definition at line 58 of file WCTrackReco_module.cc.

Referenced by produce(), and reconfigure().

TH1F* beamlinereco::WCTrackReco::fPhi_Dist
private

Definition at line 79 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().

bool beamlinereco::WCTrackReco::fPickyTracks
private

Definition at line 62 of file WCTrackReco_module.cc.

art::InputTag beamlinereco::WCTrackReco::fRawBeamlineConfigLabel
private

Definition at line 57 of file WCTrackReco_module.cc.

Referenced by produce(), and reconfigure().

art::InputTag beamlinereco::WCTrackReco::fRawWCDataLabel
private

Definition at line 56 of file WCTrackReco_module.cc.

Referenced by produce(), and reconfigure().

TH1F* beamlinereco::WCTrackReco::fReco_P
private

Definition at line 67 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().

TH1F* beamlinereco::WCTrackReco::fTheta_Dist
private

Definition at line 78 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().

TH1F* beamlinereco::WCTrackReco::fTrack_Type
private

Definition at line 80 of file WCTrackReco_module.cc.

Referenced by beginJob().

bool beamlinereco::WCTrackReco::fUseIFDB
private

Definition at line 63 of file WCTrackReco_module.cc.

Referenced by produce(), and reconfigure().

bool beamlinereco::WCTrackReco::fVerbose
private

Definition at line 61 of file WCTrackReco_module.cc.

Referenced by produce(), and reconfigure().

double beamlinereco::WCTrackReco::fVertexTime
private

Definition at line 64 of file WCTrackReco_module.cc.

Referenced by produce(), and reconfigure().

TH1F* beamlinereco::WCTrackReco::fWCDist
private

Definition at line 81 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().

WCHitFinderAlg beamlinereco::WCTrackReco::fWCHitFinderAlg
private

Definition at line 84 of file WCTrackReco_module.cc.

Referenced by produce().

WCTrackAlg beamlinereco::WCTrackReco::fWCTrackAlg
private

Definition at line 85 of file WCTrackReco_module.cc.

Referenced by produce().

TH1F* beamlinereco::WCTrackReco::fX_Dist
private

Definition at line 69 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().

TH1F* beamlinereco::WCTrackReco::fX_Face_Dist
private

Definition at line 76 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().

TH1F* beamlinereco::WCTrackReco::fX_Mag_Int
private

Definition at line 72 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().

TH1F* beamlinereco::WCTrackReco::fY_Dist
private

Definition at line 70 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().

TH1F* beamlinereco::WCTrackReco::fY_Face_Dist
private

Definition at line 77 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().

TH1F* beamlinereco::WCTrackReco::fY_Kink
private

Definition at line 68 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().

TH1F* beamlinereco::WCTrackReco::fY_Mag_Int
private

Definition at line 73 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().

TH1F* beamlinereco::WCTrackReco::fZ_Dist
private

Definition at line 71 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().

TH1F* beamlinereco::WCTrackReco::fZ_Mag_Int
private

Definition at line 74 of file WCTrackReco_module.cc.

Referenced by beginJob(), and produce().


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