4 import FWCore.ParameterSet.Config
as cms
7 _nonDefaultEraNames = [
"trackingLowPU",
"trackingPhase1",
"trackingPhase1QuadProp",
"trackingPhase2PU140"]
10 _defaultEra = (_defaultEraName,
"",
None)
12 (_name,
"_"+_name, getattr(__import__(
'Configuration.Eras.Modifier_'+_name+
'_cff',globals(),locals(),[_name],0),_name)) \
13 for _name
in _nonDefaultEraNames
16 _allEras = [_defaultEra] + _nonDefaultEras
21 "DetachedTripletStep",
27 "JetCoreRegionalStep",
29 _iterations_trackingLowPU = [
33 "DetachedTripletStep",
38 _iterations_trackingPhase1 = [
44 "DetachedTripletStep",
49 "JetCoreRegionalStep",
51 _iterations_trackingPhase1QuadProp = _iterations_trackingPhase1
52 _iterations_trackingPhase2PU140 = [
60 _iterations_muonSeeded = [
61 "MuonSeededStepInOut",
62 "MuonSeededStepOutIn",
65 _iterations_muonSeeded_trackingPhase2PU140 = [
66 "MuonSeededStepInOut",
67 "MuonSeededStepOutIn",
69 _multipleSeedProducers = {
70 "MixedTripletStep": [
"A",
"B"],
71 "TobTecStep": [
"Pair",
"Tripl"],
73 _multipleSeedProducers_trackingLowPU = {
74 "MixedTripletStep": [
"A",
"B"],
76 _multipleSeedProducers_trackingPhase1 = {
77 "PixelPairStep": [
"A",
"B"],
78 "MixedTripletStep": [
"A",
"B"],
79 "TobTecStep": [
"Pair",
"Tripl"],
81 _multipleSeedProducers_trackingPhase1QuadProp = _multipleSeedProducers_trackingPhase1
82 _multipleSeedProducers_trackingPhase2PU140 = {}
83 _oldStyleHasSelector = set([
94 _trackClusterRemoverBase = _trackClusterRemover.clone(
96 pixelClusters =
"siPixelClusters",
97 stripClusters =
"siStripClusters",
98 TrackQuality =
'highPurity',
99 minNumberOfLayersWithMeasBeforeFiltering = 0,
103 from RecoLocalTracker.SubCollectionProducers.phase2trackClusterRemover_cfi
import phase2trackClusterRemover
as _phase2trackClusterRemover
104 _trackClusterRemoverBase_trackingPhase2PU140 = _phase2trackClusterRemover.clone(
106 phase2pixelClusters =
"siPixelClusters",
107 phase2OTClusters =
"siPhase2Clusters",
108 TrackQuality =
'highPurity',
109 minNumberOfLayersWithMeasBeforeFiltering = 0,
113 return iteration[0].lower()+iteration[1:]
121 def _classifier(iteration, oldStyle=False, oldStyleQualityMasks=False):
124 if iteration
in _oldStyleHasSelector:
125 return pre+
"Selector:" + (
"QualityMasks" if oldStyleQualityMasks
else pre)
129 return pre+
":QualityMasks" 135 return _nonDefaultEras
139 for it
in globals()[
"_iterations"+postfix]:
144 muonVariable =
"_iterations_muonSeeded"+postfix
145 iterations = globals()[
"_iterations"+postfix] + globals().
get(muonVariable, _iterations_muonSeeded)
147 if includeSequenceName:
154 iters = globals()[
"_iterations"+postfix]
156 multipleSeedProducers = globals()[
"_multipleSeedProducers"+postfix]
158 multipleSeedProducers =
None 161 if multipleSeedProducers
is not None and i
in multipleSeedProducers:
162 ret.extend([seeder+m
for m
in multipleSeedProducers[i]])
166 for i
in globals().
get(
"_iterations_muonSeeded"+postfix, _iterations_muonSeeded):
179 module = _trackClusterRemoverBase.clone()
180 if eraName ==
"trackingPhase2PU140":
181 module = globals().
get(
"_trackClusterRemoverBase"+postfix, _trackClusterRemoverBase)
183 iters = globals()[
"_iterations"+postfix]
185 ind = iters.index(iteration)
191 raise Exception(
"Iteration %s is the first iteration in era %s, asking cluster remover configuration does not make sense" % (iteration, eraName))
192 prevIter = iters[ind-1]
195 trajectories =
_tracks(prevIter),
198 if eraName
in [
"trackingPhase2PU140"]:
199 customize[
"overrideTrkQuals"] =
_classifier(prevIter, oldStyle=
True)
200 elif eraName ==
"trackingLowPU":
201 customize[
"overrideTrkQuals"] =
_classifier(prevIter, oldStyle=
True, oldStyleQualityMasks=
True)
203 customize[
"trackClassifier"] =
_classifier(prevIter)
205 return module.clone(**customize)
def clusterRemoverForIter(iteration, eraName="", postfix="", module=None)
def iterationAlgos(postfix, includeSequenceName=False)
def _seedOrTrackProducers(postfix, typ)
def replace(string, replacements)
def createEarlySequence(eraName, postfix, modDict)
def _clusterRemover(iteration)
def trackProducers(postfix)
def seedProducers(postfix)
def _classifier(iteration, oldStyle=False, oldStyleQualityMasks=False)
def _modulePrefix(iteration)
T get(const Candidate &c)