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  EleWorkingPoint_V4
 
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 configureVIDCutBasedEleID_V4 (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 psetHadronicOverEMEnergyScaledCut (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 680 of file cutBasedElectronID_tools.py.

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

680 def configureVIDCutBasedEleHLTPreselection_V1( wpEB, wpEE, ecalIsoInputs, hcalIsoInputs ):
681  """
682  This function configures the full cms.PSet for a VID ID and returns it.
683  The inputs: two objects of the type EleHLTSelection_V1, one
684  containing the cuts for the Barrel (EB) and the other one for the Endcap (EE).
685  The third and fourth arguments are objects that contain information necessary
686  for isolation calculations for ECAL and HCAL.
687  """
688  # print "VID: Configuring cut set %s" % wpEB.idName
689  parameterSet = cms.PSet(
690  idName = cms.string( wpEB.idName ), # same name stored in the _EB and _EE objects
691  cutFlow = cms.VPSet(
692  psetMinPtCut(), # min pt cut
693  psetPhoSCEtaMultiRangeCut(), # eta cut
694  psetPhoFull5x5SigmaIEtaIEtaCut(wpEB, wpEE), # full 5x5 sigmaIEtaIEta cut
695  psetDEtaInSeedCut(wpEB, wpEE), # dEtaIn seed cut
696  psetDPhiInCut(wpEB, wpEE), # dPhiIn cut
697  psetHadronicOverEMCut(wpEB, wpEE), # H/E cut
698  psetEInerseMinusPInverseCut(wpEB, wpEE), # |1/e-1/p| cut
699  psetEcalPFClusterIsoCut(wpEB, wpEE, ecalIsoInputs), # ECAL PF Cluster isolation
700  psetHcalPFClusterIsoCut(wpEB, wpEE, hcalIsoInputs), # HCAL PF Cluster isolation
701  psetTrkPtIsoCut(wpEB, wpEE), # tracker isolation cut
702  psetNormalizedGsfChi2Cut(wpEB, wpEE) # GsfTrack chi2/NDOF cut
703  )
704  )
705  #
706  return parameterSet
707 
708 
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 403 of file cutBasedElectronID_tools.py.

404  """
405  This function configures the full cms.PSet for a VID ID and returns it.
406  The inputs: two objects of the type WorkingPoint_V1, one
407  containing the cuts for the Barrel (EB) and the other one for the Endcap (EE).
408  """
409  # print "VID: Configuring cut set %s" % wpEB.idName
410  parameterSet = cms.PSet(
411  #
412  idName = cms.string( wpEB.idName ), # same name stored in the _EB and _EE objects
413  cutFlow = cms.VPSet(
414  cms.PSet( cutName = cms.string("MinPtCut"),
415  minPt = cms.double(5.0),
416  needsAdditionalProducts = cms.bool(False),
417  isIgnored = cms.bool(False) ),
418  cms.PSet( cutName = cms.string("GsfEleSCEtaMultiRangeCut"),
419  useAbsEta = cms.bool(True),
420  allowedEtaRanges = cms.VPSet(
421  cms.PSet( minEta = cms.double(0.0),
422  maxEta = cms.double(ebCutOff) ),
423  cms.PSet( minEta = cms.double(ebCutOff),
424  maxEta = cms.double(2.5) )
425  ),
426  needsAdditionalProducts = cms.bool(False),
427  isIgnored = cms.bool(False)),
428  cms.PSet( cutName = cms.string('GsfEleDEtaInCut'),
429  dEtaInCutValueEB = cms.double( wpEB.dEtaInCut ),
430  dEtaInCutValueEE = cms.double( wpEE.dEtaInCut ),
431  barrelCutOff = cms.double(ebCutOff),
432  needsAdditionalProducts = cms.bool(False),
433  isIgnored = cms.bool(False)),
434  cms.PSet( cutName = cms.string('GsfEleDPhiInCut'),
435  dPhiInCutValueEB = cms.double( wpEB.dPhiInCut ),
436  dPhiInCutValueEE = cms.double( wpEE.dPhiInCut ),
437  barrelCutOff = cms.double(ebCutOff),
438  needsAdditionalProducts = cms.bool(False),
439  isIgnored = cms.bool(False)),
440  cms.PSet( cutName = cms.string('GsfEleFull5x5SigmaIEtaIEtaCut'),
441  full5x5SigmaIEtaIEtaCutValueEB = cms.double( wpEB.full5x5_sigmaIEtaIEtaCut ),
442  full5x5SigmaIEtaIEtaCutValueEE = cms.double( wpEE.full5x5_sigmaIEtaIEtaCut ),
443  barrelCutOff = cms.double(ebCutOff),
444  needsAdditionalProducts = cms.bool(False),
445  isIgnored = cms.bool(False)),
446  cms.PSet( cutName = cms.string('GsfEleHadronicOverEMCut'),
447  hadronicOverEMCutValueEB = cms.double( wpEB.hOverECut ),
448  hadronicOverEMCutValueEE = cms.double( wpEE.hOverECut ),
449  barrelCutOff = cms.double(ebCutOff),
450  needsAdditionalProducts = cms.bool(False),
451  isIgnored = cms.bool(False)),
452  cms.PSet( cutName = cms.string('GsfEleDxyCut'),
453  dxyCutValueEB = cms.double( wpEB.dxyCut ),
454  dxyCutValueEE = cms.double( wpEE.dxyCut ),
455  vertexSrc = cms.InputTag("offlinePrimaryVertices"),
456  vertexSrcMiniAOD = cms.InputTag("offlineSlimmedPrimaryVertices"),
457  barrelCutOff = cms.double(ebCutOff),
458  needsAdditionalProducts = cms.bool(True),
459  isIgnored = cms.bool(False)),
460  cms.PSet( cutName = cms.string('GsfEleDzCut'),
461  dzCutValueEB = cms.double( wpEB.dzCut ),
462  dzCutValueEE = cms.double( wpEE.dzCut ),
463  vertexSrc = cms.InputTag("offlinePrimaryVertices"),
464  vertexSrcMiniAOD = cms.InputTag("offlineSlimmedPrimaryVertices"),
465  barrelCutOff = cms.double(ebCutOff),
466  needsAdditionalProducts = cms.bool(True),
467  isIgnored = cms.bool(False)),
468  cms.PSet( cutName = cms.string('GsfEleEInverseMinusPInverseCut'),
469  eInverseMinusPInverseCutValueEB = cms.double( wpEB.absEInverseMinusPInverseCut ),
470  eInverseMinusPInverseCutValueEE = cms.double( wpEE.absEInverseMinusPInverseCut ),
471  barrelCutOff = cms.double(ebCutOff),
472  needsAdditionalProducts = cms.bool(False),
473  isIgnored = cms.bool(False)),
474  cms.PSet( cutName = cms.string('GsfEleDeltaBetaIsoCutStandalone'),
475  isoCutEBLowPt = cms.double( wpEB.relCombIsolationWithDBetaLowPtCut ),
476  isoCutEBHighPt = cms.double( wpEB.relCombIsolationWithDBetaHighPtCut ),
477  isoCutEELowPt = cms.double( wpEE.relCombIsolationWithDBetaLowPtCut ),
478  isoCutEEHighPt = cms.double( wpEE.relCombIsolationWithDBetaHighPtCut ),
479  isRelativeIso = cms.bool(True),
480  deltaBetaConstant = cms.double(0.5),
481  ptCutOff = cms.double(20.0), # high pT above this value, low pT below
482  barrelCutOff = cms.double(ebCutOff),
483  needsAdditionalProducts = cms.bool(False),
484  isIgnored = cms.bool(False)),
485  cms.PSet( cutName = cms.string('GsfEleConversionVetoCut'),
486  conversionSrc = cms.InputTag('allConversions'),
487  conversionSrcMiniAOD = cms.InputTag('reducedEgamma:reducedConversions'),
488  beamspotSrc = cms.InputTag('offlineBeamSpot'),
489  needsAdditionalProducts = cms.bool(True),
490  isIgnored = cms.bool(False)),
491  cms.PSet( cutName = cms.string('GsfEleMissingHitsCut'),
492  maxMissingHitsEB = cms.uint32( wpEB.missingHitsCut ),
493  maxMissingHitsEE = cms.uint32( wpEE.missingHitsCut ),
494  barrelCutOff = cms.double(ebCutOff),
495  needsAdditionalProducts = cms.bool(False),
496  isIgnored = cms.bool(False) ),
497  )
498  )
499  #
500  return parameterSet
501 
502 # -----------------------------
503 # Version V2 common definitions
504 # -----------------------------
505 
506 # This cut set definition is in the old style, with everything configured
507 # in one go. It is kept to minimize changes. New definitions should use
508 # 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 509 of file cutBasedElectronID_tools.py.

509 def configureVIDCutBasedEleID_V2( wpEB, wpEE, isoInputs ):
510  """
511  This function configures the full cms.PSet for a VID ID and returns it.
512  The inputs: two objects of the type WorkingPoint_V2, one
513  containing the cuts for the Barrel (EB) and the other one for the Endcap (EE).
514  The third argument is an object that contains information necessary
515  for isolation calculations.
516  """
517  # print "VID: Configuring cut set %s" % wpEB.idName
518  parameterSet = cms.PSet(
519  #
520  idName = cms.string( wpEB.idName ), # same name stored in the _EB and _EE objects
521  cutFlow = cms.VPSet(
522  cms.PSet( cutName = cms.string("MinPtCut"),
523  minPt = cms.double(5.0),
524  needsAdditionalProducts = cms.bool(False),
525  isIgnored = cms.bool(False) ),
526  cms.PSet( cutName = cms.string("GsfEleSCEtaMultiRangeCut"),
527  useAbsEta = cms.bool(True),
528  allowedEtaRanges = cms.VPSet(
529  cms.PSet( minEta = cms.double(0.0),
530  maxEta = cms.double(ebCutOff) ),
531  cms.PSet( minEta = cms.double(ebCutOff),
532  maxEta = cms.double(2.5) )
533  ),
534  needsAdditionalProducts = cms.bool(False),
535  isIgnored = cms.bool(False)),
536  cms.PSet( cutName = cms.string('GsfEleDEtaInCut'),
537  dEtaInCutValueEB = cms.double( wpEB.dEtaInCut ),
538  dEtaInCutValueEE = cms.double( wpEE.dEtaInCut ),
539  barrelCutOff = cms.double(ebCutOff),
540  needsAdditionalProducts = cms.bool(False),
541  isIgnored = cms.bool(False)),
542  cms.PSet( cutName = cms.string('GsfEleDPhiInCut'),
543  dPhiInCutValueEB = cms.double( wpEB.dPhiInCut ),
544  dPhiInCutValueEE = cms.double( wpEE.dPhiInCut ),
545  barrelCutOff = cms.double(ebCutOff),
546  needsAdditionalProducts = cms.bool(False),
547  isIgnored = cms.bool(False)),
548  cms.PSet( cutName = cms.string('GsfEleFull5x5SigmaIEtaIEtaCut'),
549  full5x5SigmaIEtaIEtaCutValueEB = cms.double( wpEB.full5x5_sigmaIEtaIEtaCut ),
550  full5x5SigmaIEtaIEtaCutValueEE = cms.double( wpEE.full5x5_sigmaIEtaIEtaCut ),
551  barrelCutOff = cms.double(ebCutOff),
552  needsAdditionalProducts = cms.bool(False),
553  isIgnored = cms.bool(False)),
554  cms.PSet( cutName = cms.string('GsfEleHadronicOverEMCut'),
555  hadronicOverEMCutValueEB = cms.double( wpEB.hOverECut ),
556  hadronicOverEMCutValueEE = cms.double( wpEE.hOverECut ),
557  barrelCutOff = cms.double(ebCutOff),
558  needsAdditionalProducts = cms.bool(False),
559  isIgnored = cms.bool(False)),
560  cms.PSet( cutName = cms.string('GsfEleDxyCut'),
561  dxyCutValueEB = cms.double( wpEB.dxyCut ),
562  dxyCutValueEE = cms.double( wpEE.dxyCut ),
563  vertexSrc = cms.InputTag("offlinePrimaryVertices"),
564  vertexSrcMiniAOD = cms.InputTag("offlineSlimmedPrimaryVertices"),
565  barrelCutOff = cms.double(ebCutOff),
566  needsAdditionalProducts = cms.bool(True),
567  isIgnored = cms.bool(False)),
568  cms.PSet( cutName = cms.string('GsfEleDzCut'),
569  dzCutValueEB = cms.double( wpEB.dzCut ),
570  dzCutValueEE = cms.double( wpEE.dzCut ),
571  vertexSrc = cms.InputTag("offlinePrimaryVertices"),
572  vertexSrcMiniAOD = cms.InputTag("offlineSlimmedPrimaryVertices"),
573  barrelCutOff = cms.double(ebCutOff),
574  needsAdditionalProducts = cms.bool(True),
575  isIgnored = cms.bool(False)),
576  cms.PSet( cutName = cms.string('GsfEleEInverseMinusPInverseCut'),
577  eInverseMinusPInverseCutValueEB = cms.double( wpEB.absEInverseMinusPInverseCut ),
578  eInverseMinusPInverseCutValueEE = cms.double( wpEE.absEInverseMinusPInverseCut ),
579  barrelCutOff = cms.double(ebCutOff),
580  needsAdditionalProducts = cms.bool(False),
581  isIgnored = cms.bool(False)),
582  cms.PSet( cutName = cms.string('GsfEleEffAreaPFIsoCut'),
583  isoCutEBLowPt = cms.double( wpEB.relCombIsolationWithEALowPtCut ),
584  isoCutEBHighPt = cms.double( wpEB.relCombIsolationWithEAHighPtCut ),
585  isoCutEELowPt = cms.double( wpEE.relCombIsolationWithEALowPtCut ),
586  isoCutEEHighPt = cms.double( wpEE.relCombIsolationWithEAHighPtCut ),
587  isRelativeIso = cms.bool(True),
588  ptCutOff = cms.double(20.0), # high pT above this value, low pT below
589  barrelCutOff = cms.double(ebCutOff),
590  rho = cms.InputTag("fixedGridRhoFastjetAll"),
591  effAreasConfigFile = cms.FileInPath( isoInputs.isoEffAreas ),
592  needsAdditionalProducts = cms.bool(True),
593  isIgnored = cms.bool(False) ),
594  cms.PSet( cutName = cms.string('GsfEleConversionVetoCut'),
595  conversionSrc = cms.InputTag('allConversions'),
596  conversionSrcMiniAOD = cms.InputTag('reducedEgamma:reducedConversions'),
597  beamspotSrc = cms.InputTag('offlineBeamSpot'),
598  needsAdditionalProducts = cms.bool(True),
599  isIgnored = cms.bool(False)),
600  cms.PSet( cutName = cms.string('GsfEleMissingHitsCut'),
601  maxMissingHitsEB = cms.uint32( wpEB.missingHitsCut ),
602  maxMissingHitsEE = cms.uint32( wpEE.missingHitsCut ),
603  barrelCutOff = cms.double(ebCutOff),
604  needsAdditionalProducts = cms.bool(False),
605  isIgnored = cms.bool(False) ),
606  )
607  )
608  #
609  return parameterSet
610 
611 
612 # ==============================================================
613 # Define the complete cut sets
614 # ==============================================================
615 
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 616 of file cutBasedElectronID_tools.py.

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

616 def configureVIDCutBasedEleID_V3( wpEB, wpEE, isoInputs ):
617  """
618  This function configures the full cms.PSet for a VID ID and returns it.
619  The inputs: two objects of the type WorkingPoint_V3, one
620  containing the cuts for the Barrel (EB) and the other one for the Endcap (EE).
621  The third argument is an object that contains information necessary
622  for isolation calculations.
623  In this version, the impact parameter cuts dxy and dz are not present
624  """
625  # print "VID: Configuring cut set %s" % wpEB.idName
626  parameterSet = cms.PSet(
627  #
628  idName = cms.string( wpEB.idName ), # same name stored in the _EB and _EE objects
629  cutFlow = cms.VPSet(
630  psetMinPtCut(),
631  psetPhoSCEtaMultiRangeCut(), # eta cut
632  psetDEtaInSeedCut(wpEB, wpEE), # dEtaIn seed cut
633  psetDPhiInCut(wpEB, wpEE), # dPhiIn cut
634  psetPhoFull5x5SigmaIEtaIEtaCut(wpEB, wpEE), # full 5x5 sigmaIEtaIEta cut
635  psetHadronicOverEMCut(wpEB, wpEE), # H/E cut
636  psetEInerseMinusPInverseCut(wpEB, wpEE), # |1/e-1/p| cut
637  psetEffAreaPFIsoCut(wpEB, wpEE, isoInputs), # rel. comb. PF isolation cut
639  psetMissingHitsCut(wpEB, wpEE)
640  )
641  )
642  #
643  return parameterSet
644 
def configureVIDCutBasedEleID_V3(wpEB, wpEE, isoInputs)
def psetPhoFull5x5SigmaIEtaIEtaCut(wpEB, wpEE)
def psetEffAreaPFIsoCut(wpEB, wpEE, isoInputs)
def cutBasedElectronID_tools.configureVIDCutBasedEleID_V4 (   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 energy and pileup dependend hOverE is introduced 

Definition at line 645 of file cutBasedElectronID_tools.py.

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

645 def configureVIDCutBasedEleID_V4( wpEB, wpEE, isoInputs ):
646  """
647  This function configures the full cms.PSet for a VID ID and returns it.
648  The inputs: two objects of the type WorkingPoint_V3, one
649  containing the cuts for the Barrel (EB) and the other one for the Endcap (EE).
650  The third argument is an object that contains information necessary
651  for isolation calculations.
652  In this version, the energy and pileup dependend hOverE is introduced
653  """
654  # print "VID: Configuring cut set %s" % wpEB.idName
655  parameterSet = cms.PSet(
656  #
657  idName = cms.string( wpEB.idName ), # same name stored in the _EB and _EE objects
658  cutFlow = cms.VPSet(
659  psetMinPtCut(),
660  psetPhoSCEtaMultiRangeCut(), # eta cut
661  psetDEtaInSeedCut(wpEB, wpEE), # dEtaIn seed cut
662  psetDPhiInCut(wpEB, wpEE), # dPhiIn cut
663  psetPhoFull5x5SigmaIEtaIEtaCut(wpEB, wpEE), # full 5x5 sigmaIEtaIEta cut
664  psetHadronicOverEMEnergyScaledCut(wpEB, wpEE), # H/E cut
665  psetEInerseMinusPInverseCut(wpEB, wpEE), # |1/e-1/p| cut
666  psetEffAreaPFIsoCut(wpEB, wpEE, isoInputs), # rel. comb. PF isolation cut
668  psetMissingHitsCut(wpEB, wpEE)
669  )
670  )
671  #
672  return parameterSet
673 
674 
675 # -----------------------------
676 # HLT-safe common definitions
677 # -----------------------------
678 
679 
def psetHadronicOverEMEnergyScaledCut(wpEB, wpEE)
def configureVIDCutBasedEleID_V4(wpEB, wpEE, isoInputs)
def psetPhoFull5x5SigmaIEtaIEtaCut(wpEB, wpEE)
def psetEffAreaPFIsoCut(wpEB, wpEE, isoInputs)
def cutBasedElectronID_tools.psetConversionVetoCut ( )

Definition at line 375 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleID_V3(), and configureVIDCutBasedEleID_V4().

376  return cms.PSet(
377  cutName = cms.string('GsfEleConversionVetoCut'),
378  conversionSrc = cms.InputTag('allConversions'),
379  conversionSrcMiniAOD = cms.InputTag('reducedEgamma:reducedConversions'),
380  beamspotSrc = cms.InputTag('offlineBeamSpot'),
381  needsAdditionalProducts = cms.bool(True),
382  isIgnored = cms.bool(False)
383  )
384 
def cutBasedElectronID_tools.psetDEtaInSeedCut (   wpEB,
  wpEE 
)

Definition at line 231 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), configureVIDCutBasedEleID_V3(), and configureVIDCutBasedEleID_V4().

231 def psetDEtaInSeedCut(wpEB, wpEE):
232  return cms.PSet(
233  cutName = cms.string('GsfEleDEtaInSeedCut'),
234  dEtaInSeedCutValueEB = cms.double( wpEB.dEtaInSeedCut ),
235  dEtaInSeedCutValueEE = cms.double( wpEE.dEtaInSeedCut ),
236  barrelCutOff = cms.double(ebCutOff),
237  needsAdditionalProducts = cms.bool(False),
238  isIgnored = cms.bool(False)
239  )
240 
241 # Configure dPhiIn cut
def cutBasedElectronID_tools.psetDPhiInCut (   wpEB,
  wpEE 
)

Definition at line 242 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), configureVIDCutBasedEleID_V3(), and configureVIDCutBasedEleID_V4().

242 def psetDPhiInCut(wpEB, wpEE):
243  return cms.PSet(
244  cutName = cms.string('GsfEleDPhiInCut'),
245  dPhiInCutValueEB = cms.double( wpEB.dPhiInCut ),
246  dPhiInCutValueEE = cms.double( wpEE.dPhiInCut ),
247  barrelCutOff = cms.double(ebCutOff),
248  needsAdditionalProducts = cms.bool(False),
249  isIgnored = cms.bool(False)
250  )
251 
252 # Configure H/E cut
def cutBasedElectronID_tools.psetEcalPFClusterIsoCut (   wpEB,
  wpEE,
  ecalIsoInputs 
)

Definition at line 293 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1().

293 def psetEcalPFClusterIsoCut(wpEB, wpEE, ecalIsoInputs):
294  return cms.PSet(
295  cutName = cms.string('GsfEleCalPFClusterIsoCut'),
296  isoType = cms.int32( 0 ), # ECAL = 0, HCAL = 1, see cut class header for IsoType enum
297  isoCutEBLowPt = cms.double( wpEB.ecalPFClusterIsoLowPtCut ),
298  isoCutEBHighPt = cms.double( wpEB.ecalPFClusterIsoHighPtCut ),
299  isoCutEELowPt = cms.double( wpEE.ecalPFClusterIsoLowPtCut ),
300  isoCutEEHighPt = cms.double( wpEE.ecalPFClusterIsoHighPtCut ),
301  isRelativeIso = cms.bool(True),
302  ptCutOff = cms.double(20.0), # high pT above this value, low pT below
303  barrelCutOff = cms.double(ebCutOff),
304  rho = cms.InputTag("fixedGridRhoFastjetCentralCalo"), # This rho is best for emulation
305  # while HLT uses ...AllCalo
306  effAreasConfigFile = cms.FileInPath( ecalIsoInputs.isoEffAreas ),
307  needsAdditionalProducts = cms.bool(True),
308  isIgnored = cms.bool(False)
309  )
310 
311 # Configure HCAL PF Cluster isolation cut. Note that this cut requires
312 # effective area constants file as input
def psetEcalPFClusterIsoCut(wpEB, wpEE, ecalIsoInputs)
def cutBasedElectronID_tools.psetEffAreaPFIsoCut (   wpEB,
  wpEE,
  isoInputs 
)

Definition at line 359 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleID_V3(), and configureVIDCutBasedEleID_V4().

359 def psetEffAreaPFIsoCut(wpEB, wpEE, isoInputs):
360  return cms.PSet(
361  cutName = cms.string('GsfEleEffAreaPFIsoCut'),
362  isoCutEBLowPt = cms.double( wpEB.relCombIsolationWithEALowPtCut ),
363  isoCutEBHighPt = cms.double( wpEB.relCombIsolationWithEAHighPtCut ),
364  isoCutEELowPt = cms.double( wpEE.relCombIsolationWithEALowPtCut ),
365  isoCutEEHighPt = cms.double( wpEE.relCombIsolationWithEAHighPtCut ),
366  isRelativeIso = cms.bool(True),
367  ptCutOff = cms.double(20.0), # high pT above this value, low pT below
368  barrelCutOff = cms.double(ebCutOff),
369  rho = cms.InputTag("fixedGridRhoFastjetAll"),
370  effAreasConfigFile = cms.FileInPath( isoInputs.isoEffAreas ),
371  needsAdditionalProducts = cms.bool(True),
372  isIgnored = cms.bool(False)
373  )
374 
def psetEffAreaPFIsoCut(wpEB, wpEE, isoInputs)
def cutBasedElectronID_tools.psetEInerseMinusPInverseCut (   wpEB,
  wpEE 
)

Definition at line 281 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), configureVIDCutBasedEleID_V3(), and configureVIDCutBasedEleID_V4().

282  return cms.PSet(
283  cutName = cms.string('GsfEleEInverseMinusPInverseCut'),
284  eInverseMinusPInverseCutValueEB = cms.double( wpEB.absEInverseMinusPInverseCut ),
285  eInverseMinusPInverseCutValueEE = cms.double( wpEE.absEInverseMinusPInverseCut ),
286  barrelCutOff = cms.double(ebCutOff),
287  needsAdditionalProducts = cms.bool(False),
288  isIgnored = cms.bool(False)
289  )
290 
291 # Configure ECAL PF Cluster isolation cut. Note that this cut requires
292 # effective area constants file as input
def cutBasedElectronID_tools.psetHadronicOverEMCut (   wpEB,
  wpEE 
)

Definition at line 253 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), and configureVIDCutBasedEleID_V3().

253 def psetHadronicOverEMCut(wpEB, wpEE):
254  return cms.PSet(
255  cutName = cms.string('GsfEleHadronicOverEMCut'),
256  hadronicOverEMCutValueEB = cms.double( wpEB.hOverECut ),
257  hadronicOverEMCutValueEE = cms.double( wpEE.hOverECut ),
258  barrelCutOff = cms.double(ebCutOff),
259  needsAdditionalProducts = cms.bool(False),
260  isIgnored = cms.bool(False)
261  )
262 
263 # Configure energy and pileup dependend H/E cut
def cutBasedElectronID_tools.psetHadronicOverEMEnergyScaledCut (   wpEB,
  wpEE 
)

Definition at line 264 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleID_V4().

265  return cms.PSet(
266  cutName = cms.string('GsfEleHadronicOverEMEnergyScaledCut'),
267  barrelC0 = cms.double( wpEB.hOverECut_C0 ),
268  barrelCE = cms.double( wpEB.hOverECut_CE ),
269  barrelCr = cms.double( wpEB.hOverECut_Cr ),
270  endcapC0 = cms.double( wpEE.hOverECut_C0 ),
271  endcapCE = cms.double( wpEE.hOverECut_CE ),
272  endcapCr = cms.double( wpEE.hOverECut_Cr ),
273  rho = cms.InputTag("fixedGridRhoFastjetAll"),
274  barrelCutOff = cms.double(ebCutOff),
275  needsAdditionalProducts = cms.bool(True),
276  isIgnored = cms.bool(False)
277  )
278 
279 
280 # Configure |1/E-1/p| cut
def psetHadronicOverEMEnergyScaledCut(wpEB, wpEE)
def cutBasedElectronID_tools.psetHcalPFClusterIsoCut (   wpEB,
  wpEE,
  hcalIsoInputs 
)

Definition at line 313 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1().

313 def psetHcalPFClusterIsoCut(wpEB, wpEE, hcalIsoInputs):
314  return cms.PSet(
315  cutName = cms.string('GsfEleCalPFClusterIsoCut'),
316  isoType = cms.int32( 1 ), # ECAL = 0, HCAL = 1, see cut class header for IsoType enum
317  isoCutEBLowPt = cms.double( wpEB.hcalPFClusterIsoLowPtCut ),
318  isoCutEBHighPt = cms.double( wpEB.hcalPFClusterIsoHighPtCut ),
319  isoCutEELowPt = cms.double( wpEE.hcalPFClusterIsoLowPtCut ),
320  isoCutEEHighPt = cms.double( wpEE.hcalPFClusterIsoHighPtCut ),
321  isRelativeIso = cms.bool(True),
322  ptCutOff = cms.double(20.0), # high pT above this value, low pT below
323  barrelCutOff = cms.double(ebCutOff),
324  rho = cms.InputTag("fixedGridRhoFastjetCentralCalo"), # This rho is best for emulation
325  # while HLT uses ...AllCalo
326  effAreasConfigFile = cms.FileInPath( hcalIsoInputs.isoEffAreas ),
327  needsAdditionalProducts = cms.bool(True),
328  isIgnored = cms.bool(False)
329  )
330 
331 # Configure tracker isolation cut
def psetHcalPFClusterIsoCut(wpEB, wpEE, hcalIsoInputs)
def cutBasedElectronID_tools.psetMinPtCut ( )

Definition at line 196 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), configureVIDCutBasedEleID_V3(), and configureVIDCutBasedEleID_V4().

197  return cms.PSet(
198  cutName = cms.string("MinPtCut"),
199  minPt = cms.double(5.0),
200  needsAdditionalProducts = cms.bool(False),
201  isIgnored = cms.bool(False)
202  )
203 
204 # Take all particles in the eta ranges 0-ebCutOff and ebCutOff-2.5
def cutBasedElectronID_tools.psetMissingHitsCut (   wpEB,
  wpEE 
)

Definition at line 385 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleID_V3(), and configureVIDCutBasedEleID_V4().

385 def psetMissingHitsCut(wpEB, wpEE):
386  return cms.PSet(
387  cutName = cms.string('GsfEleMissingHitsCut'),
388  maxMissingHitsEB = cms.uint32( wpEB.missingHitsCut ),
389  maxMissingHitsEE = cms.uint32( wpEE.missingHitsCut ),
390  barrelCutOff = cms.double(ebCutOff),
391  needsAdditionalProducts = cms.bool(False),
392  isIgnored = cms.bool(False)
393  )
394 
395 
396 # -----------------------------
397 # Version V1 common definitions
398 # -----------------------------
399 
400 # This cut set definition is in the old style, with everything configured
401 # in one go. It is kept to minimize changes. New definitions should use
402 # PSets defined above instead.
def cutBasedElectronID_tools.psetNormalizedGsfChi2Cut (   wpEB,
  wpEE 
)

Definition at line 349 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1().

349 def psetNormalizedGsfChi2Cut(wpEB, wpEE):
350  return cms.PSet(
351  cutName = cms.string('GsfEleNormalizedGsfChi2Cut'),
352  normalizedGsfChi2CutValueEB = cms.double( wpEB.normalizedGsfChi2Cut ),
353  normalizedGsfChi2CutValueEE = cms.double( wpEE.normalizedGsfChi2Cut ),
354  barrelCutOff = cms.double(ebCutOff),
355  needsAdditionalProducts = cms.bool(False),
356  isIgnored = cms.bool(False)
357  )
358 
def cutBasedElectronID_tools.psetPhoFull5x5SigmaIEtaIEtaCut (   wpEB,
  wpEE 
)

Definition at line 220 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), configureVIDCutBasedEleID_V3(), and configureVIDCutBasedEleID_V4().

221  return cms.PSet(
222  cutName = cms.string('GsfEleFull5x5SigmaIEtaIEtaCut'),
223  full5x5SigmaIEtaIEtaCutValueEB = cms.double( wpEB.full5x5_sigmaIEtaIEtaCut ),
224  full5x5SigmaIEtaIEtaCutValueEE = cms.double( wpEE.full5x5_sigmaIEtaIEtaCut ),
225  barrelCutOff = cms.double(ebCutOff),
226  needsAdditionalProducts = cms.bool(False),
227  isIgnored = cms.bool(False)
228  )
229 
230 # Configure the cut on dEta seed
def psetPhoFull5x5SigmaIEtaIEtaCut(wpEB, wpEE)
def cutBasedElectronID_tools.psetPhoSCEtaMultiRangeCut ( )

Definition at line 205 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1(), configureVIDCutBasedEleID_V3(), and configureVIDCutBasedEleID_V4().

206  return cms.PSet(
207  cutName = cms.string("GsfEleSCEtaMultiRangeCut"),
208  useAbsEta = cms.bool(True),
209  allowedEtaRanges = cms.VPSet(
210  cms.PSet( minEta = cms.double(0.0),
211  maxEta = cms.double(ebCutOff) ),
212  cms.PSet( minEta = cms.double(ebCutOff),
213  maxEta = cms.double(2.5) )
214  ),
215  needsAdditionalProducts = cms.bool(False),
216  isIgnored = cms.bool(False)
217  )
218 
219 # Configure the cut on full5x5 sigmaIEtaIEta
def cutBasedElectronID_tools.psetTrkPtIsoCut (   wpEB,
  wpEE 
)

Definition at line 332 of file cutBasedElectronID_tools.py.

Referenced by configureVIDCutBasedEleHLTPreselection_V1().

332 def psetTrkPtIsoCut(wpEB, wpEE):
333  return cms.PSet(
334  cutName = cms.string('GsfEleTrkPtIsoCut'),
335  # Three constants for the GsfEleTrkPtIsoCut
336  # cut = constTerm if Et < slopeStart
337  # cut = slopeTerm * (Et - slopeStart) + constTerm if Et >= slopeStart
338  slopeTermEB = cms.double( wpEB.trkIsoSlopeTerm ),
339  slopeTermEE = cms.double( wpEE.trkIsoSlopeTerm ),
340  slopeStartEB = cms.double( wpEB.trkIsoSlopeStart ),
341  slopeStartEE = cms.double( wpEE.trkIsoSlopeStart ),
342  constTermEB = cms.double( wpEB.trkIsoConstTerm ),
343  constTermEE = cms.double( wpEE.trkIsoConstTerm ),
344  needsAdditionalProducts = cms.bool(False),
345  isIgnored = cms.bool(False)
346  )
347 
348 # Configure GsfTrack chi2/NDOF cut

Variable Documentation

cutBasedElectronID_tools.ebCutOff

Definition at line 5 of file cutBasedElectronID_tools.py.