1 import FWCore.ParameterSet.Config
as cms
2 from PhysicsTools.SelectorUtils.centralIDRegistry
import central_id_registry
5 weightFileBaseDir =
"RecoEgamma/PhotonIdentification/data/MVA" 10 category_cuts = cms.vstring(
11 "abs(superCluster.eta) < 1.479",
12 "abs(superCluster.eta) >= 1.479",
16 mvaClassName =
"PhotonMVAEstimator" 22 mvaProducerModuleLabel =
"photonMVAValueMapProducer" 30 This is a container class to hold MVA cut values for a 2-category MVA 31 as well as the names of the value maps that contain the MVA values computed 32 for all particles in a producer upstream. 56 This function configures the full cms.PSet for a VID ID and returns it. 57 The inputs: an object of the class PhoMVA_2Categories_WP or similar 58 that contains all necessary parameters for this MVA. 60 parameterSet = cms.PSet(
62 idName = cms.string( mvaWP.idName ),
64 cms.PSet( cutName = cms.string(
"PhoMVACut"),
65 mvaCuts = cms.vdouble( mvaWP.getCutValues() ),
66 mvaValueMapName = cms.InputTag( mvaWP.mvaValueMapName ),
67 mvaCategoriesMapName =cms.InputTag( mvaWP.mvaCategoriesMapName ),
68 needsAdditionalProducts = cms.bool(
True),
69 isIgnored = cms.bool(
False)
95 mvaValueMapName = mvaProducerModuleLabel +
":" + mvaClassName + mvaTag +
"Values" 96 mvaCategoriesMapName = mvaProducerModuleLabel +
":" + mvaClassName + mvaTag +
"Categories" 99 producer_config = cms.PSet(
100 mvaName = cms.string(mvaClassName),
101 mvaTag = cms.string(mvaTag),
102 weightFileNames = cms.vstring(*weightFiles),
103 variableDefinition = cms.string(variablesFile),
104 **addKwargsForValueProducer
110 idName = wpc[
"idName"]
114 mvaValueMapName = mvaValueMapName,
115 mvaCategoriesMapName = mvaCategoriesMapName,
116 cutCategory0 = wpc[
"cuts"][
"EB"],
117 cutCategory1 = wpc[
"cuts"][
"EE"]
121 configs = {
"producer_config": producer_config,
"VID_config": VID_config}