From 01e796f0ba33c68b76641d3522e85fc74162d44d Mon Sep 17 00:00:00 2001 From: swagata87 Date: Mon, 21 Aug 2023 19:13:41 +0200 Subject: [PATCH] use % (for regression vars) --- PhysicsTools/NanoAOD/python/electrons_cff.py | 6 +++++- PhysicsTools/NanoAOD/python/photons_cff.py | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/PhysicsTools/NanoAOD/python/electrons_cff.py b/PhysicsTools/NanoAOD/python/electrons_cff.py index 2a68db305aa24..107e545a7add6 100644 --- a/PhysicsTools/NanoAOD/python/electrons_cff.py +++ b/PhysicsTools/NanoAOD/python/electrons_cff.py @@ -445,8 +445,12 @@ def _get_bitmapVIDForEle_docstring(modules,WorkingPoints): superClusterFbrem = Var("superClusterFbrem",float,doc="superClusterFbrem",precision=10), convVtxFitProb = Var("convVtxFitProb",float,doc="convVtxFitProb",precision=10), clustersSize = Var("superCluster.clustersSize",int,doc="clustersSize"), - + iEtaMod5 = Var("?superCluster.seedCrysIEtaOrIx>0?(superCluster.seedCrysIEtaOrIx-1)%5:(superCluster.seedCrysIEtaOrIx+1)%5",int,doc="iEtaMod5"), + iEtaMod20 = Var("?abs(superCluster.seedCrysIEtaOrIx)<=25?(superCluster.seedCrysIEtaOrIx-(?superCluster.seedCrysIEtaOrIx>0?+1:-1))%20:(superCluster.seedCrysIEtaOrIx-(?superCluster.seedCrysIEtaOrIx>0?+26:-26))%20",int,doc="iEtaMod20"), + iPhiMod2 = Var("(superCluster.seedCrysIPhiOrIy-1)%2",int,doc="iPhiMod2"), + iPhiMod20 = Var("(superCluster.seedCrysIPhiOrIy-1)%20",int,doc="iPhiMod20"), ) + electronExtraTable.variables = cms.PSet( _eleVarsBase, diff --git a/PhysicsTools/NanoAOD/python/photons_cff.py b/PhysicsTools/NanoAOD/python/photons_cff.py index 65c14b91c9146..3d78a92144e37 100644 --- a/PhysicsTools/NanoAOD/python/photons_cff.py +++ b/PhysicsTools/NanoAOD/python/photons_cff.py @@ -292,7 +292,11 @@ def make_bitmapVID_docstring(id_modules_working_points_pset): ecalPFClusterIso = Var("ecalPFClusterIso",float,doc="ecal PFCluster Isolation",precision=10), hcalPFClusterIso = Var("hcalPFClusterIso",float,doc="hcal PFCluster Isolation",precision=10), chargedHadronIso = Var("chargedHadronIso",float,doc="charged hadron Isolation",precision=10), - trkSumPtSolidConeDR04 = Var("trkSumPtSolidConeDR04",float,doc="track isolation solid cone 0.4",precision=10) + trkSumPtSolidConeDR04 = Var("trkSumPtSolidConeDR04",float,doc="track isolation solid cone 0.4",precision=10), + iEtaMod5 = Var("?superCluster.seedCrysIEtaOrIx>0?(superCluster.seedCrysIEtaOrIx-1)%5:(superCluster.seedCrysIEtaOrIx+1)%5",int,doc="iEtaMod5"), + iEtaMod20 = Var("?abs(superCluster.seedCrysIEtaOrIx)<=25?(superCluster.seedCrysIEtaOrIx-(?superCluster.seedCrysIEtaOrIx>0?+1:-1))%20:(superCluster.seedCrysIEtaOrIx-(?superCluster.seedCrysIEtaOrIx>0?+26:-26))%20",int,doc="iEtaMod20"), + iPhiMod2 = Var("(superCluster.seedCrysIPhiOrIy-1)%2",int,doc="iPhiMod2"), + iPhiMod20 = Var("(superCluster.seedCrysIPhiOrIy-1)%20",int,doc="iPhiMod20"), ) photonExtraTable.variables = cms.PSet(