Public Member Functions | Private Member Functions | Private Attributes | List of all members
skim::SelectionNue2018FHC Class Reference

#include "/cvmfs/nova-development.opensciencegrid.org/novasoft/releases/N20-09-17/AnalysisSkimmer/evaluators/SelectionNue2018FHC.h"

Inheritance diagram for skim::SelectionNue2018FHC:
skim::SelectionBase

Public Member Functions

 SelectionNue2018FHC ()
 
 SelectionNue2018FHC (SelectionNue2018FHC const &)=delete
 
 SelectionNue2018FHC (SelectionNue2018FHC &&)=delete
 
SelectionNue2018FHCoperator= (SelectionNue2018FHC const &)=delete
 
SelectionNue2018FHCoperator= (SelectionNue2018FHC &&)=delete
 
void reconfigure (fhicl::ParameterSet const &p)
 
bool PassesSelection (skim::Parameters *pars, novadaq::cnv::DetId const &detId)
 

Private Member Functions

bool PassesPreselection (skim::ParametersNue const &params)
 
bool KeepNueFarDetectorSlice (skim::ParametersNue const &params)
 
bool KeepNueNearDetectorSlice (skim::ParametersNue const &params)
 
bool CheckSlicePID (skim::ParametersNue const &params)
 

Private Attributes

float fFDDistAllTop
 minimum distance to the top wall More...
 
float fFDDistAllBottom
 minimum distance to the bottom wall More...
 
float fFDDistAllWest
 minimum distance to the west wall More...
 
float fFDDistAllEast
 minimum distance to the east wall More...
 
float fFDDistAllFront
 minimum distance to the front wall More...
 
float fFDDistAllBack
 minimum distance to the back wall More...
 
float fFDMaxSparsenessAsymm
 maximum asymmetry in the zero-hit planes at the start and end of the shower More...
 
float fFDMaxDistAllBack
 maximum distance to the back wall More...
 
float fFarCloseBoundary
 distance at which we are no longer close to top of detector More...
 
float fVeryFarBoundary
 distance at which we are very far from the top of detector More...
 
float fMaxTransverseMomentumClose
 maximum transverse momentum when close to top of detector More...
 
float fMaxTransverseMomentumFar
 maximum transverse momentum when away from top of detector More...
 
float fSliceHitsPerPlane
 maximum number of hits per plane in a slice More...
 
float fFDMinSliceHits
 minimum number of hits required in FD slices. More...
 
float fFDMaxSliceHits
 maximum number of hits required in FD slices. More...
 
float fFDMaxNueEnergy
 max NueEnergy at FD More...
 
float fFDMinNueEnergy
 min NueEnergy at FD More...
 
float fMinCVNVal
 min cvn value optimised on S/sqrt(B) More...
 
float fFDMaxProngLength
 maximum length of longest prong More...
 
float fFDMinProngLength
 minimum length of longest prong More...
 
float fFDClosestSliceTimeBefore
 closest time distance allowed for previous slice More...
 
float fFDClosestSliceTimeAfter
 closest time distance allowed for next slice More...
 
float fFDClosestSliceHighCVNTopDist
 minimum distance from top for closest slice ( CVN > 0.87 ) More...
 
float fFDClosestSliceLowCVNTopDist
 minimum distance from top for closest slice ( 0.75 < CVN < 0.87 ) More...
 
float fFDClosestSliceMinDist
 minimum distance for closest slice More...
 
float fFDClosestSliceCVNBoundary
 CVN boundary for closest slice check. More...
 
float fNDMaxVertexX
 
float fNDMinVertexX
 
float fNDMaxVertexY
 
float fNDMinVertexY
 
float fNDMaxVertexZ
 
float fNDMinVertexZ
 
float fNDMaxShowerW
 
float fNDMinShowerZ
 
float fNDMaxShowerZ
 
float fNDMinSliceHits
 
float fNDMaxSliceHits
 
float fNDMaxNueEnergy
 
float fNDMinNueEnergy
 
float fNDMaxProngLength
 
float fNDMinProngLength
 
unsigned int fNDMinPlanesToFront
 

Detailed Description

Definition at line 17 of file SelectionNue2018FHC.h.

Constructor & Destructor Documentation

skim::SelectionNue2018FHC::SelectionNue2018FHC ( )

Definition at line 11 of file SelectionNue2018FHC.cxx.

12 {
13 
14 }
skim::SelectionNue2018FHC::SelectionNue2018FHC ( SelectionNue2018FHC const &  )
delete
skim::SelectionNue2018FHC::SelectionNue2018FHC ( SelectionNue2018FHC &&  )
delete

Member Function Documentation

bool skim::SelectionNue2018FHC::CheckSlicePID ( skim::ParametersNue const &  params)
private

Definition at line 162 of file SelectionNue2018FHC.cxx.

References skim::ParametersNue::CVNVal(), fMinCVNVal, and LOG_DEBUG.

Referenced by PassesSelection().

163 {
164  // only get rid of an event if both PID values are less than the minimum
165  // required. keep the event if it satisfies either cut.
166 
167  if( params.CVNVal() < fMinCVNVal){
168  LOG_DEBUG("SelectionNue2018FHC")
169  << "failed PID Cuts"
170  << "\nCVN: " << params.CVNVal() << " " << fMinCVNVal;
171  return false;
172  }
173 
174  LOG_DEBUG("SelectionNue2018FHC")
175  << "passed PID Cuts"
176  << "\nCVN: " << params.CVNVal() << " " << fMinCVNVal;
177  return true;
178 }
#define LOG_DEBUG(stream)
Definition: Messenger.h:149
float fMinCVNVal
min cvn value optimised on S/sqrt(B)
bool skim::SelectionNue2018FHC::KeepNueFarDetectorSlice ( skim::ParametersNue const &  params)
private

Definition at line 199 of file SelectionNue2018FHC.cxx.

References skim::ParametersNue::ClosestSliceDistFromTop(), skim::ParametersNue::ClosestSliceMinDist(), skim::ParametersNue::ClosestSliceTime(), skim::ParametersNue::CVNVal(), skim::ParametersNue::DistAllBack(), skim::ParametersNue::DistAllBottom(), skim::ParametersNue::DistAllEast(), skim::ParametersNue::DistAllFront(), skim::ParametersNue::DistAllTop(), skim::ParametersNue::DistAllWest(), fFarCloseBoundary, fFDClosestSliceCVNBoundary, fFDClosestSliceHighCVNTopDist, fFDClosestSliceLowCVNTopDist, fFDClosestSliceMinDist, fFDClosestSliceTimeAfter, fFDClosestSliceTimeBefore, fFDDistAllBack, fFDDistAllBottom, fFDDistAllEast, fFDDistAllFront, fFDDistAllTop, fFDDistAllWest, fFDMaxDistAllBack, fFDMaxProngLength, fFDMaxSliceHits, fFDMaxSparsenessAsymm, fFDMinProngLength, fFDMinSliceHits, fMaxTransverseMomentumClose, fMaxTransverseMomentumFar, fMinCVNVal, fVeryFarBoundary, LOG_DEBUG, PassesPreselection(), skim::ParametersNue::ProngLength(), skim::ParametersNue::ShowerMaxY(), skim::ParametersNue::ShowerPt(), skim::ParametersNue::SliceHits(), skim::ParametersNue::SparsenessAsymm(), and skim::ParametersNue::VetoKeepNue().

Referenced by PassesSelection().

200 {
201  if(!this->PassesPreselection(params)) return false;
202 
203  // cuts based on slice info include cuts on number of hits,
204  // energy of slice, fraction of slice hits in 3D showers
205  //
206  if(params.SliceHits() < fFDMinSliceHits ||
207  params.SliceHits() > fFDMaxSliceHits
208  // params.NueEnergy() > fFDMaxNueEnergy ||
209  // params.NueEnergy() < fFDMinNueEnergy
210  ){
211  LOG_DEBUG("SelectionNue2018FHC")
212  << "failed Cell/Hit Checks"
213  << "\nSliceHits: " << params.SliceHits();
214 
215  return false;
216  }
217  LOG_DEBUG("SelectionNue2018FHC")
218  << "passed Cell/Hit Checks"
219  << "\nSliceHits: " << fFDMinSliceHits << " <= " << params.SliceHits() << " <= " << fFDMaxSliceHits;
220 
221  // check the prong length
222  if(params.ProngLength() <= fFDMinProngLength ||
223  params.ProngLength() >= fFDMaxProngLength ){
224  LOG_DEBUG("SelectionNue2018FHC")
225  << "failed shower length cuts"
226  << "\nProngLength: " << params.ProngLength() << " " << fFDMaxProngLength
227  << "\nProngLength: " << params.ProngLength() << " " << fFDMinProngLength;
228  return false;
229  }
230  LOG_DEBUG("SelectionNue2018FHC")
231  << "passed shower length cuts"
232  << "\nProngLength: " << params.ProngLength() << " " << fFDMaxProngLength
233  << "\nProngLength: " << params.ProngLength() << " " << fFDMinProngLength;
234 
235  // cuts based on the showers - we already checked the number of showers
236  // in the KeepSlice method, so don't bother doing it again
237  if((params.ShowerMaxY() >= fVeryFarBoundary && params.ShowerMaxY() < fFarCloseBoundary && params.ShowerPt() >= fMaxTransverseMomentumFar) ||
238  (params.ShowerMaxY() >= fFarCloseBoundary && params.ShowerPt() >= fMaxTransverseMomentumClose)
239  ){
240  LOG_DEBUG("SelectionNue2018FHC")
241  << "failed ptp cuts"
242  << "\nMinTopDist: " << params.ShowerMaxY() << " " << fVeryFarBoundary
243  << "\nMinTopDist: " << params.ShowerMaxY() << " " << fFarCloseBoundary
244  << "\nShowerPt: " << params.ShowerPt() << " " << fMaxTransverseMomentumFar
245  << "\nShowerPt: " << params.ShowerPt() << " " << fMaxTransverseMomentumClose;
246  return false;
247  }
248  LOG_DEBUG("SelectionNue2018FHC")
249  << "passed ptp cuts"
250  << "\nMinTopDist: " << params.ShowerMaxY() << " " << fVeryFarBoundary
251  << "\nMinTopDist: " << params.ShowerMaxY() << " " << fFarCloseBoundary
252  << "\nShowerPt: " << params.ShowerPt() << " " << fMaxTransverseMomentumFar
253  << "\nShowerPt: " << params.ShowerPt() << " " << fMaxTransverseMomentumClose;
254 
255  // check the containment
256  if(params.DistAllTop() <= fFDDistAllTop ||
257  params.DistAllBottom() <= fFDDistAllBottom ||
258  params.DistAllWest() <= fFDDistAllWest ||
259  params.DistAllEast() <= fFDDistAllEast ||
260  params.DistAllFront() <= fFDDistAllFront ||
261  params.DistAllBack() <= fFDDistAllBack ){
262  LOG_DEBUG("SelectionNue2018FHC")
263  << "failed containment"
264  << "\nDistAllTop: " << params.DistAllTop() << " " << fFDDistAllTop
265  << "\nDistAllBottom: " << params.DistAllBottom() << " " << fFDDistAllBottom
266  << "\nDistAllWest: " << params.DistAllWest() << " " << fFDDistAllWest
267  << "\nDistAllEast: " << params.DistAllEast() << " " << fFDDistAllEast
268  << "\nDistAllFront: " << params.DistAllFront() << " " << fFDDistAllFront
269  << "\nDistAllBack: " << params.DistAllBack() << " " << fFDDistAllBack;
270 
271  return false;
272  }
273  LOG_DEBUG("SelectionNue2018FHC")
274  << "passed containment"
275  << "\nDistAllTop: " << params.DistAllTop() << " " << fFDDistAllTop
276  << "\nDistAllBottom: " << params.DistAllBottom() << " " << fFDDistAllBottom
277  << "\nDistAllWest: " << params.DistAllWest() << " " << fFDDistAllWest
278  << "\nDistAllEast: " << params.DistAllEast() << " " << fFDDistAllEast
279  << "\nDistAllFront: " << params.DistAllFront() << " " << fFDDistAllFront
280  << "\nDistAllBack: " << params.DistAllBack() << " " << fFDDistAllBack;
281 
282  // FD backward cosmic photon rejection cut
283  if(params.DistAllBack() < fFDMaxDistAllBack &&
284  params.SparsenessAsymm() >= fFDMaxSparsenessAsymm ){
285  LOG_DEBUG("SelectionNue2018FHC")
286  << "failed backward cosmic photon rejection cut"
287  << "\nDistAllBack: " << params.DistAllBack() << " " << fFDMaxDistAllBack
288  << "\nSparsenessAsymm: " << params.SparsenessAsymm() << " " << fFDMaxSparsenessAsymm;
289 
290  return false;
291  }
292  LOG_DEBUG("SelectionNue2018FHC")
293  << "passed backward cosmic photon rejection cut"
294  << "\nDistAllBack: " << params.DistAllBack() << " " << fFDMaxDistAllBack
295  << "\nSparsenessAsymm: " << params.SparsenessAsymm() << " " << fFDMaxSparsenessAsymm;
296 
297 
298  //FD Nerest Slice
299  if( params.CVNVal() > fMinCVNVal &&
300  params.CVNVal() < fFDClosestSliceCVNBoundary &&
301  params.ClosestSliceTime() > fFDClosestSliceTimeBefore &&
302  params.ClosestSliceTime() < fFDClosestSliceTimeAfter &&
303  params.ClosestSliceMinDist() < fFDClosestSliceMinDist &&
304  params.ClosestSliceDistFromTop() < fFDClosestSliceLowCVNTopDist ){
305 
306  LOG_DEBUG("SelectionNue2018FHC")
307  << "failed nearest slice cut"
308  << "\nMinCVNVal " << params.CVNVal() << " " << fMinCVNVal
309  << "\nFDClosestSliceCVNBoundary " << params.CVNVal() << " " << fFDClosestSliceCVNBoundary
310  << "\nFDClosestSliceTimeBefore " << params.ClosestSliceTime() << " " << fFDClosestSliceTimeBefore
311  << "\nFDClosestSliceTimeAfter " << params.ClosestSliceTime() << " " << fFDClosestSliceTimeAfter
312  << "\nFDClosestSliceMinDist " << params.ClosestSliceMinDist() << " " << fFDClosestSliceMinDist
313  << "\nFDClosestSliceLowCVNTopDist " << params.ClosestSliceDistFromTop() << " " << fFDClosestSliceLowCVNTopDist;
314 
315  return false;
316  }
317  LOG_DEBUG("SelectionNue2018FHC")
318  << "passed nearest slice cut"
319  << "\nMinCVNVal " << params.CVNVal() << " " << fMinCVNVal
320  << "\nFDClosestSliceCVNBoundary " << params.CVNVal() << " " << fFDClosestSliceCVNBoundary
321  << "\nFDClosestSliceTimeBefore " << params.ClosestSliceTime() << " " << fFDClosestSliceTimeBefore
322  << "\nFDClosestSliceTimeAfter " << params.ClosestSliceTime() << " " << fFDClosestSliceTimeAfter
323  << "\nFDClosestSliceMinDist " << params.ClosestSliceMinDist() << " " << fFDClosestSliceMinDist
324  << "\nFDClosestSliceLowCVNTopDist " << params.ClosestSliceDistFromTop() << " " << fFDClosestSliceLowCVNTopDist;
325 
326  if( params.CVNVal() > fFDClosestSliceCVNBoundary &&
327  params.ClosestSliceTime() > fFDClosestSliceTimeBefore &&
328  params.ClosestSliceTime() < fFDClosestSliceTimeAfter &&
329  params.ClosestSliceMinDist() < fFDClosestSliceMinDist &&
330  params.ClosestSliceDistFromTop() < fFDClosestSliceHighCVNTopDist ){
331 
332  LOG_DEBUG("SelectionNue2018FHC")
333  << "failed nearest slice cut"
334  << "\nFDClosestSliceCVNBoundary " << params.CVNVal() << fFDClosestSliceCVNBoundary
335  << "\nFDClosestSliceTimeBefore " << params.ClosestSliceTime() << fFDClosestSliceTimeBefore
336  << "\nFDClosestSliceTimeAfter " << params.ClosestSliceTime() << fFDClosestSliceTimeAfter
337  << "\nFDClosestSliceMinDist " << params.ClosestSliceMinDist() << fFDClosestSliceMinDist
338  << "\nFDClosestSliceHighCVNTopDist " << params.ClosestSliceDistFromTop() << fFDClosestSliceHighCVNTopDist;
339 
340  return false;
341  }
342  LOG_DEBUG("SelectionNue2018FHC")
343  << "passed nearest slice cut"
344  << "\nFDClosestSliceCVNBoundary " << params.CVNVal() << fFDClosestSliceCVNBoundary
345  << "\nFDClosestSliceTimeBefore " << params.ClosestSliceTime() << fFDClosestSliceTimeBefore
346  << "\nFDClosestSliceTimeAfter " << params.ClosestSliceTime() << fFDClosestSliceTimeAfter
347  << "\nFDClosestSliceMinDist " << params.ClosestSliceMinDist() << fFDClosestSliceMinDist
348  << "\nFDClosestSliceHighCVNTopDist " << params.ClosestSliceDistFromTop() << fFDClosestSliceHighCVNTopDist;
349 
350  // cosmic veto cut
351  if (!params.VetoKeepNue()){
352  LOG_DEBUG("SelectionNue2018FHC")
353  << "failed cosmic veto cut"
354  << "\nVetoKeepNue: " << params.VetoKeepNue() ;
355  return false;
356  }
357  LOG_DEBUG("SelectionNue2018FHC")
358  << "passed cosmic veto cut"
359  << "\nVetoKeepNue: " << params.VetoKeepNue() ;
360 
361  return true;
362 }
float fVeryFarBoundary
distance at which we are very far from the top of detector
#define LOG_DEBUG(stream)
Definition: Messenger.h:149
float fFDDistAllBottom
minimum distance to the bottom wall
float fMinCVNVal
min cvn value optimised on S/sqrt(B)
float fMaxTransverseMomentumClose
maximum transverse momentum when close to top of detector
bool PassesPreselection(skim::ParametersNue const &params)
float fFDMaxSparsenessAsymm
maximum asymmetry in the zero-hit planes at the start and end of the shower
float fFDMaxSliceHits
maximum number of hits required in FD slices.
float fFDClosestSliceLowCVNTopDist
minimum distance from top for closest slice ( 0.75 < CVN < 0.87 )
float fFDMaxProngLength
maximum length of longest prong
float fFDClosestSliceTimeBefore
closest time distance allowed for previous slice
float fFDMinProngLength
minimum length of longest prong
float fFDClosestSliceTimeAfter
closest time distance allowed for next slice
float fFDMaxDistAllBack
maximum distance to the back wall
float fFDDistAllFront
minimum distance to the front wall
float fFDDistAllEast
minimum distance to the east wall
float fFDClosestSliceCVNBoundary
CVN boundary for closest slice check.
float fFDDistAllWest
minimum distance to the west wall
float fFDMinSliceHits
minimum number of hits required in FD slices.
float fFDClosestSliceHighCVNTopDist
minimum distance from top for closest slice ( CVN > 0.87 )
float fFarCloseBoundary
distance at which we are no longer close to top of detector
float fFDDistAllTop
minimum distance to the top wall
float fMaxTransverseMomentumFar
maximum transverse momentum when away from top of detector
float fFDClosestSliceMinDist
minimum distance for closest slice
float fFDDistAllBack
minimum distance to the back wall
bool skim::SelectionNue2018FHC::KeepNueNearDetectorSlice ( skim::ParametersNue const &  params)
private

Definition at line 365 of file SelectionNue2018FHC.cxx.

References std::abs(), fNDMaxProngLength, fNDMaxShowerW, fNDMaxShowerZ, fNDMaxSliceHits, fNDMaxVertexX, fNDMaxVertexY, fNDMaxVertexZ, fNDMinPlanesToFront, fNDMinProngLength, fNDMinShowerZ, fNDMinSliceHits, fNDMinVertexX, fNDMinVertexY, fNDMinVertexZ, LOG_DEBUG, std::max(), PassesPreselection(), skim::ParametersNue::PlanesToFront(), skim::ParametersNue::ProngLength(), skim::ParametersNue::ShowerMaxEndZ(), skim::ParametersNue::ShowerMaxVtxZ(), skim::ParametersNue::ShowerMaxX(), skim::ParametersNue::ShowerMaxY(), skim::ParametersNue::ShowerMinEndZ(), skim::ParametersNue::ShowerMinVtxZ(), skim::ParametersNue::ShowerMinX(), skim::ParametersNue::ShowerMinY(), skim::ParametersNue::SliceHits(), and skim::ParametersNue::Vertex().

Referenced by PassesSelection().

366 {
367 
368  if(!this->PassesPreselection(params)) return false;
369 
370  // cuts based on slice info
371  if(params.PlanesToFront() < fNDMinPlanesToFront ||
372  params.SliceHits() < fNDMinSliceHits ||
373  params.SliceHits() > fNDMaxSliceHits
374  // params.NueEnergy() > fNDMaxNueEnergy ||
375  // params.NueEnergy() < fNDMinNueEnergy
376  ){
377  LOG_DEBUG("SelectionNue2018FHC")
378  << "failed Cells/Calorimetry"
379  << "\nPlanesToFront: " << params.PlanesToFront() << " " << fNDMinPlanesToFront
380  << "\nSliceHits: " << params.SliceHits() << " " << fNDMinSliceHits
381  << "\nSliceHits: " << params.SliceHits() << " " << fNDMaxSliceHits;
382 
383  return false;
384  }
385 
386 
387  // cuts based on the showers - we already checked the number of showers
388  // in the KeepSlice method, so don't bother doing it again
389  if(params.ProngLength() < fNDMinProngLength ||
390  params.ProngLength() > fNDMaxProngLength ){
391  LOG_DEBUG("SelectionNue2018FHC")
392  << "failed shower length cuts"
393  << "\nProngLength: " << params.ProngLength() << " " << fNDMaxProngLength
394  << "\nProngLength: " << params.ProngLength() << " " << fNDMinProngLength;
395 
396  return false;
397  }
398 
399 
400  float maxW = std::max(std::max(std::abs(params.ShowerMaxX()), std::abs(params.ShowerMinX())),
401  std::max(std::abs(params.ShowerMaxY()), std::abs(params.ShowerMinY())));
402 
403 
404  // check the containment
405  if(params.Vertex().X() < fNDMinVertexX ||
406  params.Vertex().X() > fNDMaxVertexX ||
407  params.Vertex().Y() < fNDMinVertexY ||
408  params.Vertex().Y() > fNDMaxVertexY ||
409  params.Vertex().Z() < fNDMinVertexZ ||
410  params.Vertex().Z() > fNDMaxVertexZ ||
411  maxW > fNDMaxShowerW ||
412  params.ShowerMinVtxZ() < fNDMinShowerZ ||
413  params.ShowerMinEndZ() < fNDMinShowerZ ||
414  params.ShowerMaxVtxZ() > fNDMaxShowerZ ||
415  params.ShowerMaxEndZ() > fNDMaxShowerZ){
416  LOG_DEBUG("SelectionNue2018FHC")
417  << "failed containment cuts"
418  << "\nVertexX: " << params.Vertex().X() << " " << fNDMinVertexX
419  << "\nVertexX: " << params.Vertex().X() << " " << fNDMaxVertexX
420  << "\nVertexY: " << params.Vertex().Y() << " " << fNDMinVertexY
421  << "\nVertexY: " << params.Vertex().Y() << " " << fNDMaxVertexY
422  << "\nVertexZ: " << params.Vertex().Z() << " " << fNDMinVertexZ
423  << "\nVertexZ: " << params.Vertex().Z() << " " << fNDMaxVertexZ
424  << "\nShowerMaxX: " << params.ShowerMaxX() << " " << fNDMaxShowerW
425  << "\nShowerMaxY: " << params.ShowerMaxY() << " " << fNDMaxShowerW
426  << "\nmaxW: " << maxW << " " << fNDMaxShowerW
427  << "\nShowerMinVtxZ: " << params.ShowerMinVtxZ() << " " << fNDMinShowerZ
428  << "\nShowerMinEndZ: " << params.ShowerMinEndZ() << " " << fNDMinShowerZ
429  << "\nShowerMaxVtxZ: " << params.ShowerMaxVtxZ() << " " << fNDMaxShowerZ
430  << "\nShowerMaxEndZ: " << params.ShowerMaxEndZ() << " " << fNDMaxShowerZ;
431 
432  return false;
433  }
434 
435  return true;
436 }
T max(const caf::Proxy< T > &a, T b)
#define LOG_DEBUG(stream)
Definition: Messenger.h:149
bool PassesPreselection(skim::ParametersNue const &params)
float abs(float number)
Definition: d0nt_math.hpp:39
SelectionNue2018FHC& skim::SelectionNue2018FHC::operator= ( SelectionNue2018FHC const &  )
delete
SelectionNue2018FHC& skim::SelectionNue2018FHC::operator= ( SelectionNue2018FHC &&  )
delete
bool skim::SelectionNue2018FHC::PassesPreselection ( skim::ParametersNue const &  params)
private

Definition at line 181 of file SelectionNue2018FHC.cxx.

References skim::ParametersNue::CellsPerPlane(), fSliceHitsPerPlane, and LOG_DEBUG.

Referenced by KeepNueFarDetectorSlice(), and KeepNueNearDetectorSlice().

182 {
183 
184  if(params.CellsPerPlane() >= fSliceHitsPerPlane ){
185  LOG_DEBUG("SelectionNue2018FHC")
186  << "failed preselection cuts"
187  << "\nCellsPerPlane: " << params.CellsPerPlane() << " " << fSliceHitsPerPlane;
188  return false;
189  }
190 
191  LOG_DEBUG("SelectionNue2018FHC")
192  << "passed preselection cuts"
193  << "\nCellsPerPlane: " << params.CellsPerPlane() << " " << fSliceHitsPerPlane;
194  return true;
195 }
#define LOG_DEBUG(stream)
Definition: Messenger.h:149
float fSliceHitsPerPlane
maximum number of hits per plane in a slice
bool skim::SelectionNue2018FHC::PassesSelection ( skim::Parameters pars,
novadaq::cnv::DetId const &  detId 
)
virtual

Implements skim::SelectionBase.

Definition at line 142 of file SelectionNue2018FHC.cxx.

References CheckSlicePID(), KeepNueFarDetectorSlice(), KeepNueNearDetectorSlice(), novadaq::cnv::kFARDET, novadaq::cnv::kNEARDET, and LOG_DEBUG.

144 {
145  LOG_DEBUG("SelectionNue2018FHC")
146  << "Inside SelectionNue2018FHC::PassesSelection";
147 
148  skim::ParametersNue *params = dynamic_cast<skim::ParametersNue*>(pars);
149 
150  // check the PID values
151  if( !this->CheckSlicePID(*params) ) return false;
152 
153  // if the nue criteria are satified, keep the slice
154  if (detId == novadaq::cnv::kFARDET) return this->KeepNueFarDetectorSlice (*params);
155  else if(detId == novadaq::cnv::kNEARDET) return this->KeepNueNearDetectorSlice(*params);
156 
157  return false;
158 
159 }
#define LOG_DEBUG(stream)
Definition: Messenger.h:149
bool CheckSlicePID(skim::ParametersNue const &params)
bool KeepNueFarDetectorSlice(skim::ParametersNue const &params)
Far Detector at Ash River, MN.
Near Detector in the NuMI cavern.
bool KeepNueNearDetectorSlice(skim::ParametersNue const &params)
void skim::SelectionNue2018FHC::reconfigure ( fhicl::ParameterSet const &  p)
virtual

Implements skim::SelectionBase.

Definition at line 17 of file SelectionNue2018FHC.cxx.

References fFarCloseBoundary, fFDClosestSliceCVNBoundary, fFDClosestSliceHighCVNTopDist, fFDClosestSliceLowCVNTopDist, fFDClosestSliceMinDist, fFDClosestSliceTimeAfter, fFDClosestSliceTimeBefore, fFDDistAllBack, fFDDistAllBottom, fFDDistAllEast, fFDDistAllFront, fFDDistAllTop, fFDDistAllWest, fFDMaxDistAllBack, fFDMaxNueEnergy, fFDMaxProngLength, fFDMaxSliceHits, fFDMaxSparsenessAsymm, fFDMinNueEnergy, fFDMinProngLength, fFDMinSliceHits, fMaxTransverseMomentumClose, fMaxTransverseMomentumFar, fMinCVNVal, fNDMaxNueEnergy, fNDMaxProngLength, fNDMaxShowerW, fNDMaxShowerZ, fNDMaxSliceHits, fNDMaxVertexX, fNDMaxVertexY, fNDMaxVertexZ, fNDMinNueEnergy, fNDMinPlanesToFront, fNDMinProngLength, fNDMinShowerZ, fNDMinSliceHits, fNDMinVertexX, fNDMinVertexY, fNDMinVertexZ, fSliceHitsPerPlane, fVeryFarBoundary, and fhicl::ParameterSet::get().

18 {
19 
20 
21  /*******
22  ///////////////////////// FD ///////////////////////////////////////////////////////////////
23 
24  const Cut kNue2018FD = kNue2018CorePresel && kNue2018CVNCut && kNearestSliceCosRej2018;
25 
26  const Cut kNue2018CorePresel = kNue2017BasicPart && kNue2018CorePart;
27 
28  const Cut kNue2018CorePart =
29  kNue2018Presel && //<<<<< Changes the Energy variable Cut,
30  // presently not used in the skimmer. All the rest is the same.
31  kNue2017ProngContainment &&
32  kNue2017PtPCutCVN &&
33  kNue2017BackwardCut;
34 
35 
36  const Cut kNue2018FHCCVNCut = kCVNSSe >= kNue2018CVNFHCLowEdge; --> 0.84
37  const Var kCVNSSe([](const caf::SRProxy* sr){return sr->sel.cvnProd3Train.nueid;});
38 
39  const Cut kNearestSliceCosRej2018([](const caf::SRProxy* sr) { ///<<< different cvn variable. Missing : kNue2017CorePresel(sr) && sr->sel.cvn.nueid > 0.75 , which are redundant anyway.
40  /// depends on FHC vs RHC
41  const double topcut = (kCVNSSe(sr) >= hibin) ? 50 : 400; // highbin = 0.96 for FHC
42  return (fabs(sr->slc.closestslicetime) >= 100 ||
43  sr->slc.closestsliceminfromtop >= topcut ||
44  sr->slc.closestslicemindist >= 500);
45 
46  ////////////////// //////////////// ND ///////////////////////////////////////////////////////////////
47 
48 
49  const Cut kNue2018NDCVNSsb = kNue2018NDPresel && kNue2018CVNCut;
50 
51  const Cut kNue2018NDEnergy = kNueEnergy2018 < 4.5; // Not presently used in Skimmer
52 
53  const Cut kNue2018NDPresel = kNueDQ2017CVN && <<<<<<<< const Cut kNue2017NDPresel = kNueDQ2017CVN &&
54  kNue2017NDFiducial && kNue2017NDFiducial &&
55  kNue2017NDContain && kNue2017NDContain &&
56  kNue2017NDFrontPlanes && kNue2017NDFrontPlanes &&
57  kNue2017NDNHits && kNue2017NDNHits &&
58  kNue2018NDEnergy && <<<<<<<< kNue2017NDEnergy &&
59  kNue2017NDProngLength; kNue2017NDProngLength;
60 
61 
62 
63 
64  *******/
65 
66  // Pt/P kNue2017PtPCutCVN
67  fFarCloseBoundary = p.get<float>("FarCloseBoundary", 590. ); // ok
68  fVeryFarBoundary = p.get<float>("VeryFarBoundary", 350. ); // ok
69  fMaxTransverseMomentumClose = p.get<float>("MaxTransverseMomentumClose", 0.58 ); // ok
70  fMaxTransverseMomentumFar = p.get<float>("MaxTransverseMomentumFar", 0.80 ); // ok
71 
72  // kNueDQ2017CVN
73  fSliceHitsPerPlane = p.get<float>("SliceHitsPerPlane", 8. ); //
74 
75  // kNue2017CVNCut
76  fMinCVNVal = p.get<float>("MinCVNVal", 0.84 ); // ok
77 
78  // FD specific Cuts
79  //Preselection (kNue2017Presel)
80  fFDMinSliceHits = p.get<float>("FDMinSliceHits", 31. ); // ok
81  fFDMaxSliceHits = p.get<float>("FDMaxSliceHits", 149. ); // ok
82  fFDMaxProngLength = p.get<float>("FDMaxProngLength", 500. ); // ok
83  fFDMinProngLength = p.get<float>("FDMinProngLength", 100. ); // ok
84  //------------> Energy Cut Not Applied
85  fFDMaxNueEnergy = p.get<float>("FDMaxNueEnergy", 3. ); //
86  fFDMinNueEnergy = p.get<float>("FDMinNueEnergy", 1. ); //
87  //<------------
88 
89  // Containment kNue2017ProngContainment
90  fFDDistAllEast = p.get<float>("FDDistAllEast", 12. ); // ok
91  fFDDistAllWest = p.get<float>("FDDistAllWest", 12. ); // ok
92  fFDDistAllTop = p.get<float>("FDDistAllTop", 63. ); // ok
93  fFDDistAllBottom = p.get<float>("FDDistAllBottom", 12. ); // ok
94  fFDDistAllFront = p.get<float>("FDDistAllFront", 18. ); // ok
95  fFDDistAllBack = p.get<float>("FDDistAllBack", 18. ); // ok
96 
97  //kNearestSlice ...
98  fFDClosestSliceTimeBefore = p.get<float>("FDClosestSliceTimeBefore", -100); // ok
99  fFDClosestSliceTimeAfter = p.get<float>("FDClosestSliceTimeAfter", 100); // ok
100  fFDClosestSliceHighCVNTopDist = p.get<float>("FDClosestSliceHighCVNTopDist", 50); // ok
101  fFDClosestSliceLowCVNTopDist = p.get<float>("FDClosestSliceLowCVNTopDist", 400); // ok
102  fFDClosestSliceMinDist = p.get<float>("FDClosestSliceMinDist", 500); // ok
103  fFDClosestSliceCVNBoundary = p.get<float>("FDClosestSliceCVNBoundary", 0.96); // ok
104 
105 
106  // Backward Photon kNue2017BackwardCut
107  fFDMaxDistAllBack = p.get<float>("FDMaxDistAllBack", 200. ); // ok
108  fFDMaxSparsenessAsymm = p.get<float>("FDMaxSparsenessAsymm", -0.1 ); // ok
109 
110  // ND specific -------------------------------------------------------
111  // kNue2017NDFiducial
112  fNDMaxVertexX = p.get<float>("NDMaxVertexX", 160. ); // ok
113  fNDMinVertexX = p.get<float>("NDMinVertexX", -100. ); // ok
114  fNDMaxVertexY = p.get<float>("NDMaxVertexY", 100. ); // ok
115  fNDMinVertexY = p.get<float>("NDMinVertexY", -160. ); // ok
116  fNDMaxVertexZ = p.get<float>("NDMaxVertexZ", 900. ); // ok
117  fNDMinVertexZ = p.get<float>("NDMinVertexZ", 150. ); // ok
118 
119  // kNue2017NDContain : Containment cuts
120  fNDMaxShowerW = p.get<float>("NDMaxShowerW", 170. ); // ok
121  fNDMinShowerZ = p.get<float>("NDMinShowerZ", 100. ); // ok
122  fNDMaxShowerZ = p.get<float>("NDMaxShowerZ", 1225.); // ok
123 
124  // kNue2017NDNHits
125  fNDMinSliceHits = p.get<float>("NDMinSliceHits", 20. ); // ok
126  fNDMaxSliceHits = p.get<float>("NDMaxSliceHits", 200. ); // ok
127 
128  fNDMaxNueEnergy = p.get<float>("NDMaxNueEnergy", 5. ); // Not Used
129  fNDMinNueEnergy = p.get<float>("fNDMinNueEnergy", 0. ); // Not Used
130 
131  // kNue2017NDProngLength
132  fNDMaxProngLength = p.get<float>("NDMaxProngLength", 500. );
133  fNDMinProngLength = p.get<float>("NDMinProngLength", 100. );
134 
135  // kNue2017NDFrontPlanes
136  fNDMinPlanesToFront = p.get<unsigned int>("NDMinPlanesToFront", 7 ); // ok
137 
138  return;
139 }
float fVeryFarBoundary
distance at which we are very far from the top of detector
float fSliceHitsPerPlane
maximum number of hits per plane in a slice
float fFDDistAllBottom
minimum distance to the bottom wall
float fMinCVNVal
min cvn value optimised on S/sqrt(B)
float fMaxTransverseMomentumClose
maximum transverse momentum when close to top of detector
const char * p
Definition: xmltok.h:285
float fFDMaxSparsenessAsymm
maximum asymmetry in the zero-hit planes at the start and end of the shower
float fFDMaxSliceHits
maximum number of hits required in FD slices.
float fFDClosestSliceLowCVNTopDist
minimum distance from top for closest slice ( 0.75 < CVN < 0.87 )
float fFDMaxNueEnergy
max NueEnergy at FD
float fFDMaxProngLength
maximum length of longest prong
float fFDClosestSliceTimeBefore
closest time distance allowed for previous slice
float fFDMinProngLength
minimum length of longest prong
float fFDClosestSliceTimeAfter
closest time distance allowed for next slice
float fFDMaxDistAllBack
maximum distance to the back wall
float fFDDistAllFront
minimum distance to the front wall
float fFDDistAllEast
minimum distance to the east wall
float fFDClosestSliceCVNBoundary
CVN boundary for closest slice check.
float fFDDistAllWest
minimum distance to the west wall
float fFDMinNueEnergy
min NueEnergy at FD
float fFDMinSliceHits
minimum number of hits required in FD slices.
float fFDClosestSliceHighCVNTopDist
minimum distance from top for closest slice ( CVN > 0.87 )
float fFarCloseBoundary
distance at which we are no longer close to top of detector
float fFDDistAllTop
minimum distance to the top wall
float fMaxTransverseMomentumFar
maximum transverse momentum when away from top of detector
float fFDClosestSliceMinDist
minimum distance for closest slice
float fFDDistAllBack
minimum distance to the back wall

Member Data Documentation

float skim::SelectionNue2018FHC::fFarCloseBoundary
private

distance at which we are no longer close to top of detector

Definition at line 69 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDClosestSliceCVNBoundary
private

CVN boundary for closest slice check.

Definition at line 90 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDClosestSliceHighCVNTopDist
private

minimum distance from top for closest slice ( CVN > 0.87 )

Definition at line 87 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDClosestSliceLowCVNTopDist
private

minimum distance from top for closest slice ( 0.75 < CVN < 0.87 )

Definition at line 88 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDClosestSliceMinDist
private

minimum distance for closest slice

Definition at line 89 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDClosestSliceTimeAfter
private

closest time distance allowed for next slice

Definition at line 86 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDClosestSliceTimeBefore
private

closest time distance allowed for previous slice

Definition at line 85 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDDistAllBack
private

minimum distance to the back wall

Definition at line 66 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDDistAllBottom
private

minimum distance to the bottom wall

Definition at line 62 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDDistAllEast
private

minimum distance to the east wall

Definition at line 64 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDDistAllFront
private

minimum distance to the front wall

Definition at line 65 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDDistAllTop
private

minimum distance to the top wall

Definition at line 61 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDDistAllWest
private

minimum distance to the west wall

Definition at line 63 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDMaxDistAllBack
private

maximum distance to the back wall

Definition at line 68 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDMaxNueEnergy
private

max NueEnergy at FD

Definition at line 78 of file SelectionNue2018FHC.h.

Referenced by reconfigure().

float skim::SelectionNue2018FHC::fFDMaxProngLength
private

maximum length of longest prong

Definition at line 83 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDMaxSliceHits
private

maximum number of hits required in FD slices.

Definition at line 75 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDMaxSparsenessAsymm
private

maximum asymmetry in the zero-hit planes at the start and end of the shower

Definition at line 67 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDMinNueEnergy
private

min NueEnergy at FD

Definition at line 79 of file SelectionNue2018FHC.h.

Referenced by reconfigure().

float skim::SelectionNue2018FHC::fFDMinProngLength
private

minimum length of longest prong

Definition at line 84 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fFDMinSliceHits
private

minimum number of hits required in FD slices.

Definition at line 74 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fMaxTransverseMomentumClose
private

maximum transverse momentum when close to top of detector

Definition at line 71 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fMaxTransverseMomentumFar
private

maximum transverse momentum when away from top of detector

Definition at line 72 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fMinCVNVal
private

min cvn value optimised on S/sqrt(B)

Definition at line 82 of file SelectionNue2018FHC.h.

Referenced by CheckSlicePID(), KeepNueFarDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMaxNueEnergy
private

Definition at line 105 of file SelectionNue2018FHC.h.

Referenced by reconfigure().

float skim::SelectionNue2018FHC::fNDMaxProngLength
private

Definition at line 107 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMaxShowerW
private

Definition at line 99 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMaxShowerZ
private

Definition at line 101 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMaxSliceHits
private

Definition at line 103 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMaxVertexX
private

Definition at line 93 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMaxVertexY
private

Definition at line 95 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMaxVertexZ
private

Definition at line 97 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMinNueEnergy
private

Definition at line 106 of file SelectionNue2018FHC.h.

Referenced by reconfigure().

unsigned int skim::SelectionNue2018FHC::fNDMinPlanesToFront
private

Definition at line 109 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMinProngLength
private

Definition at line 108 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMinShowerZ
private

Definition at line 100 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMinSliceHits
private

Definition at line 102 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMinVertexX
private

Definition at line 94 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMinVertexY
private

Definition at line 96 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fNDMinVertexZ
private

Definition at line 98 of file SelectionNue2018FHC.h.

Referenced by KeepNueNearDetectorSlice(), and reconfigure().

float skim::SelectionNue2018FHC::fSliceHitsPerPlane
private

maximum number of hits per plane in a slice

Definition at line 73 of file SelectionNue2018FHC.h.

Referenced by PassesPreselection(), and reconfigure().

float skim::SelectionNue2018FHC::fVeryFarBoundary
private

distance at which we are very far from the top of detector

Definition at line 70 of file SelectionNue2018FHC.h.

Referenced by KeepNueFarDetectorSlice(), and reconfigure().


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