13 mlog = logging.getLogger(name)
14 mlog.debug(
'Start configuration')
20 from ROOT
import LikeEnum
21 from ElectronPhotonSelectorTools.AsgElectronIsEMSelectorsConfig
import (
22 AsgElectronIsEMSelectorCfg)
23 if "electronIsEMselectors" not in kwargs:
25 flags,
"LooseElectronSelector", egammaPID.ElectronIDLoosePP)
27 flags,
"MediumElectronSelector", egammaPID.ElectronIDMediumPP)
29 flags,
"TightElectronSelector", egammaPID.ElectronIDTightPP)
31 kwargs[
"electronIsEMselectors"] = [
32 LooseElectronSelectorAcc.popPrivateTools(),
33 MediumElectronSelectorAcc.popPrivateTools(),
34 TightElectronSelectorAcc.popPrivateTools()]
35 kwargs[
"electronIsEMselectorResultNames"] = [
36 "Loose",
"Medium",
"Tight"]
37 acc.merge(LooseElectronSelectorAcc)
38 acc.merge(MediumElectronSelectorAcc)
39 acc.merge(TightElectronSelectorAcc)
42 from ElectronPhotonSelectorTools.AsgElectronLikelihoodToolsConfig
import (
43 AsgElectronLikelihoodToolCfg)
44 if "electronLHselectors" not in kwargs:
46 flags,
"LooseLHSelector", LikeEnum.Loose)
47 LooseLHSelectorAcc.primaryVertexContainer =
"PrimaryVertices"
49 flags,
"MediumLHSelector", LikeEnum.Medium)
50 MediumLHSelectorAcc.primaryVertexContainer =
"PrimaryVertices"
52 flags,
"TightLHSelector", LikeEnum.Tight)
53 TightLHSelectorAcc.primaryVertexContainer =
"PrimaryVertices"
54 kwargs[
"electronLHselectors"] = [LooseLHSelectorAcc.popPrivateTools(),
55 MediumLHSelectorAcc.popPrivateTools(),
56 TightLHSelectorAcc.popPrivateTools()]
57 kwargs[
"electronLHselectorResultNames"] = [
58 "LHLoose",
"LHMedium",
"LHTight"]
59 acc.merge(LooseLHSelectorAcc)
60 acc.merge(MediumLHSelectorAcc)
61 acc.merge(TightLHSelectorAcc)
63 tool = CompFactory.EMPIDBuilder(name, **kwargs)
65 acc.setPrivateTools(tool)