CMS 3D CMS Logo

Classes | Functions | Variables
cutBasedElectronID_tools Namespace Reference

Classes

class  EleHLTSelection_V1
 
class  EleWorkingPoint_V1
 
class  EleWorkingPoint_V2
 
class  EleWorkingPoint_V3
 
class  IsolationCutInputs_V2
 

Functions

def configureVIDCutBasedEleHLTPreselection_V1 (wpEB, wpEE, ecalIsoInputs, hcalIsoInputs)
 
def configureVIDCutBasedEleID_V1 (wpEB, wpEE)
 
def configureVIDCutBasedEleID_V2 (wpEB, wpEE, isoInputs)
 
def configureVIDCutBasedEleID_V3 (wpEB, wpEE, isoInputs)
 
def psetConversionVetoCut ()
 
def psetDEtaInSeedCut (wpEB, wpEE)
 
def psetDPhiInCut (wpEB, wpEE)
 
def psetEcalPFClusterIsoCut (wpEB, wpEE, ecalIsoInputs)
 
def psetEffAreaPFIsoCut (wpEB, wpEE, isoInputs)
 
def psetEInerseMinusPInverseCut (wpEB, wpEE)
 
def psetHadronicOverEMCut (wpEB, wpEE)
 
def psetHcalPFClusterIsoCut (wpEB, wpEE, hcalIsoInputs)
 
def psetMinPtCut ()
 
def psetMissingHitsCut (wpEB, wpEE)
 
def psetNormalizedGsfChi2Cut (wpEB, wpEE)
 
def psetPhoFull5x5SigmaIEtaIEtaCut (wpEB, wpEE)
 
def psetPhoSCEtaMultiRangeCut ()
 
def psetTrkPtIsoCut (wpEB, wpEE)
 

Variables

 ebCutOff
 

Function Documentation

def cutBasedElectronID_tools.configureVIDCutBasedEleHLTPreselection_V1 (   wpEB,
  wpEE,
  ecalIsoInputs,
  hcalIsoInputs 
)
This function configures the full cms.PSet for a VID ID and returns it.
The inputs: two objects of the type EleHLTSelection_V1, one
containing the cuts for the Barrel (EB) and the other one for the Endcap (EE).
The third and fourth arguments are objects that contain information necessary
for isolation calculations for ECAL and HCAL.

Definition at line 599 of file cutBasedElectronID_tools.py.

References psetDEtaInSeedCut(), psetDPhiInCut(), psetEcalPFClusterIsoCut(), psetEInerseMinusPInverseCut(), psetHadronicOverEMCut(), psetHcalPFClusterIsoCut(), psetMinPtCut(), psetNormalizedGsfChi2Cut(), psetPhoFull5x5SigmaIEtaIEtaCut(), psetPhoSCEtaMultiRangeCut(), and psetTrkPtIsoCut().

599 def configureVIDCutBasedEleHLTPreselection_V1( wpEB, wpEE, ecalIsoInputs, hcalIsoInputs ):
600  """
601  This function configures the full cms.PSet for a VID ID and returns it.
602  The inputs: two objects of the type EleHLTSelection_V1, one
603  containing the cuts for the Barrel (EB) and the other one for the Endcap (EE).
604  The third and fourth arguments are objects that contain information necessary
605  for isolation calculations for ECAL and HCAL.
606  """
607  # print "VID: Configuring cut set %s" % wpEB.idName
608  parameterSet = cms.PSet(
609  idName = cms.string( wpEB.idName ), # same name stored in the _EB and _EE objects
610  cutFlow = cms.VPSet(
611  psetMinPtCut(), # min pt cut
612  psetPhoSCEtaMultiRangeCut(), # eta cut
613  psetPhoFull5x5SigmaIEtaIEtaCut(wpEB, wpEE), # full 5x5 sigmaIEtaIEta cut
614  psetDEtaInSeedCut(wpEB, wpEE), # dEtaIn seed cut
615  psetDPhiInCut(wpEB, wpEE), # dPhiIn cut
616  psetHadronicOverEMCut(wpEB, wpEE), # H/E cut
617  psetEInerseMinusPInverseCut(wpEB, wpEE), # |1/e-1/p| cut
618  psetEcalPFClusterIsoCut(wpEB, wpEE, ecalIsoInputs), # ECAL PF Cluster isolation
619  psetHcalPFClusterIsoCut(wpEB, wpEE, hcalIsoInputs), # HCAL PF Cluster isolation
620  psetTrkPtIsoCut(wpEB, wpEE), # tracker isolation cut
621  psetNormalizedGsfChi2Cut(wpEB, wpEE) # GsfTrack chi2/NDOF cut
622  )
623  )
624  #
625  return parameterSet
626 
627 
def psetEcalPFClusterIsoCut(wpEB, wpEE, ecalIsoInputs)
def psetHcalPFClusterIsoCut(wpEB, wpEE, hcalIsoInputs)
def configureVIDCutBasedEleHLTPreselection_V1(wpEB, wpEE, ecalIsoInputs, hcalIsoInputs)
def psetPhoFull5x5SigmaIEtaIEtaCut(wpEB, wpEE)
def cutBasedElectronID_tools.configureVIDCutBasedEleID_V1 (   wpEB,
  wpEE 
)
This function configures the full cms.PSet for a VID ID and returns it.
The inputs: two objects of the type WorkingPoint_V1, one
containing the cuts for the Barrel (EB) and the other one for the Endcap (EE).

Definition at line 351 of file cutBasedElectronID_tools.py.

352  """
353  This function configures the full cms.PSet for a VID ID and returns it.
354  The inputs: two objects of the type WorkingPoint_V1, one
355  containing the cuts for the Barrel (EB) and the other one for the Endcap (EE).
356  """
357  # print "VID: Configuring cut set %s" % wpEB.idName
358  parameterSet = cms.PSet(
359  #
360  idName = cms.string( wpEB.idName ), # same name stored in the _EB and _EE objects
361  cutFlow = cms.VPSet(
362  cms.PSet( cutName = cms.string("MinPtCut"),
363  minPt = cms.double(5.0),
364  needsAdditionalProducts = cms.bool(False),
365  isIgnored = cms.bool(False) ),
366  cms.PSet( cutName = cms.string("GsfEleSCEtaMultiRangeCut"),
367  useAbsEta = cms.bool(True),
368  allowedEtaRanges = cms.VPSet(
369  cms.PSet( minEta = cms.double(0.0),
370  maxEta = cms.double(ebCutOff) ),
371  cms.PSet( minEta = cms.double(ebCutOff),
372  maxEta = cms.double(2.5) )
373  ),
374  needsAdditionalProducts = cms.bool(False),
375  isIgnored = cms.bool(False)),
376  cms.PSet( cutName = cms.string('GsfEleDEtaInCut'),
377  dEtaInCutValueEB = cms.double( wpEB.dEtaInCut ),
378  dEtaInCutValueEE = cms.double( wpEE.dEtaInCut ),
379  barrelCutOff = cms.double(ebCutOff),
380  needsAdditionalProducts = cms.bool(False),
381  isIgnored = cms.bool(False)),
382  cms.PSet( cutName = cms.string('GsfEleDPhiInCut'),
383  dPhiInCutValueEB = cms.double( wpEB.dPhiInCut ),
384  dPhiInCutValueEE = cms.double( wpEE.dPhiInCut ),
385  barrelCutOff = cms.double(ebCutOff),
386  needsAdditionalProducts = cms.bool(False),
387  isIgnored = cms.bool(False)),
388  cms.PSet( cutName = cms.string('GsfEleFull5x5SigmaIEtaIEtaCut'),
389  full5x5SigmaIEtaIEtaCutValueEB = cms.double( wpEB.full5x5_sigmaIEtaIEtaCut ),
390  full5x5SigmaIEtaIEtaCutValueEE = cms.double( wpEE.full5x5_sigmaIEtaIEtaCut ),
391  barrelCutOff = cms.double(ebCutOff),
392  needsAdditionalProducts = cms.bool(False),
393  isIgnored = cms.bool(False)),
394  cms.PSet( cutName = cms.string('GsfEleHadronicOverEMCut'),
395  hadronicOverEMCutValueEB = cms.double( wpEB.hOverECut ),
396  hadronicOverEMCutValueEE = cms.double( wpEE.hOverECut ),
397  barrelCutOff = cms.double(ebCutOff),
398  needsAdditionalProducts = cms.bool(False),
399  isIgnored = cms.bool(False)),
400  cms.PSet( cutName = cms.string('GsfEleDxyCut'),
401  dxyCutValueEB = cms.double( wpEB.dxyCut ),
402  dxyCutValueEE = cms.double( wpEE.dxyCut ),
403  vertexSrc = cms.InputTag("offlinePrimaryVertices"),
404  vertexSrcMiniAOD = cms.InputTag("offlineSlimmedPrimaryVertices"),
405  barrelCutOff = cms.double(ebCutOff),
406  needsAdditionalProducts = cms.bool(True),
407  isIgnored = cms.bool(False)),
408  cms.PSet( cutName = cms.string('GsfEleDzCut'),
409  dzCutValueEB = cms.double( wpEB.dzCut ),
410  dzCutValueEE = cms.double( wpEE.dzCut ),
411  vertexSrc = cms.InputTag("offlinePrimaryVertices"),
412  vertexSrcMiniAOD = cms.InputTag("offlineSlimmedPrimaryVertices"),
413  barrelCutOff = cms.double(ebCutOff),
414  needsAdditionalProducts = cms.bool(True),
415  isIgnored = cms.bool(False)),
416  cms.PSet( cutName = cms.string('GsfEleEInverseMinusPInverseCut'),
417  eInverseMinusPInverseCutValueEB = cms.double( wpEB.absEInverseMinusPInverseCut ),
418  eInverseMinusPInverseCutValueEE = cms.double( wpEE.absEInverseMinusPInverseCut ),
419  barrelCutOff = cms.double(ebCutOff),
420  needsAdditionalProducts = cms.bool(False),
421  isIgnored = cms.bool(False)),
422  cms.PSet( cutName = cms.string('GsfEleDeltaBetaIsoCutStandalone'),
423  isoCutEBLowPt = cms.double( wpEB.relCombIsolationWithDBetaLowPtCut ),
424  isoCutEBHighPt = cms.double( wpEB.relCombIsolationWithDBetaHighPtCut ),
425  isoCutEELowPt = cms.double( wpEE.relCombIsolationWithDBetaLowPtCut ),
426  isoCutEEHighPt = cms.double( wpEE.relCombIsolationWithDBetaHighPtCut ),
427  isRelativeIso = cms.bool(True),
428  deltaBetaConstant = cms.double(0.5),
429  ptCutOff = cms.double(20.0), # high pT above this value, low pT below
430  barrelCutOff = cms.double(ebCutOff),
431  needsAdditionalProducts = cms.bool(False),
432  isIgnored = cms.bool(False)),
433  cms.PSet( cutName = cms.string('GsfEleConversionVetoCut'),
434  conversionSrc = cms.InputTag('allConversions'),
435  conversionSrcMiniAOD = cms.InputTag('reducedEgamma:reducedConversions'),
436  beamspotSrc = cms.InputTag('offlineBeamSpot'),
437  needsAdditionalProducts = cms.bool(True),
438  isIgnored = cms.bool(False)),
439  cms.PSet( cutName = cms.string('GsfEleMissingHitsCut'),
440  maxMissingHitsEB = cms.uint32( wpEB.missingHitsCut ),
441  maxMissingHitsEE = cms.uint32( wpEE.missingHitsCut ),
442  barrelCutOff = cms.double(ebCutOff),
443  needsAdditionalProducts = cms.bool(False),
444  isIgnored = cms.bool(False) ),
445  )
446  )
447  #
448  return parameterSet
449 
450 # -----------------------------
451 # Version V2 common definitions
452 # -----------------------------
453 
454 # This cut set definition is in the old style, with everything configured
455 # in one go. It is kept to minimize changes. New definitions should use
456 # PSets defined above instead.
def configureVIDCutBasedEleID_V1(wpEB, wpEE)
def cutBasedElectronID_tools.configureVIDCutBasedEleID_V2 (   wpEB,
  wpEE,
  isoInputs 
)
This function configures the full cms.PSet for a VID ID and returns it.
The inputs: two objects of the type WorkingPoint_V2, one
containing the cuts for the Barrel (EB) and the other one for the Endcap (EE).
The third argument is an object that contains information necessary
for isolation calculations.

Definition at line 457 of file cutBasedElectronID_tools.py.

457 def configureVIDCutBasedEleID_V2( wpEB, wpEE, isoInputs ):
458  """
459  This function configures the full cms.PSet for a VID ID and returns it.
460  The inputs: two objects of the type WorkingPoint_V2, one
461  containing the cuts for the Barrel (EB) and the other one for the Endcap (EE).
462  The third argument is an object that contains information necessary
463  for isolation calculations.
464  """
465  # print "VID: Configuring cut set %s" % wpEB.idName
466  parameterSet = cms.PSet(
467  #
468  idName = cms.string( wpEB.idName ), # same name stored in the _EB and _EE objects
469  cutFlow = cms.VPSet(
470  cms.PSet( cutName = cms.string("MinPtCut"),
471  minPt = cms.double(5.0),
472  needsAdditionalProducts = cms.bool(False),
473  isIgnored = cms.bool(False) ),
474  cms.PSet( cutName = cms.string("GsfEleSCEtaMultiRangeCut"),
475  useAbsEta = cms.bool(True),
476  allowedEtaRanges = cms.VPSet(
477  cms.PSet( minEta = cms.double(0.0),
478  maxEta = cms.double(ebCutOff) ),
479  cms.PSet( minEta = cms.double(ebCutOff),
480  maxEta = cms.double(2.5) )
481  ),
482  needsAdditionalProducts = cms.bool(False),
483  isIgnored = cms.bool(False)),
484  cms.PSet( cutName = cms.string('GsfEleDEtaInCut'),
485  dEtaInCutValueEB = cms.double( wpEB.dEtaInCut ),
486  dEtaInCutValueEE = cms.double( wpEE.dEtaInCut ),
487  barrelCutOff = cms.double(ebCutOff),
488  needsAdditionalProducts = cms.bool(False),
489  isIgnored = cms.bool(False)),
490  cms.PSet( cutName = cms.string('GsfEleDPhiInCut'),
491  dPhiInCutValueEB = cms.double( wpEB.dPhiInCut ),
492  dPhiInCutValueEE = cms.double( wpEE.dPhiInCut ),
493  barrelCutOff = cms.double(ebCutOff),
494  needsAdditionalProducts = cms.bool(False),
495  isIgnored = cms.bool(False)),
496  cms.PSet( cutName = cms.string('GsfEleFull5x5SigmaIEtaIEtaCut'),
497  full5x5SigmaIEtaIEtaCutValueEB = cms.double( wpEB.full5x5_sigmaIEtaIEtaCut ),
498  full5x5SigmaIEtaIEtaCutValueEE = cms.double( wpEE.full5x5_sigmaIEtaIEtaCut ),
499  barrelCutOff = cms.double(ebCutOff),
500  needsAdditionalProducts = cms.bool(False),
501  isIgnored = cms.bool(False)),
502  cms.PSet( cutName = cms.string('GsfEleHadronicOverEMCut'),
503  hadronicOverEMCutValueEB = cms.double( wpEB.hOverECut ),
504  hadronicOverEMCutValueEE = cms.double( wpEE.hOverECut ),
505  barrelCutOff = cms.double(ebCutOff),
506  needsAdditionalProducts = cms.bool(False),
507  isIgnored = cms.bool(False)),
508  cms.PSet( cutName = cms.string('GsfEleDxyCut'),
509  dxyCutValueEB = cms.double( wpEB.dxyCut ),
510  dxyCutValueEE = cms.double( wpEE.dxyCut ),
511  vertexSrc = cms.InputTag("offlinePrimaryVertices"),
512  vertexSrcMiniAOD = cms.InputTag("offlineSlimmedPrimaryVertices"),
513  barrelCutOff = cms.double(ebCutOff),
514  needsAdditionalProducts = cms.bool(True),
515  isIgnored = cms.bool(False)),
516  cms.PSet( cutName = cms.string('GsfEleDzCut'),
517  dzCutValueEB = cms.double( wpEB.dzCut ),
518  dzCutValueEE = cms.double( wpEE.dzCut ),
519  vertexSrc = cms.InputTag("offlinePrimaryVertices"),
520  vertexSrcMiniAOD = cms.InputTag("offlineSlimmedPrimaryVertices"),
521  barrelCutOff = cms.double(ebCutOff),
522  needsAdditionalProducts = cms.bool(True),
523  isIgnored = cms.bool(False)),
524  cms.PSet( cutName = cms.string('GsfEleEInverseMinusPInverseCut'),
525  eInverseMinusPInverseCutValueEB = cms.double( wpEB.absEInverseMinusPInverseCut ),
526  eInverseMinusPInverseCutValueEE = cms.double( wpEE.absEInverseMinusPInverseCut ),
527  barrelCutOff = cms.double(ebCutOff),
528  needsAdditionalProducts = cms.bool(False),
529  isIgnored = cms.bool(False)),
530  cms.PSet( cutName = cms.string('GsfEleEffAreaPFIsoCut'),
531  isoCutEBLowPt = cms.double( wpEB.relCombIsolationWithEALowPtCut ),
532  isoCutEBHighPt = cms.double( wpEB.relCombIsolationWithEAHighPtCut ),
533  isoCutEELowPt = cms.double( wpEE.relCombIsolationWithEALowPtCut ),
534  isoCutEEHighPt = cms.double( wpEE.relCombIsolationWithEAHighPtCut ),
535  isRelativeIso = cms.bool(True),
536  ptCutOff = cms.double(20.0), # high pT above this value, low pT below
537  barrelCutOff = cms.double(ebCutOff),
538  rho = cms.InputTag("fixedGridRhoFastjetAll"),
539  effAreasConfigFile = cms.FileInPath( isoInputs.isoEffAreas ),
540  needsAdditionalProducts = cms.bool(True),
541  isIgnored = cms.bool(False) ),
542  cms.PSet( cutName = cms.string('GsfEleConversionVetoCut'),
543  conversionSrc = cms.InputTag('allConversions'),
544  conversionSrcMiniAOD = cms.InputTag('reducedEgamma:reducedConversions'),
545  beamspotSrc = cms.InputTag('offlineBeamSpot'),
546  needsAdditionalProducts = cms.bool(True),
547  isIgnored = cms.bool(False)),
548  cms.PSet( cutName = cms.string('GsfEleMissingHitsCut'),
549  maxMissingHitsEB = cms.uint32( wpEB.missingHitsCut ),
550  maxMissingHitsEE = cms.uint32( wpEE.missingHitsCut ),
551  barrelCutOff = cms.double(ebCutOff),
552  needsAdditionalProducts = cms.bool(False),
553  isIgnored = cms.bool(False) ),
554  )
555  )
556  #
557  return parameterSet
558 
559 
560 # ==============================================================
561 # Define the complete cut sets
562 # ==============================================================
563 
def configureVIDCutBasedEleID_V2(wpEB, wpEE, isoInputs)
def cutBasedElectronID_tools.configureVIDCutBasedEleID_V3 (   wpEB,
  wpEE,
  isoInputs 
)
This function configures the full cms.PSet for a VID ID and returns it.
The inputs: two objects of the type WorkingPoint_V3, one
containing the cuts for the Barrel (EB) and the other one for the Endcap (EE).
The third argument is an object that contains information necessary
for isolation calculations.
    In this version, the impact parameter cuts dxy and dz are not present

Definition at line 564 of file cutBasedElectronID_tools.py.

References psetConversionVetoCut(), psetDEtaInSeedCut(), psetDPhiInCut(), psetEffAreaPFIsoCut(), psetEInerseMinusPInverseCut(), psetHadronicOverEMCut(), psetMinPtCut(), psetMissingHitsCut(), psetPhoFull5x5SigmaIEtaIEtaCut(), and psetPhoSCEtaMultiRangeCut().

564 def configureVIDCutBasedEleID_V3( wpEB, wpEE, isoInputs ):
565  """
566  This function configures the full cms.PSet for a VID ID and returns it.
567  The inputs: two objects of the type WorkingPoint_V3, one
568  containing the cuts for the Barrel (EB) and the other one for the Endcap (EE).
569  The third argument is an object that contains information necessary
570  for isolation calculations.
571  In this version, the impact parameter cuts dxy and dz are not present
572  """
573  # print "VID: Configuring cut set %s" % wpEB.idName
574  parameterSet = cms.PSet(
575  #
576  idName = cms.string( wpEB.idName ), # same name stored in the _EB and _EE objects
577  cutFlow = cms.VPSet(
578  psetMinPtCut(),
579  psetPhoSCEtaMultiRangeCut(), # eta cut
580  psetDEtaInSeedCut(wpEB, wpEE), # dEtaIn seed cut
581  psetDPhiInCut(wpEB, wpEE), # dPhiIn cut
582  psetPhoFull5x5SigmaIEtaIEtaCut(wpEB, wpEE), # full 5x5 sigmaIEtaIEta cut
583  psetHadronicOverEMCut(wpEB, wpEE), # H/E cut
584  psetEInerseMinusPInverseCut(wpEB, wpEE), # |1/e-1/p| cut
585  psetEffAreaPFIsoCut(wpEB, wpEE, isoInputs), # rel. comb. PF isolation cut
587  psetMissingHitsCut(wpEB, wpEE)
588  )
589  )
590  #
591  return parameterSet
592 
593 
594 # -----------------------------
595 # HLT-safe common definitions
596 # -----------------------------
597 
598 
def configureVIDCutBasedEleID_V3(wpEB, wpEE, isoInputs)
def psetPhoFull5x5SigmaIEtaIEtaCut(wpEB, wpEE)
def psetEffAreaPFIsoCut(wpEB, wpEE, isoInputs)
def cutBasedElectronID_tools.psetConversionVetoCut ( )

Definition at line 323 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleID_V3().

324  return cms.PSet(
325  cutName = cms.string('GsfEleConversionVetoCut'),
326  conversionSrc = cms.InputTag('allConversions'),
327  conversionSrcMiniAOD = cms.InputTag('reducedEgamma:reducedConversions'),
328  beamspotSrc = cms.InputTag('offlineBeamSpot'),
329  needsAdditionalProducts = cms.bool(True),
330  isIgnored = cms.bool(False)
331  )
332 
def cutBasedElectronID_tools.psetDEtaInSeedCut (   wpEB,
  wpEE 
)

Definition at line 196 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), and configureVIDCutBasedEleID_V3().

196 def psetDEtaInSeedCut(wpEB, wpEE):
197  return cms.PSet(
198  cutName = cms.string('GsfEleDEtaInSeedCut'),
199  dEtaInSeedCutValueEB = cms.double( wpEB.dEtaInSeedCut ),
200  dEtaInSeedCutValueEE = cms.double( wpEE.dEtaInSeedCut ),
201  barrelCutOff = cms.double(ebCutOff),
202  needsAdditionalProducts = cms.bool(False),
203  isIgnored = cms.bool(False)
204  )
205 
206 # Configure dPhiIn cut
def cutBasedElectronID_tools.psetDPhiInCut (   wpEB,
  wpEE 
)

Definition at line 207 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), and configureVIDCutBasedEleID_V3().

207 def psetDPhiInCut(wpEB, wpEE):
208  return cms.PSet(
209  cutName = cms.string('GsfEleDPhiInCut'),
210  dPhiInCutValueEB = cms.double( wpEB.dPhiInCut ),
211  dPhiInCutValueEE = cms.double( wpEE.dPhiInCut ),
212  barrelCutOff = cms.double(ebCutOff),
213  needsAdditionalProducts = cms.bool(False),
214  isIgnored = cms.bool(False)
215  )
216 
217 # Configure H/E cut
def cutBasedElectronID_tools.psetEcalPFClusterIsoCut (   wpEB,
  wpEE,
  ecalIsoInputs 
)

Definition at line 241 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1().

241 def psetEcalPFClusterIsoCut(wpEB, wpEE, ecalIsoInputs):
242  return cms.PSet(
243  cutName = cms.string('GsfEleCalPFClusterIsoCut'),
244  isoType = cms.int32( 0 ), # ECAL = 0, HCAL = 1, see cut class header for IsoType enum
245  isoCutEBLowPt = cms.double( wpEB.ecalPFClusterIsoLowPtCut ),
246  isoCutEBHighPt = cms.double( wpEB.ecalPFClusterIsoHighPtCut ),
247  isoCutEELowPt = cms.double( wpEE.ecalPFClusterIsoLowPtCut ),
248  isoCutEEHighPt = cms.double( wpEE.ecalPFClusterIsoHighPtCut ),
249  isRelativeIso = cms.bool(True),
250  ptCutOff = cms.double(20.0), # high pT above this value, low pT below
251  barrelCutOff = cms.double(ebCutOff),
252  rho = cms.InputTag("fixedGridRhoFastjetCentralCalo"), # This rho is best for emulation
253  # while HLT uses ...AllCalo
254  effAreasConfigFile = cms.FileInPath( ecalIsoInputs.isoEffAreas ),
255  needsAdditionalProducts = cms.bool(True),
256  isIgnored = cms.bool(False)
257  )
258 
259 # Configure HCAL PF Cluster isolation cut. Note that this cut requires
260 # effective area constants file as input
def psetEcalPFClusterIsoCut(wpEB, wpEE, ecalIsoInputs)
def cutBasedElectronID_tools.psetEffAreaPFIsoCut (   wpEB,
  wpEE,
  isoInputs 
)

Definition at line 307 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleID_V3().

307 def psetEffAreaPFIsoCut(wpEB, wpEE, isoInputs):
308  return cms.PSet(
309  cutName = cms.string('GsfEleEffAreaPFIsoCut'),
310  isoCutEBLowPt = cms.double( wpEB.relCombIsolationWithEALowPtCut ),
311  isoCutEBHighPt = cms.double( wpEB.relCombIsolationWithEAHighPtCut ),
312  isoCutEELowPt = cms.double( wpEE.relCombIsolationWithEALowPtCut ),
313  isoCutEEHighPt = cms.double( wpEE.relCombIsolationWithEAHighPtCut ),
314  isRelativeIso = cms.bool(True),
315  ptCutOff = cms.double(20.0), # high pT above this value, low pT below
316  barrelCutOff = cms.double(ebCutOff),
317  rho = cms.InputTag("fixedGridRhoFastjetAll"),
318  effAreasConfigFile = cms.FileInPath( isoInputs.isoEffAreas ),
319  needsAdditionalProducts = cms.bool(True),
320  isIgnored = cms.bool(False)
321  )
322 
def psetEffAreaPFIsoCut(wpEB, wpEE, isoInputs)
def cutBasedElectronID_tools.psetEInerseMinusPInverseCut (   wpEB,
  wpEE 
)

Definition at line 229 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), and configureVIDCutBasedEleID_V3().

230  return cms.PSet(
231  cutName = cms.string('GsfEleEInverseMinusPInverseCut'),
232  eInverseMinusPInverseCutValueEB = cms.double( wpEB.absEInverseMinusPInverseCut ),
233  eInverseMinusPInverseCutValueEE = cms.double( wpEE.absEInverseMinusPInverseCut ),
234  barrelCutOff = cms.double(ebCutOff),
235  needsAdditionalProducts = cms.bool(False),
236  isIgnored = cms.bool(False)
237  )
238 
239 # Configure ECAL PF Cluster isolation cut. Note that this cut requires
240 # effective area constants file as input
def cutBasedElectronID_tools.psetHadronicOverEMCut (   wpEB,
  wpEE 
)

Definition at line 218 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), and configureVIDCutBasedEleID_V3().

218 def psetHadronicOverEMCut(wpEB, wpEE):
219  return cms.PSet(
220  cutName = cms.string('GsfEleHadronicOverEMCut'),
221  hadronicOverEMCutValueEB = cms.double( wpEB.hOverECut ),
222  hadronicOverEMCutValueEE = cms.double( wpEE.hOverECut ),
223  barrelCutOff = cms.double(ebCutOff),
224  needsAdditionalProducts = cms.bool(False),
225  isIgnored = cms.bool(False)
226  )
227 
228 # Configure |1/E-1/p| cut
def cutBasedElectronID_tools.psetHcalPFClusterIsoCut (   wpEB,
  wpEE,
  hcalIsoInputs 
)

Definition at line 261 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1().

261 def psetHcalPFClusterIsoCut(wpEB, wpEE, hcalIsoInputs):
262  return cms.PSet(
263  cutName = cms.string('GsfEleCalPFClusterIsoCut'),
264  isoType = cms.int32( 1 ), # ECAL = 0, HCAL = 1, see cut class header for IsoType enum
265  isoCutEBLowPt = cms.double( wpEB.hcalPFClusterIsoLowPtCut ),
266  isoCutEBHighPt = cms.double( wpEB.hcalPFClusterIsoHighPtCut ),
267  isoCutEELowPt = cms.double( wpEE.hcalPFClusterIsoLowPtCut ),
268  isoCutEEHighPt = cms.double( wpEE.hcalPFClusterIsoHighPtCut ),
269  isRelativeIso = cms.bool(True),
270  ptCutOff = cms.double(20.0), # high pT above this value, low pT below
271  barrelCutOff = cms.double(ebCutOff),
272  rho = cms.InputTag("fixedGridRhoFastjetCentralCalo"), # This rho is best for emulation
273  # while HLT uses ...AllCalo
274  effAreasConfigFile = cms.FileInPath( hcalIsoInputs.isoEffAreas ),
275  needsAdditionalProducts = cms.bool(True),
276  isIgnored = cms.bool(False)
277  )
278 
279 # Configure tracker isolation cut
def psetHcalPFClusterIsoCut(wpEB, wpEE, hcalIsoInputs)
def cutBasedElectronID_tools.psetMinPtCut ( )

Definition at line 161 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), and configureVIDCutBasedEleID_V3().

162  return cms.PSet(
163  cutName = cms.string("MinPtCut"),
164  minPt = cms.double(5.0),
165  needsAdditionalProducts = cms.bool(False),
166  isIgnored = cms.bool(False)
167  )
168 
169 # Take all particles in the eta ranges 0-ebCutOff and ebCutOff-2.5
def cutBasedElectronID_tools.psetMissingHitsCut (   wpEB,
  wpEE 
)

Definition at line 333 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleID_V3().

333 def psetMissingHitsCut(wpEB, wpEE):
334  return cms.PSet(
335  cutName = cms.string('GsfEleMissingHitsCut'),
336  maxMissingHitsEB = cms.uint32( wpEB.missingHitsCut ),
337  maxMissingHitsEE = cms.uint32( wpEE.missingHitsCut ),
338  barrelCutOff = cms.double(ebCutOff),
339  needsAdditionalProducts = cms.bool(False),
340  isIgnored = cms.bool(False)
341  )
342 
343 
344 # -----------------------------
345 # Version V1 common definitions
346 # -----------------------------
347 
348 # This cut set definition is in the old style, with everything configured
349 # in one go. It is kept to minimize changes. New definitions should use
350 # PSets defined above instead.
def cutBasedElectronID_tools.psetNormalizedGsfChi2Cut (   wpEB,
  wpEE 
)

Definition at line 297 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1().

297 def psetNormalizedGsfChi2Cut(wpEB, wpEE):
298  return cms.PSet(
299  cutName = cms.string('GsfEleNormalizedGsfChi2Cut'),
300  normalizedGsfChi2CutValueEB = cms.double( wpEB.normalizedGsfChi2Cut ),
301  normalizedGsfChi2CutValueEE = cms.double( wpEE.normalizedGsfChi2Cut ),
302  barrelCutOff = cms.double(ebCutOff),
303  needsAdditionalProducts = cms.bool(False),
304  isIgnored = cms.bool(False)
305  )
306 
def cutBasedElectronID_tools.psetPhoFull5x5SigmaIEtaIEtaCut (   wpEB,
  wpEE 
)

Definition at line 185 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), and configureVIDCutBasedEleID_V3().

186  return cms.PSet(
187  cutName = cms.string('GsfEleFull5x5SigmaIEtaIEtaCut'),
188  full5x5SigmaIEtaIEtaCutValueEB = cms.double( wpEB.full5x5_sigmaIEtaIEtaCut ),
189  full5x5SigmaIEtaIEtaCutValueEE = cms.double( wpEE.full5x5_sigmaIEtaIEtaCut ),
190  barrelCutOff = cms.double(ebCutOff),
191  needsAdditionalProducts = cms.bool(False),
192  isIgnored = cms.bool(False)
193  )
194 
195 # Configure the cut on dEta seed
def psetPhoFull5x5SigmaIEtaIEtaCut(wpEB, wpEE)
def cutBasedElectronID_tools.psetPhoSCEtaMultiRangeCut ( )

Definition at line 170 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), and configureVIDCutBasedEleID_V3().

171  return cms.PSet(
172  cutName = cms.string("GsfEleSCEtaMultiRangeCut"),
173  useAbsEta = cms.bool(True),
174  allowedEtaRanges = cms.VPSet(
175  cms.PSet( minEta = cms.double(0.0),
176  maxEta = cms.double(ebCutOff) ),
177  cms.PSet( minEta = cms.double(ebCutOff),
178  maxEta = cms.double(2.5) )
179  ),
180  needsAdditionalProducts = cms.bool(False),
181  isIgnored = cms.bool(False)
182  )
183 
184 # Configure the cut on full5x5 sigmaIEtaIEta
def cutBasedElectronID_tools.psetTrkPtIsoCut (   wpEB,
  wpEE 
)

Definition at line 280 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1().

280 def psetTrkPtIsoCut(wpEB, wpEE):
281  return cms.PSet(
282  cutName = cms.string('GsfEleTrkPtIsoCut'),
283  # Three constants for the GsfEleTrkPtIsoCut
284  # cut = constTerm if Et < slopeStart
285  # cut = slopeTerm * (Et - slopeStart) + constTerm if Et >= slopeStart
286  slopeTermEB = cms.double( wpEB.trkIsoSlopeTerm ),
287  slopeTermEE = cms.double( wpEE.trkIsoSlopeTerm ),
288  slopeStartEB = cms.double( wpEB.trkIsoSlopeStart ),
289  slopeStartEE = cms.double( wpEE.trkIsoSlopeStart ),
290  constTermEB = cms.double( wpEB.trkIsoConstTerm ),
291  constTermEE = cms.double( wpEE.trkIsoConstTerm ),
292  needsAdditionalProducts = cms.bool(False),
293  isIgnored = cms.bool(False)
294  )
295 
296 # Configure GsfTrack chi2/NDOF cut

Variable Documentation

cutBasedElectronID_tools.ebCutOff

Definition at line 5 of file cutBasedElectronID_tools.py.