10 yResidualsOfflineValidation=
"""
11 import FWCore.ParameterSet.Config as cms
13 process = cms.Process("OfflineValidator")
15 process.load("Alignment.OfflineValidation..oO[dataset]Oo._cff")
17 process.source.inputCommands = cms.untracked.vstring('keep *', 'drop *_MEtoEDMConverter_*_*') # hack to get rid of the memory consumption problem in 2_2_X and beond
18 process.options = cms.untracked.PSet(
19 wantSummary = cms.untracked.bool(False),
20 Rethrow = cms.untracked.vstring("ProductNotFound"), # make this exception fatal
21 fileMode = cms.untracked.string('NOMERGE') # no ordering needed, but calls endRun/beginRun etc. at file boundaries
25 ## Maximum number of Events
27 process.maxEvents = cms.untracked.PSet(
28 input = cms.untracked.int32(.oO[nEvents]Oo.)
32 ## Messages & Convenience
34 process.load("FWCore.MessageLogger.MessageLogger_cfi")
35 process.MessageLogger = cms.Service("MessageLogger",
36 destinations = cms.untracked.vstring('LOGFILE_Offline_.oO[name]Oo.',
40 ## report only every 100th record
41 ##process.MessageLogger.cerr.FwkReport.reportEvery = 100
45 ## Alignment Track Selection
47 process.load("Alignment.CommonAlignmentProducer.AlignmentTrackSelector_cfi")
48 process.AlignmentTrackSelector.src = 'TrackRefitter1'
49 process.AlignmentTrackSelector.filter = True
50 process.AlignmentTrackSelector.applyBasicCuts = True
51 process.AlignmentTrackSelector.pMin = 4.
52 process.AlignmentTrackSelector.pMax = 9999.
53 process.AlignmentTrackSelector.ptMin = 0.
54 process.AlignmentTrackSelector.ptMax = 9999.
55 process.AlignmentTrackSelector.etaMin = -999.
56 process.AlignmentTrackSelector.etaMax = 999.
57 process.AlignmentTrackSelector.nHitMin = 8
58 process.AlignmentTrackSelector.nHitMin2D = 2
59 process.AlignmentTrackSelector.chi2nMax = 999.
60 process.AlignmentTrackSelector.applyMultiplicityFilter = False
61 process.AlignmentTrackSelector.maxMultiplicity = 1
62 process.AlignmentTrackSelector.applyNHighestPt = False
63 process.AlignmentTrackSelector.nHighestPt = 1
64 process.AlignmentTrackSelector.seedOnlyFrom = 0
65 process.AlignmentTrackSelector.applyIsolationCut = False
66 process.AlignmentTrackSelector.minHitIsolation = 0.8
67 process.AlignmentTrackSelector.applyChargeCheck = False
68 process.AlignmentTrackSelector.minHitChargeStrip = 50.
69 #process.AlignmentTrackSelector.trackQualities = ["highPurity"]
70 #process.AlignmentTrackSelector.iterativeTrackingSteps = ["iter1","iter2"]
73 #-- new track hit filter
74 # TrackerTrackHitFilter takes as input the tracks/trajectories coming out from TrackRefitter1
75 process.load("RecoTracker.FinalTrackSelectors.TrackerTrackHitFilter_cff")
76 process.TrackerTrackHitFilter.src = 'TrackRefitter1'
77 process.TrackerTrackHitFilter.useTrajectories= True # this is needed only if you require some selections; but it will work even if you don't ask for them
78 process.TrackerTrackHitFilter.minimumHits = 8
79 process.TrackerTrackHitFilter.commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC")
80 process.TrackerTrackHitFilter.detsToIgnore = [
81 # see https://hypernews.cern.ch/HyperNews/CMS/get/tracker-performance/484.html
83 369136710, 369136714, 402668822,
85 436310989, 436310990, 436299301, 436299302,
87 470340521, 470063045, 470063046, 470114669, 470114670, 470161093, 470161094, 470164333, 470164334, 470312005, 470312006, 470312009, 470067405, 470067406, 470128813
89 process.TrackerTrackHitFilter.replaceWithInactiveHits = True
90 process.TrackerTrackHitFilter.stripAllInvalidHits = False
91 process.TrackerTrackHitFilter.rejectBadStoNHits = True
92 process.TrackerTrackHitFilter.StoNcommands = cms.vstring("ALL 14.0")
93 process.TrackerTrackHitFilter.rejectLowAngleHits= True
94 process.TrackerTrackHitFilter.TrackAngleCut= 0.35 # in rads, starting from the module surface
95 process.TrackerTrackHitFilter.usePixelQualityFlag= True
97 #now we give the TrackCandidate coming out of the TrackerTrackHitFilter to the track producer
98 import RecoTracker.TrackProducer.CosmicFinalFitWithMaterialP5_cff
99 process.HitFilteredTracks = RecoTracker.TrackProducer.CosmicFinalFitWithMaterialP5_cff.cosmictrackfinderP5.clone(
100 src = 'TrackerTrackHitFilter'
104 ## Load and Configure TrackRefitter1
107 process.load("RecoTracker.TrackProducer.TrackRefitters_cff")
109 process.TrackRefitter1 = RecoTracker.TrackProducer.TrackRefitterP5_cfi.TrackRefitterP5.clone(
110 src = '.oO[TrackCollection]Oo.',
111 TrajectoryInEvent = True,
112 TTRHBuilder = "WithTrackAngle",
113 NavigationSchool = ""
116 process.TrackRefitter2 = process.TrackRefitter1.clone(
117 src = 'HitFilteredTracks')
123 process.load("RecoVertex.BeamSpotProducer.BeamSpot_cff")
126 ## GlobalTag Conditions (if needed)
128 process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
129 process.GlobalTag.globaltag = ".oO[GlobalTag]Oo."
130 #process.GlobalTag.connect="frontier://FrontierProd/CMS_COND_21X_GLOBALTAG"
131 # process.GlobalTag.connect="frontier://FrontierProd/CMS_COND_31X_GLOBALTAG"
133 ## LAYERWISE Lorentz Angle ###################
135 process.SiStripLorentzAngle = cms.ESSource("PoolDBESSource",
137 cms.untracked.string('TBufferBlobStreamingService'),
138 DBParameters = cms.PSet(
139 messageLevel = cms.untracked.int32(2),
141 cms.untracked.string('/afs/cern.ch/cms/DB/conddb')
143 timetype = cms.string('runnumber'),
144 toGet = cms.VPSet(cms.PSet(
145 record = cms.string('SiStripLorentzAngleRcd'),
146 tag = cms.string('SiStripLA_CRAFT_layers')
148 connect = cms.string('sqlite_file:/afs/cern.ch/user/j/jdraeger/public/LA_object/LA_CRAFT_layers.db')
150 process.es_prefer_SiStripLorentzAngle = cms.ESPrefer("PoolDBESSource","SiStripLorentzAngle")
155 process.load("Configuration.StandardSequences.Geometry_cff")
160 process.load("Configuration/StandardSequences/MagneticField_38T_cff")
164 ## to apply misalignments
165 #TrackerDigiGeometryESModule.applyAlignment = True
168 ## Load and Configure OfflineValidation
170 process.load("Alignment.OfflineValidation.TrackerOfflineValidation_.oO[offlineValidationMode]Oo._cff")
171 process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..Tracks = 'TrackRefitter2'
172 process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..trajectoryInput = 'TrackRefitter2'
173 process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..moduleLevelHistsTransient = cms.bool(.oO[offlineModuleLevelHistsTransient]Oo.)
174 process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..stripYResiduals = True
175 .oO[offlineValidationFileOutput]Oo.
180 process.p = cms.Path(process.offlineBeamSpot*process.TrackRefitter1*process.TrackerTrackHitFilter*process.HitFilteredTracks
181 *process.TrackRefitter2*process.AlignmentTrackSelector*process.seqTrackerOfflineValidation.oO[offlineValidationMode]Oo.)
189 from CondCore.DBCommon.CondDBSetup_cfi import *
190 process.APE = cms.ESSource("PoolDBESSource",CondDBSetup,
191 connect = cms.string('frontier://FrontierProd/CMS_COND_31X_FROM21X'),
192 timetype = cms.string("runnumber"),
194 cms.PSet(record = cms.string('TrackerAlignmentErrorRcd'),
195 tag = cms.string('TrackerIdealGeometryErrors210_mc')
198 process.es_prefer_APE = cms.ESPrefer("PoolDBESSource", "APE")
204 CosmicsOfflineValidation=
"""
205 import FWCore.ParameterSet.Config as cms
207 process = cms.Process("OfflineValidator")
209 process.load("Alignment.OfflineValidation..oO[dataset]Oo._cff")
211 process.options = cms.untracked.PSet(
212 wantSummary = cms.untracked.bool(False),
213 Rethrow = cms.untracked.vstring("ProductNotFound"), # make this exception fatal
214 # fileMode = cms.untracked.string('NOMERGE') # no ordering needed, but calls endRun/beginRun etc. at file boundaries
218 ## Maximum number of Events
220 process.maxEvents = cms.untracked.PSet(
221 input = cms.untracked.int32(.oO[nEvents]Oo.)
225 ## Messages & Convenience
227 process.load("FWCore.MessageLogger.MessageLogger_cfi")
228 process.MessageLogger.cerr = cms.untracked.PSet(placeholder = cms.untracked.bool(True))
229 process.MessageLogger.cout = cms.untracked.PSet(INFO = cms.untracked.PSet(
230 reportEvery = cms.untracked.int32(1000) # every 1000th only
231 # limit = cms.untracked.int32(10) # or limit to 10 printouts...
233 process.MessageLogger.statistics.append('cout')
238 process.load("RecoVertex.BeamSpotProducer.BeamSpot_cff")
241 process.load("RecoTracker.TrackProducer.TrackRefitters_cff")
243 ##-- Track hit filter
244 ## TrackerTrackHitFilter takes as input the tracks/trajectories coming out from TrackRefitter1
245 #process.load("RecoTracker.FinalTrackSelectors.TrackerTrackHitFilter_cff")
246 #process.TrackerTrackHitFilter.src = 'TrackRefitter1'
248 #-- 1st refit from file
249 process.TrackRefitter1 = process.TrackRefitterP5.clone(
250 src ='ALCARECOTkAlCosmicsCTF0T',
251 NavigationSchool = cms.string(''),
252 TrajectoryInEvent = True,
253 TTRHBuilder = "WithAngleAndTemplate" #default
256 #-- 2nd fit for AlignmentProducer
257 process.TrackRefitter2 = process.TrackRefitter1.clone(
258 src = 'AlignmentTrackSelector'
262 process.load("RecoTracker.FinalTrackSelectors.TrackerTrackHitFilter_cff")
263 process.TrackerTrackHitFilter.src = 'TrackRefitter1'
264 process.TrackerTrackHitFilter.useTrajectories= True # this is needed only if you require some selections; but it will work even if you don't ask for them
265 process.TrackerTrackHitFilter.minimumHits = 8
266 process.TrackerTrackHitFilter.commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC")
267 process.TrackerTrackHitFilter.detsToIgnore = []
268 process.TrackerTrackHitFilter.replaceWithInactiveHits = True
269 process.TrackerTrackHitFilter.stripAllInvalidHits = False
270 process.TrackerTrackHitFilter.rejectBadStoNHits = True
271 process.TrackerTrackHitFilter.StoNcommands = cms.vstring("ALL 18.0")
272 process.TrackerTrackHitFilter.rejectLowAngleHits = True
273 process.TrackerTrackHitFilter.TrackAngleCut = 0.1# in rads, starting from the module surface; small value since we have bows!
274 process.TrackerTrackHitFilter.usePixelQualityFlag = True #False
277 ## now we give the TrackCandidate coming out of the TrackerTrackHitFilter to the track producer
278 import RecoTracker.TrackProducer.CTFFinalFitWithMaterialP5_cff
279 process.TrackCandidateFitter = RecoTracker.TrackProducer.CTFFinalFitWithMaterialP5_cff.ctfWithMaterialTracksCosmics.clone(
280 src = 'TrackerTrackHitFilter',
281 NavigationSchool = cms.string(''),
282 TTRHBuilder = "WithAngleAndTemplate"
284 #-- Filter tracks for alignment
285 process.load("Alignment.CommonAlignmentProducer.AlignmentTrackSelector_cfi")
286 process.AlignmentTrackSelector.src = 'TrackCandidateFitter'
287 process.AlignmentTrackSelector.applyBasicCuts = True
288 process.AlignmentTrackSelector.pMin = 4
289 process.AlignmentTrackSelector.pMax = 9999.
290 process.AlignmentTrackSelector.ptMin = 0
291 process.AlignmentTrackSelector.etaMin = -999.
292 process.AlignmentTrackSelector.etaMax = 999.
293 process.AlignmentTrackSelector.nHitMin = 8
294 process.AlignmentTrackSelector.nHitMin2D = 2
295 process.AlignmentTrackSelector.chi2nMax = 99.
296 process.AlignmentTrackSelector.applyMultiplicityFilter = True# False
297 process.AlignmentTrackSelector.maxMultiplicity = 1
299 ## GlobalTag Conditions (if needed)
301 process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
302 process.GlobalTag.globaltag = ".oO[GlobalTag]Oo."
308 process.load("Configuration.StandardSequences.GeometryDB_cff")
313 process.load("Configuration/StandardSequences/MagneticField_38T_cff")
315 import CalibTracker.Configuration.Common.PoolDBESSource_cfi
317 process.conditionsInTrackerAlignmentRcd = CalibTracker.Configuration.Common.PoolDBESSource_cfi.poolDBESSource.clone(connect = cms.string('sqlite_file:/afs/cern.ch/cms/CAF/CMSALCA/ALCA_TRACKERALIGN/MP/MPproduction/mp1193/jobData/jobm/alignments_MP.db'),
318 toGet = cms.VPSet(cms.PSet(record = cms.string('TrackerAlignmentRcd'),
319 tag = cms.string('Alignments')
324 process.prefer_conditionsInTrackerAlignmentRcd = cms.ESPrefer("PoolDBESSource", "conditionsInTrackerAlignmentRcd")
327 .oO[LorentzAngleTemplate]Oo.
332 #process.load("Configuration.StandardSequences.Geometry_cff")
337 ## Load and Configure OfflineValidation
340 process.load("Alignment.OfflineValidation.TrackerOfflineValidation_.oO[offlineValidationMode]Oo._cff")
341 process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..Tracks = 'TrackRefitter2'
342 process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..trajectoryInput = 'TrackRefitter2'
343 process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..moduleLevelHistsTransient = cms.bool(.oO[offlineModuleLevelHistsTransient]Oo.)
344 process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..moduleLevelProfiles = cms.bool(.oO[offlineModuleLevelProfiles]Oo.)
345 process.TFileService.fileName = '.oO[outputFile]Oo.'
351 process.p = cms.Path( process.offlineBeamSpot
352 *process.TrackRefitter1
353 *process.TrackerTrackHitFilter
354 *process.TrackCandidateFitter
355 *process.AlignmentTrackSelector
356 *process.TrackRefitter2
357 *process.seqTrackerOfflineValidationStandalone
366 CosmicsAt0TOfflineValidation=
"""
367 import FWCore.ParameterSet.Config as cms
369 process = cms.Process("OfflineValidator")
371 process.load("Alignment.OfflineValidation..oO[dataset]Oo._cff")
373 process.options = cms.untracked.PSet(
374 wantSummary = cms.untracked.bool(False),
375 Rethrow = cms.untracked.vstring("ProductNotFound"), # make this exception fatal
376 fileMode = cms.untracked.string('NOMERGE') # no ordering needed, but calls endRun/beginRun etc. at file boundaries
380 ## Maximum number of Events
382 process.maxEvents = cms.untracked.PSet(
383 input = cms.untracked.int32(.oO[nEvents]Oo.)
387 ## Messages & Convenience
389 process.load("FWCore.MessageLogger.MessageLogger_cfi")
390 process.MessageLogger.cerr = cms.untracked.PSet(placeholder = cms.untracked.bool(True))
391 process.MessageLogger.cout = cms.untracked.PSet(INFO = cms.untracked.PSet(
392 reportEvery = cms.untracked.int32(1000) # every 1000th only
393 # limit = cms.untracked.int32(10) # or limit to 10 printouts...
395 process.MessageLogger.statistics.append('cout')
399 # TrackerTrackHitFilter takes as input the tracks/trajectories coming out from TrackRefitter1
400 process.load("RecoTracker.FinalTrackSelectors.TrackerTrackHitFilter_cff")
401 process.TrackerTrackHitFilter.src = 'TrackRefitter1'
403 #-- Alignment Track Selection
404 process.load("Alignment.CommonAlignmentProducer.AlignmentTrackSelector_cfi")
405 process.AlignmentTrackSelector.src = 'HitFilteredTracks'
406 process.AlignmentTrackSelector.filter = True
408 .oO[TrackSelectionTemplate]Oo.
409 # Override the pmin setting since not meaningful with B=0T
410 process.AlignmentTrackSelector.pMin = 4.
412 #### momentum constraint for 0T
413 # First momentum constraint
414 process.load("RecoTracker.TrackProducer.MomentumConstraintProducer_cff")
415 import RecoTracker.TrackProducer.MomentumConstraintProducer_cff
416 process.AliMomConstraint1 = RecoTracker.TrackProducer.MomentumConstraintProducer_cff.MyMomConstraint.clone()
417 process.AliMomConstraint1.src = '.oO[TrackCollection]Oo.'
418 process.AliMomConstraint1.fixedMomentum = 5.0
419 process.AliMomConstraint1.fixedMomentumError = 0.005
421 # Second momentum constraint
422 #process.load("RecoTracker.TrackProducer.MomentumConstraintProducer_cff")
423 #import RecoTracker.TrackProducer.MomentumConstraintProducer_cff
424 #process.AliMomConstraint2 = RecoTracker.TrackProducer.MomentumConstraintProducer_cff.MyMomConstraint.clone()
425 #process.AliMomConstraint2.src = 'AlignmentTrackSelector'
426 #process.AliMomConstraint2.fixedMomentum = 5.0
427 #process.AliMomConstraint2.fixedMomentumError = 0.005
431 #now we give the TrackCandidate coming out of the TrackerTrackHitFilter to the track producer
432 import RecoTracker.TrackProducer.CTFFinalFitWithMaterialP5_cff
433 process.HitFilteredTracks = RecoTracker.TrackProducer.CTFFinalFitWithMaterialP5_cff.ctfWithMaterialTracksCosmics.clone(
434 src = 'TrackerTrackHitFilter'
436 ### TrajectoryInEvent = True,
437 ### TTRHBuilder = "WithAngleAndTemplate"
441 ## Load and Configure TrackRefitter1
444 process.load("RecoTracker.TrackProducer.TrackRefitters_cff")
447 # parameters for TrackRefitter
448 #process.load("RecoTracker.TrackProducer.RefitterWithMaterial_cff")
449 import RecoTracker.TrackProducer.TrackRefitters_cff
450 process.TrackRefitter1 = process.TrackRefitterP5.clone(
451 src = '.oO[TrackCollection]Oo.', #'AliMomConstraint1',
452 TrajectoryInEvent = True,
453 TTRHBuilder = "WithAngleAndTemplate",
454 NavigationSchool = "",
455 constraint = 'momentum', ### SPECIFIC FOR CRUZET
456 srcConstr='AliMomConstraint1' ### SPECIFIC FOR CRUZET$works only with tag V02-10-02 TrackingTools/PatternTools / or CMSSW >=31X
459 process.TrackRefitter2 = process.TrackRefitter1.clone(
460 src = 'AlignmentTrackSelector',
461 srcConstr='AliMomConstraint1',
462 constraint = 'momentum' ### SPECIFIC FOR CRUZET
469 process.load("RecoVertex.BeamSpotProducer.BeamSpot_cff")
472 ## GlobalTag Conditions (if needed)
474 process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
475 process.GlobalTag.globaltag = ".oO[GlobalTag]Oo."
476 # process.GlobalTag.connect="frontier://FrontierProd/CMS_COND_31X_GLOBALTAG"
478 .oO[LorentzAngleTemplate]Oo.
483 process.load("Configuration.StandardSequences.Geometry_cff")
488 #process.load("Configuration/StandardSequences/MagneticField_38T_cff")
489 process.load("Configuration.StandardSequences.MagneticField_0T_cff") # 0T runs
493 ## to apply misalignments
494 #TrackerDigiGeometryESModule.applyAlignment = True
497 ## Load and Configure OfflineValidation
499 process.load("Alignment.OfflineValidation.TrackerOfflineValidation_.oO[offlineValidationMode]Oo._cff")
500 process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..Tracks = 'TrackRefitter2'
501 process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..trajectoryInput = 'TrackRefitter2'
502 process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..moduleLevelHistsTransient = cms.bool(.oO[offlineModuleLevelHistsTransient]Oo.)
503 process.TFileService.fileName = '.oO[outputFile]Oo.'
509 process.p = cms.Path(process.offlineBeamSpot*process.AliMomConstraint1*process.TrackRefitter1*process.TrackerTrackHitFilter*process.HitFilteredTracks
510 *process.AlignmentTrackSelector*process.TrackRefitter2*process.seqTrackerOfflineValidation.oO[offlineValidationMode]Oo.)
517 TrackSelectionCosmicsDuringCollisions =
"""
519 process.AlignmentTrackSelector.applyBasicCuts = True
520 # Note that pMin is overridden and set to zero in
521 # the offlineTemplate0T
522 process.AlignmentTrackSelector.pMin = 4.
523 process.AlignmentTrackSelector.pMax = 9999.
524 process.AlignmentTrackSelector.ptMin = 0.
525 process.AlignmentTrackSelector.ptMax = 9999.
526 process.AlignmentTrackSelector.etaMin = -999.
527 process.AlignmentTrackSelector.etaMax = 999.
528 process.AlignmentTrackSelector.nHitMin = 8
529 process.AlignmentTrackSelector.nHitMin2D = 2
530 process.AlignmentTrackSelector.chi2nMax = 999.
531 process.AlignmentTrackSelector.applyMultiplicityFilter = False
532 process.AlignmentTrackSelector.maxMultiplicity = 1
533 process.AlignmentTrackSelector.applyNHighestPt = False
534 process.AlignmentTrackSelector.nHighestPt = 1
535 process.AlignmentTrackSelector.seedOnlyFrom = 0
536 process.AlignmentTrackSelector.applyIsolationCut = False
537 process.AlignmentTrackSelector.minHitIsolation = 0.8
538 process.AlignmentTrackSelector.applyChargeCheck = False
539 process.AlignmentTrackSelector.minHitChargeStrip = 50.
540 #process.AlignmentTrackSelector.trackQualities = ["highPurity"]
541 #process.AlignmentTrackSelector.iterativeTrackingSteps = ["iter1","iter2"]
544 process.TrackerTrackHitFilter.useTrajectories= True # this is needed only if you require some selections; but it will work even if you don't ask for them
545 process.TrackerTrackHitFilter.minimumHits = 8
546 process.TrackerTrackHitFilter.commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC")
547 process.TrackerTrackHitFilter.detsToIgnore = [
548 # see https://hypernews.cern.ch/HyperNews/CMS/get/tracker-performance/484.html
550 #369136710, 369136714, 402668822,
552 #436310989, 436310990, 436299301, 436299302,
554 #470340521, 470063045, 470063046, 470114669, 470114670, 470161093, 470161094, 470164333, 470164334, 470312005, 470312006, 470312009, 470067405, 470067406, 470128813
556 process.TrackerTrackHitFilter.replaceWithInactiveHits = True
557 process.TrackerTrackHitFilter.stripAllInvalidHits = False
558 process.TrackerTrackHitFilter.rejectBadStoNHits = True
559 process.TrackerTrackHitFilter.StoNcommands = cms.vstring("ALL 18.0")
560 process.TrackerTrackHitFilter.rejectLowAngleHits= True
561 process.TrackerTrackHitFilter.TrackAngleCut= 0.35 # in rads, starting from the module surface
562 process.TrackerTrackHitFilter.usePixelQualityFlag= True
564 #######################################
565 ##Trigger settings for Cosmics during collisions
566 #######################################
567 process.load('L1TriggerConfig.L1GtConfigProducers.L1GtTriggerMaskTechTrigConfig_cff')
568 process.load('HLTrigger/HLTfilters/hltLevel1GTSeed_cfi')
569 process.L1T1=process.hltLevel1GTSeed.clone()
570 process.L1T1.L1TechTriggerSeeding = cms.bool(True)
571 process.L1T1.L1SeedsLogicalExpression=cms.string('25')
572 process.hltHighLevel = cms.EDFilter("HLTHighLevel",
573 TriggerResultsTag = cms.InputTag("TriggerResults","","HLT"),
574 HLTPaths = cms.vstring('HLT_TrackerCosmics'),
575 eventSetupPathsKey = cms.string(''),
576 andOr = cms.bool(False),
577 throw = cms.bool(True)
581 process.triggerSelection=cms.Sequence(process.L1T1*process.hltHighLevel)
587 TrackSelectionCosmicsData =
"""
589 process.AlignmentTrackSelector.applyBasicCuts = True
590 # Note that pMin is overridden and set to zero in
591 # the offlineTemplate0T
592 process.AlignmentTrackSelector.pMin = 4.
593 process.AlignmentTrackSelector.pMax = 9999.
594 process.AlignmentTrackSelector.ptMin = 0.
595 process.AlignmentTrackSelector.ptMax = 9999.
596 process.AlignmentTrackSelector.etaMin = -999.
597 process.AlignmentTrackSelector.etaMax = 999.
598 process.AlignmentTrackSelector.nHitMin = 8
599 process.AlignmentTrackSelector.nHitMin2D = 2
600 process.AlignmentTrackSelector.chi2nMax = 999.
601 process.AlignmentTrackSelector.applyMultiplicityFilter = False
602 process.AlignmentTrackSelector.maxMultiplicity = 1
603 process.AlignmentTrackSelector.applyNHighestPt = False
604 process.AlignmentTrackSelector.nHighestPt = 1
605 process.AlignmentTrackSelector.seedOnlyFrom = 0
606 process.AlignmentTrackSelector.applyIsolationCut = False
607 process.AlignmentTrackSelector.minHitIsolation = 0.8
608 process.AlignmentTrackSelector.applyChargeCheck = False
609 process.AlignmentTrackSelector.minHitChargeStrip = 50.
610 #process.AlignmentTrackSelector.trackQualities = ["highPurity"]
611 #process.AlignmentTrackSelector.iterativeTrackingSteps = ["iter1","iter2"]
614 process.TrackerTrackHitFilter.useTrajectories= True # this is needed only if you require some selections; but it will work even if you don't ask for them
615 process.TrackerTrackHitFilter.minimumHits = 8
616 process.TrackerTrackHitFilter.commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC")
617 process.TrackerTrackHitFilter.detsToIgnore = [
618 # see https://hypernews.cern.ch/HyperNews/CMS/get/tracker-performance/484.html
620 #369136710, 369136714, 402668822,
622 #436310989, 436310990, 436299301, 436299302,
624 #470340521, 470063045, 470063046, 470114669, 470114670, 470161093, 470161094, 470164333, 470164334, 470312005, 470312006, 470312009, 470067405, 470067406, 470128813
626 process.TrackerTrackHitFilter.replaceWithInactiveHits = True
627 process.TrackerTrackHitFilter.stripAllInvalidHits = False
628 process.TrackerTrackHitFilter.rejectBadStoNHits = True
629 process.TrackerTrackHitFilter.StoNcommands = cms.vstring("ALL 18.0")
630 process.TrackerTrackHitFilter.rejectLowAngleHits= True
631 process.TrackerTrackHitFilter.TrackAngleCut= 0.35 # in rads, starting from the module surface
632 process.TrackerTrackHitFilter.usePixelQualityFlag= True
633 #process.TrackerTrackHitFilter.PxlCorrClusterChargeCut = 10000.0
634 #process.triggerSelection=cms.Sequence(process.hltPhysicsDeclared)
640 TrackSelectionCosmicsDataBPIX =
"""
642 process.AlignmentTrackSelector.applyBasicCuts = True
643 # Note that pMin is overridden and set to zero in
644 # the offlineTemplate0T
645 process.AlignmentTrackSelector.pMin = 4.
646 process.AlignmentTrackSelector.pMax = 9999.
647 process.AlignmentTrackSelector.ptMin = 0.
648 process.AlignmentTrackSelector.ptMax = 9999.
649 process.AlignmentTrackSelector.etaMin = -999.
650 process.AlignmentTrackSelector.etaMax = 999.
651 process.AlignmentTrackSelector.nHitMin = 8
652 process.AlignmentTrackSelector.nHitMin2D = 2
653 process.AlignmentTrackSelector.chi2nMax = 999.
654 process.AlignmentTrackSelector.applyMultiplicityFilter = False
655 process.AlignmentTrackSelector.maxMultiplicity = 1
656 process.AlignmentTrackSelector.applyNHighestPt = False
657 process.AlignmentTrackSelector.nHighestPt = 1
658 process.AlignmentTrackSelector.seedOnlyFrom = 0
659 process.AlignmentTrackSelector.applyIsolationCut = False
660 process.AlignmentTrackSelector.minHitIsolation = 0.8
661 process.AlignmentTrackSelector.applyChargeCheck = False
662 process.AlignmentTrackSelector.minHitChargeStrip = 50.
663 process.AlignmentTrackSelector.minHitsPerSubDet = cms.PSet(
664 inTEC = cms.int32(0),
665 inTOB = cms.int32(0),
666 inFPIX = cms.int32(0),
667 inTID = cms.int32(0),
668 inBPIX = cms.int32(1),
669 inTIB = cms.int32(0),
670 inPIXEL = cms.int32(0),
671 inTIDplus = cms.int32(0),
672 inTIDminus = cms.int32(0),
673 inTECplus = cms.int32(0),
674 inTECminus = cms.int32(0),
675 inFPIXplus = cms.int32(0),
676 inFPIXminus = cms.int32(0),
677 inENDCAP = cms.int32(0),
678 inENDCAPplus = cms.int32(0),
679 inENDCAPminus = cms.int32(0),
681 #process.AlignmentTrackSelector.trackQualities = ["highPurity"]
682 #process.AlignmentTrackSelector.iterativeTrackingSteps = ["iter1","iter2"]
685 process.TrackerTrackHitFilter.useTrajectories= True # this is needed only if you require some selections; but it will work even if you don't ask for them
686 process.TrackerTrackHitFilter.minimumHits = 8
687 process.TrackerTrackHitFilter.commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC")
688 process.TrackerTrackHitFilter.detsToIgnore = [
689 # see https://hypernews.cern.ch/HyperNews/CMS/get/tracker-performance/484.html
691 #369136710, 369136714, 402668822,
693 #436310989, 436310990, 436299301, 436299302,
695 #470340521, 470063045, 470063046, 470114669, 470114670, 470161093, 470161094, 470164333, 470164334, 470312005, 470312006, 470312009, 470067405, 470067406, 470128813
697 process.TrackerTrackHitFilter.replaceWithInactiveHits = True
698 process.TrackerTrackHitFilter.stripAllInvalidHits = False
699 process.TrackerTrackHitFilter.rejectBadStoNHits = True
700 process.TrackerTrackHitFilter.StoNcommands = cms.vstring("ALL 18.0")
701 process.TrackerTrackHitFilter.rejectLowAngleHits= True
702 process.TrackerTrackHitFilter.TrackAngleCut= 0.35 # in rads, starting from the module surface
703 process.TrackerTrackHitFilter.usePixelQualityFlag= True
705 process.triggerSelection=cms.Sequence(process.hltPhysicsDeclared)
711 TrackSelectionCosmicsDataFPIXplus =
"""
713 process.AlignmentTrackSelector.applyBasicCuts = True
714 # Note that pMin is overridden and set to zero in
715 # the offlineTemplate0T
716 process.AlignmentTrackSelector.pMin = 4.
717 process.AlignmentTrackSelector.pMax = 9999.
718 process.AlignmentTrackSelector.ptMin = 0.
719 process.AlignmentTrackSelector.ptMax = 9999.
720 process.AlignmentTrackSelector.etaMin = -999.
721 process.AlignmentTrackSelector.etaMax = 999.
722 process.AlignmentTrackSelector.nHitMin = 8
723 process.AlignmentTrackSelector.nHitMin2D = 2
724 process.AlignmentTrackSelector.chi2nMax = 999.
725 process.AlignmentTrackSelector.applyMultiplicityFilter = False
726 process.AlignmentTrackSelector.maxMultiplicity = 1
727 process.AlignmentTrackSelector.applyNHighestPt = False
728 process.AlignmentTrackSelector.nHighestPt = 1
729 process.AlignmentTrackSelector.seedOnlyFrom = 0
730 process.AlignmentTrackSelector.applyIsolationCut = False
731 process.AlignmentTrackSelector.minHitIsolation = 0.8
732 process.AlignmentTrackSelector.applyChargeCheck = False
733 process.AlignmentTrackSelector.minHitChargeStrip = 50.
734 process.AlignmentTrackSelector.minHitsPerSubDet = cms.PSet(
735 inTEC = cms.int32(0),
736 inTOB = cms.int32(0),
737 inFPIX = cms.int32(0),
738 inTID = cms.int32(0),
739 inBPIX = cms.int32(0),
740 inTIB = cms.int32(0),
741 inPIXEL = cms.int32(0),
742 inTIDplus = cms.int32(0),
743 inTIDminus = cms.int32(0),
744 inTECplus = cms.int32(0),
745 inTECminus = cms.int32(0),
746 inFPIXplus = cms.int32(1),
747 inFPIXminus = cms.int32(0),
748 inENDCAP = cms.int32(0),
749 inENDCAPplus = cms.int32(0),
750 inENDCAPminus = cms.int32(0),
752 #process.AlignmentTrackSelector.trackQualities = ["highPurity"]
753 #process.AlignmentTrackSelector.iterativeTrackingSteps = ["iter1","iter2"]
756 process.TrackerTrackHitFilter.useTrajectories= True # this is needed only if you require some selections; but it will work even if you don't ask for them
757 process.TrackerTrackHitFilter.minimumHits = 8
758 process.TrackerTrackHitFilter.commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC")
759 process.TrackerTrackHitFilter.detsToIgnore = [
760 # see https://hypernews.cern.ch/HyperNews/CMS/get/tracker-performance/484.html
762 #369136710, 369136714, 402668822,
764 #436310989, 436310990, 436299301, 436299302,
766 #470340521, 470063045, 470063046, 470114669, 470114670, 470161093, 470161094, 470164333, 470164334, 470312005, 470312006, 470312009, 470067405, 470067406, 470128813
768 process.TrackerTrackHitFilter.replaceWithInactiveHits = True
769 process.TrackerTrackHitFilter.stripAllInvalidHits = False
770 process.TrackerTrackHitFilter.rejectBadStoNHits = True
771 process.TrackerTrackHitFilter.StoNcommands = cms.vstring("ALL 18.0")
772 process.TrackerTrackHitFilter.rejectLowAngleHits= True
773 process.TrackerTrackHitFilter.TrackAngleCut= 0.35 # in rads, starting from the module surface
774 process.TrackerTrackHitFilter.usePixelQualityFlag= True
776 process.triggerSelection=cms.Sequence(process.hltPhysicsDeclared)
782 TrackSelectionCosmicsDataFPIXminus =
"""
784 process.AlignmentTrackSelector.applyBasicCuts = True
785 # Note that pMin is overridden and set to zero in
786 # the offlineTemplate0T
787 process.AlignmentTrackSelector.pMin = 4.
788 process.AlignmentTrackSelector.pMax = 9999.
789 process.AlignmentTrackSelector.ptMin = 0.
790 process.AlignmentTrackSelector.ptMax = 9999.
791 process.AlignmentTrackSelector.etaMin = -999.
792 process.AlignmentTrackSelector.etaMax = 999.
793 process.AlignmentTrackSelector.nHitMin = 8
794 process.AlignmentTrackSelector.nHitMin2D = 2
795 process.AlignmentTrackSelector.chi2nMax = 999.
796 process.AlignmentTrackSelector.applyMultiplicityFilter = False
797 process.AlignmentTrackSelector.maxMultiplicity = 1
798 process.AlignmentTrackSelector.applyNHighestPt = False
799 process.AlignmentTrackSelector.nHighestPt = 1
800 process.AlignmentTrackSelector.seedOnlyFrom = 0
801 process.AlignmentTrackSelector.applyIsolationCut = False
802 process.AlignmentTrackSelector.minHitIsolation = 0.8
803 process.AlignmentTrackSelector.applyChargeCheck = False
804 process.AlignmentTrackSelector.minHitChargeStrip = 50.
805 process.AlignmentTrackSelector.minHitsPerSubDet = cms.PSet(
806 inTEC = cms.int32(0),
807 inTOB = cms.int32(0),
808 inFPIX = cms.int32(0),
809 inTID = cms.int32(0),
810 inBPIX = cms.int32(0),
811 inTIB = cms.int32(0),
812 inPIXEL = cms.int32(0),
813 inTIDplus = cms.int32(0),
814 inTIDminus = cms.int32(0),
815 inTECplus = cms.int32(0),
816 inTECminus = cms.int32(0),
817 inFPIXplus = cms.int32(0),
818 inFPIXminus = cms.int32(1),
819 inENDCAP = cms.int32(0),
820 inENDCAPplus = cms.int32(0),
821 inENDCAPminus = cms.int32(0),
823 #process.AlignmentTrackSelector.trackQualities = ["highPurity"]
824 #process.AlignmentTrackSelector.iterativeTrackingSteps = ["iter1","iter2"]
827 process.TrackerTrackHitFilter.useTrajectories= True # this is needed only if you require some selections; but it will work even if you don't ask for them
828 process.TrackerTrackHitFilter.minimumHits = 8
829 process.TrackerTrackHitFilter.commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC")
830 process.TrackerTrackHitFilter.detsToIgnore = [
831 # see https://hypernews.cern.ch/HyperNews/CMS/get/tracker-performance/484.html
833 #369136710, 369136714, 402668822,
835 #436310989, 436310990, 436299301, 436299302,
837 #470340521, 470063045, 470063046, 470114669, 470114670, 470161093, 470161094, 470164333, 470164334, 470312005, 470312006, 470312009, 470067405, 470067406, 470128813
839 process.TrackerTrackHitFilter.replaceWithInactiveHits = True
840 process.TrackerTrackHitFilter.stripAllInvalidHits = False
841 process.TrackerTrackHitFilter.rejectBadStoNHits = True
842 process.TrackerTrackHitFilter.StoNcommands = cms.vstring("ALL 18.0")
843 process.TrackerTrackHitFilter.rejectLowAngleHits= True
844 process.TrackerTrackHitFilter.TrackAngleCut= 0.35 # in rads, starting from the module surface
845 process.TrackerTrackHitFilter.usePixelQualityFlag= True
847 process.triggerSelection=cms.Sequence(process.hltPhysicsDeclared)
853 TrackSelectionMinBiasData =
"""
854 ##### For Tracks:collisions taken in deco mode
855 process.AlignmentTrackSelector.applyBasicCuts = True
856 # Note that pMin is overridden and set to zero in
857 # the offlineTemplate0T
858 process.AlignmentTrackSelector.pMin = 3
859 process.AlignmentTrackSelector.pMax = 9999.
860 process.AlignmentTrackSelector.ptMin = 0.65
861 process.AlignmentTrackSelector.ptMax = 9999.
862 process.AlignmentTrackSelector.etaMin = -999.
863 process.AlignmentTrackSelector.etaMax = 999.
864 process.AlignmentTrackSelector.nHitMin = 8
865 process.AlignmentTrackSelector.nHitMin2D = 2
866 process.AlignmentTrackSelector.chi2nMax = 999.
867 process.AlignmentTrackSelector.applyMultiplicityFilter = False
868 process.AlignmentTrackSelector.maxMultiplicity = 1
869 process.AlignmentTrackSelector.applyNHighestPt = False
870 process.AlignmentTrackSelector.nHighestPt = 1
871 process.AlignmentTrackSelector.seedOnlyFrom = 0
872 process.AlignmentTrackSelector.applyIsolationCut = False
873 process.AlignmentTrackSelector.minHitIsolation = 0.8
874 process.AlignmentTrackSelector.applyChargeCheck = False
875 process.AlignmentTrackSelector.minHitChargeStrip = 50.
876 #process.AlignmentTrackSelector.trackQualities = ["highPurity"]
877 #process.AlignmentTrackSelector.iterativeTrackingSteps = ["iter1","iter2"]
880 process.TrackerTrackHitFilter.useTrajectories= True # this is needed only if you require some selections; but it will work even if you don't ask for them
881 process.TrackerTrackHitFilter.minimumHits = 8
882 process.TrackerTrackHitFilter.commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC")
883 process.TrackerTrackHitFilter.detsToIgnore = [
884 # see https://hypernews.cern.ch/HyperNews/CMS/get/tracker-performance/484.html
886 #369136710, 369136714, 402668822,
888 #436310989, 436310990, 436299301, 436299302,
891 #470340521, 470063045, 470063046, 470114669, 470114670, 470161093, 470161094, 470164333, 470164334, 470312005, 470312006, 470312009, 470067405, 470067406, 470128813
893 process.TrackerTrackHitFilter.replaceWithInactiveHits = True
894 process.TrackerTrackHitFilter.stripAllInvalidHits = False
895 process.TrackerTrackHitFilter.rejectBadStoNHits = True
896 process.TrackerTrackHitFilter.StoNcommands = cms.vstring("ALL 12.0")
897 process.TrackerTrackHitFilter.rejectLowAngleHits= True
898 process.TrackerTrackHitFilter.TrackAngleCut= 0.17 # in rads, starting from the module surface
899 process.TrackerTrackHitFilter.usePixelQualityFlag= True
904 #bit 0 is selecting bunch crossing
905 #bit 40 MinBias trigger
908 process.triggerSelection=cms.Sequence(process.oneGoodVertexFilter)
915 TrackSelectionIsolatedMuons =
"""
916 ##### For Tracks:collisions taken in deco mode
918 process.AlignmentTrackSelector.applyBasicCuts = True
919 # Note that pMin is overridden and set to zero in
920 # the offlineTemplate0T
921 process.AlignmentTrackSelector.pMin = 0
922 process.AlignmentTrackSelector.pMax = 9999.
923 process.AlignmentTrackSelector.ptMin = 3.
924 process.AlignmentTrackSelector.ptMax = 9999.
925 process.AlignmentTrackSelector.etaMin = -999.
926 process.AlignmentTrackSelector.etaMax = 999.
927 process.AlignmentTrackSelector.nHitMin = 8
928 process.AlignmentTrackSelector.nHitMin2D = 2
929 process.AlignmentTrackSelector.chi2nMax = 999.
930 process.AlignmentTrackSelector.applyMultiplicityFilter = False
931 process.AlignmentTrackSelector.maxMultiplicity = 1
932 process.AlignmentTrackSelector.applyNHighestPt = False
933 process.AlignmentTrackSelector.nHighestPt = 1
934 process.AlignmentTrackSelector.seedOnlyFrom = 0
935 process.AlignmentTrackSelector.applyIsolationCut = False
936 process.AlignmentTrackSelector.minHitIsolation = 0.8
937 process.AlignmentTrackSelector.applyChargeCheck = False
938 process.AlignmentTrackSelector.minHitChargeStrip = 50.
939 #process.AlignmentTrackSelector.trackQualities = ["highPurity"]
940 #process.AlignmentTrackSelector.iterativeTrackingSteps = ["iter1","iter2"]
943 process.TrackerTrackHitFilter.useTrajectories= True # this is needed only if you require some selections; but it will work even if you don't ask for them
944 process.TrackerTrackHitFilter.minimumHits = 8
945 process.TrackerTrackHitFilter.commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC")
946 process.TrackerTrackHitFilter.detsToIgnore = [
947 # see https://hypernews.cern.ch/HyperNews/CMS/get/tracker-performance/484.html
949 #369136710, 369136714, 402668822,
951 #436310989, 436310990, 436299301, 436299302,
953 #470340521, 470063045, 470063046, 470114669, 470114670, 470161093, 470161094, 470164333, 470164334, 470312005, 470312006, 470312009, 470067405, 470067406, 470128813
955 process.TrackerTrackHitFilter.replaceWithInactiveHits = True
956 process.TrackerTrackHitFilter.stripAllInvalidHits = False
957 process.TrackerTrackHitFilter.rejectBadStoNHits = True
958 process.TrackerTrackHitFilter.StoNcommands = cms.vstring("ALL 12.0")
959 process.TrackerTrackHitFilter.rejectLowAngleHits= True
960 process.TrackerTrackHitFilter.TrackAngleCut= 0.17 # in rads, starting from the module surface
961 process.TrackerTrackHitFilter.usePixelQualityFlag= True
966 #bit 0 is selecting bunch crossing
967 #bit xy for muons trigger
970 #process.triggerSelection=cms.Sequence(process.bptxAnd)
979 CosmicsOfflineValidation_Deformations=
"""
980 import FWCore.ParameterSet.Config as cms
982 process = cms.Process("OfflineValidator")
984 process.load("Alignment.OfflineValidation..oO[dataset]Oo._cff")
986 #process.source.inputCommands = cms.untracked.vstring('keep *', 'drop *_MEtoEDMConverter_*_*') # hack to get rid of the memory consumption problem in 2_2_X and beond
987 process.options = cms.untracked.PSet(
988 wantSummary = cms.untracked.bool(False),
989 Rethrow = cms.untracked.vstring("ProductNotFound"), # make this exception fatal
990 fileMode = cms.untracked.string('NOMERGE') # no ordering needed, but calls endRun/beginRun etc. at file boundaries
994 ## Maximum number of Events
996 process.maxEvents = cms.untracked.PSet(
997 input = cms.untracked.int32(.oO[nEvents]Oo.)
1001 ## Messages & Convenience
1003 process.load("FWCore.MessageLogger.MessageLogger_cfi")
1004 process.MessageLogger.cerr = cms.untracked.PSet(placeholder = cms.untracked.bool(True))
1005 process.MessageLogger.cout = cms.untracked.PSet(INFO = cms.untracked.PSet(
1006 reportEvery = cms.untracked.int32(1000) # every 1000th only
1007 # limit = cms.untracked.int32(10) # or limit to 10 printouts...
1009 process.MessageLogger.statistics.append('cout')
1012 #-- Track hit filter
1013 # TrackerTrackHitFilter takes as input the tracks/trajectories coming out from TrackRefitter1
1014 process.load("RecoTracker.FinalTrackSelectors.TrackerTrackHitFilter_cff")
1015 process.TrackerTrackHitFilter.src = 'TrackRefitter1'
1019 #-- Alignment Track Selection
1020 process.load("Alignment.CommonAlignmentProducer.AlignmentTrackSelector_cfi")
1021 process.AlignmentTrackSelector.src = 'HitFilteredTracks'
1022 process.AlignmentTrackSelector.filter = True
1024 .oO[TrackSelectionTemplate]Oo.
1026 #now we give the TrackCandidate coming out of the TrackerTrackHitFilter to the track producer
1027 import RecoTracker.TrackProducer.CTFFinalFitWithMaterialP5_cff
1028 process.HitFilteredTracks = RecoTracker.TrackProducer.CTFFinalFitWithMaterialP5_cff.ctfWithMaterialTracksCosmics.clone(
1029 src = 'TrackerTrackHitFilter',
1030 ### TrajectoryInEvent = True,
1031 NavigationSchool = '',
1032 TTRHBuilder = "WithAngleAndTemplate"
1036 ## Load and Configure TrackRefitter1
1041 process.load("RecoTracker.TrackProducer.TrackRefitters_cff")
1043 process.TrackRefitter1 = process.TrackRefitterP5.clone(
1044 src = 'ALCARECOTkAlCosmicsCTF0T',
1045 TrajectoryInEvent = True,
1046 NavigationSchool = '',
1047 TTRHBuilder = "WithAngleAndTemplate"
1049 process.TrackRefitter2 = process.TrackRefitter1.clone(
1050 src = 'AlignmentTrackSelector',
1058 process.load("RecoVertex.BeamSpotProducer.BeamSpot_cff")
1061 ## GlobalTag Conditions (if needed)
1063 process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
1064 # process.GlobalTag.connect = "frontier://FrontierProd/CMS_COND_31X_GLOBALTAG"
1065 process.GlobalTag.globaltag = ".oO[GlobalTag]Oo."
1068 .oO[LorentzAngleTemplate]Oo.
1073 process.load("Configuration.StandardSequences.Geometry_cff")
1078 process.load("Configuration/StandardSequences/MagneticField_38T_cff")
1082 from CondCore.DBCommon.CondDBSetup_cfi import *
1083 process.trackerSurfaces = cms.ESSource(
1086 connect = cms.string('.oO[dbpath]Oo.'),
1087 toGet = cms.VPSet(cms.PSet(record = cms.string("TrackerSurfaceDeformationRcd"),
1088 tag = cms.string("Deformations")
1092 process.es_prefer_trackerSurfaces = cms.ESPrefer("PoolDBESSource", "trackerSurfaces")
1094 ## to apply misalignments
1095 #TrackerDigiGeometryESModule.applyAlignment = True
1098 ## Load and Configure OfflineValidation
1101 process.load("Alignment.OfflineValidation.TrackerOfflineValidation_.oO[offlineValidationMode]Oo._cff")
1102 process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..Tracks = 'TrackRefitter2'
1103 process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..trajectoryInput = 'TrackRefitter2'
1104 #process.TrackerOfflineValidation.oO[offlineValidationMode]Oo..moduleLevelHistsTransient = cms.bool(.oO[offlineModuleLevelHistsTransient]Oo.)
1105 process.TrackerOfflineValidationStandalone.moduleLevelHistsTransient = cms.bool(False)
1106 process.TrackerOfflineValidationStandalone.moduleLevelProfiles = cms.bool(True)
1107 process.TFileService.fileName = '.oO[outputFile]Oo.'
1112 process.p = cms.Path(process.offlineBeamSpot*process.TrackRefitter1*process.TrackerTrackHitFilter*process.HitFilteredTracks
1113 *process.AlignmentTrackSelector*process.TrackRefitter2*process.seqTrackerOfflineValidation.oO[offlineValidationMode]Oo.)
1121 TrackSelectionCosmicsDataDef =
"""
1122 # import CalibTracker.Configuration.Common.PoolDBESSource_cfi
1123 # process.trackerBowedSensors = CalibTracker.Configuration.Common.PoolDBESSource_cfi.poolDBESSource.clone(
1124 # connect = cms.string('.oO[dbpath]Oo.'),
1126 # toGet = cms.VPSet(cms.PSet(record = cms.string('TrackerSurfaceDeformationRcd'),
1127 # tag = cms.string('Deformations')
1131 # process.prefer_trackerBowedSensors = cms.ESPrefer("PoolDBESSource", "trackerBowedSensors")
1133 process.AlignmentTrackSelector.applyBasicCuts = True
1134 # Note that pMin is overridden and set to zero in
1135 # the offlineTemplate0T
1136 process.AlignmentTrackSelector.pMin = 4.
1137 process.AlignmentTrackSelector.pMax = 9999.
1138 process.AlignmentTrackSelector.ptMin = 0.
1139 process.AlignmentTrackSelector.ptMax = 9999.
1140 process.AlignmentTrackSelector.etaMin = -999.
1141 process.AlignmentTrackSelector.etaMax = 999.
1142 process.AlignmentTrackSelector.nHitMin = 8
1143 process.AlignmentTrackSelector.nHitMin2D = 2
1144 process.AlignmentTrackSelector.chi2nMax = 999.
1145 process.AlignmentTrackSelector.applyMultiplicityFilter = True
1146 process.AlignmentTrackSelector.maxMultiplicity = 1
1147 process.AlignmentTrackSelector.applyNHighestPt = False
1148 process.AlignmentTrackSelector.nHighestPt = 1
1149 process.AlignmentTrackSelector.seedOnlyFrom = 0
1150 process.AlignmentTrackSelector.applyIsolationCut = False
1151 process.AlignmentTrackSelector.minHitIsolation = 0.8
1152 process.AlignmentTrackSelector.applyChargeCheck = False
1153 process.AlignmentTrackSelector.minHitChargeStrip = 50.
1154 #process.AlignmentTrackSelector.trackQualities = ["highPurity"]
1155 #process.AlignmentTrackSelector.iterativeTrackingSteps = ["iter1","iter2"]
1158 process.TrackerTrackHitFilter.useTrajectories= True # this is needed only if you require some selections; but it will work even if you don't ask for them
1159 process.TrackerTrackHitFilter.minimumHits = 8
1160 process.TrackerTrackHitFilter.commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC")
1161 process.TrackerTrackHitFilter.detsToIgnore = [
1162 # see https://hypernews.cern.ch/HyperNews/CMS/get/tracker-performance/484.html
1164 #369136710, 369136714, 402668822,
1166 #436310989, 436310990, 436299301, 436299302,
1168 #470340521, 470063045, 470063046, 470114669, 470114670, 470161093, 470161094, 470164333, 470164334, 470312005, 470312006, 470312009, 470067405, 470067406, 470128813
1170 process.TrackerTrackHitFilter.replaceWithInactiveHits = True
1171 process.TrackerTrackHitFilter.stripAllInvalidHits = False
1172 process.TrackerTrackHitFilter.rejectBadStoNHits = True
1173 process.TrackerTrackHitFilter.StoNcommands = cms.vstring("ALL 18.0")
1174 process.TrackerTrackHitFilter.rejectLowAngleHits= True
1175 process.TrackerTrackHitFilter.TrackAngleCut= 0.35 # in rads, starting from the module surface
1176 process.TrackerTrackHitFilter.usePixelQualityFlag= True
1177 #process.TrackerTrackHitFilter.PxlCorrClusterChargeCut = 10000.0
1178 process.triggerSelection=cms.Sequence(process.hltPhysicsDeclared)
1184 TrackSelectionCosmicsInterfillLADef =
"""
1185 # import CalibTracker.Configuration.Common.PoolDBESSource_cfi
1186 # process.trackerBowedSensors = CalibTracker.Configuration.Common.PoolDBESSource_cfi.poolDBESSource.clone(
1187 # connect = cms.string('.oO[dbpath]Oo.'),
1189 # toGet = cms.VPSet(cms.PSet(record = cms.string('TrackerSurfaceDeformationRcd'),
1190 # tag = cms.string('Deformations')
1194 # process.prefer_trackerBowedSensors = cms.ESPrefer("PoolDBESSource", "trackerBowedSensors")
1197 process.myLA = CalibTracker.Configuration.Common.PoolDBESSource_cfi.poolDBESSource.clone(
1198 connect = cms.string ('frontier://PromptProd/CMS_COND_31X_STRIP'),
1199 toGet = cms.VPSet(cms.PSet(
1200 record = cms.string('SiStripLorentzAngleRcd'),
1201 tag = cms.string('SiStripLorentzAnglePeak_GR10_v1_offline')
1205 process.es_prefer_myLA = cms.ESPrefer("PoolDBESSource","myLA")
1207 #-- initialize beam spot
1208 process.load("RecoVertex.BeamSpotProducer.BeamSpot_cfi")
1211 process.AlignmentTrackSelector.applyBasicCuts = True
1212 # Note that pMin is overridden and set to zero in
1213 # the offlineTemplate0T
1214 process.AlignmentTrackSelector.pMin = 4.
1215 process.AlignmentTrackSelector.pMax = 9999.
1216 process.AlignmentTrackSelector.ptMin = 0.
1217 process.AlignmentTrackSelector.ptMax = 9999.
1218 process.AlignmentTrackSelector.etaMin = -999.
1219 process.AlignmentTrackSelector.etaMax = 999.
1220 process.AlignmentTrackSelector.nHitMin = 8
1221 process.AlignmentTrackSelector.nHitMin2D = 2
1222 process.AlignmentTrackSelector.chi2nMax = 999.
1223 process.AlignmentTrackSelector.applyMultiplicityFilter = False
1224 process.AlignmentTrackSelector.maxMultiplicity = 1
1225 process.AlignmentTrackSelector.applyNHighestPt = False
1226 process.AlignmentTrackSelector.nHighestPt = 1
1227 process.AlignmentTrackSelector.seedOnlyFrom = 0
1228 process.AlignmentTrackSelector.applyIsolationCut = False
1229 process.AlignmentTrackSelector.minHitIsolation = 0.8
1230 process.AlignmentTrackSelector.applyChargeCheck = False
1231 process.AlignmentTrackSelector.minHitChargeStrip = 50.
1232 #process.AlignmentTrackSelector.trackQualities = ["highPurity"]
1233 #process.AlignmentTrackSelector.iterativeTrackingSteps = ["iter1","iter2"]
1236 process.TrackerTrackHitFilter.useTrajectories= True # this is needed only if you require some selections; but it will work even if you don't ask for them
1237 process.TrackerTrackHitFilter.minimumHits = 8
1238 process.TrackerTrackHitFilter.commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC")
1239 process.TrackerTrackHitFilter.detsToIgnore = [
1240 # see https://hypernews.cern.ch/HyperNews/CMS/get/tracker-performance/484.html
1242 #369136710, 369136714, 402668822,
1244 #436310989, 436310990, 436299301, 436299302,
1246 #470340521, 470063045, 470063046, 470114669, 470114670, 470161093, 470161094, 470164333, 470164334, 470312005, 470312006, 470312009, 470067405, 470067406, 470128813
1248 process.TrackerTrackHitFilter.replaceWithInactiveHits = True
1249 process.TrackerTrackHitFilter.stripAllInvalidHits = False
1250 process.TrackerTrackHitFilter.rejectBadStoNHits = True
1251 process.TrackerTrackHitFilter.StoNcommands = cms.vstring("ALL 18.0")
1252 process.TrackerTrackHitFilter.rejectLowAngleHits= True
1253 process.TrackerTrackHitFilter.TrackAngleCut= 0.35 # in rads, starting from the module surface
1254 process.TrackerTrackHitFilter.usePixelQualityFlag= True
1256 #######################################
1257 ##Trigger settings for Cosmics during collisions
1258 #######################################
1259 process.load('L1TriggerConfig.L1GtConfigProducers.L1GtTriggerMaskTechTrigConfig_cff')
1260 process.load('HLTrigger/HLTfilters/hltLevel1GTSeed_cfi')
1261 process.L1T1=process.hltLevel1GTSeed.clone()
1262 process.L1T1.L1TechTriggerSeeding = cms.bool(True)
1263 process.L1T1.L1SeedsLogicalExpression=cms.string('25')
1264 process.hltHighLevel = cms.EDFilter("HLTHighLevel",
1265 TriggerResultsTag = cms.InputTag("TriggerResults","","HLT"),
1266 HLTPaths = cms.vstring('HLT_TrackerCosmics'),
1267 eventSetupPathsKey = cms.string(''),
1268 andOr = cms.bool(False),
1269 throw = cms.bool(True)
1273 process.triggerSelection=cms.Sequence(process.L1T1*process.hltHighLevel)
1279 TrackSelectionMinBiasDataDef =
"""
1280 # import CalibTracker.Configuration.Common.PoolDBESSource_cfi
1281 # process.trackerBowedSensors = CalibTracker.Configuration.Common.PoolDBESSource_cfi.poolDBESSource.clone(
1282 # connect = cms.string('.oO[dbpath]Oo.'),
1284 # toGet = cms.VPSet(cms.PSet(record = cms.string('TrackerSurfaceDeformationRcd'),
1285 # tag = cms.string('Deformations')
1289 # process.prefer_trackerBowedSensors = cms.ESPrefer("PoolDBESSource", "trackerBowedSensors")
1291 ##### For Tracks:collisions taken in deco mode
1292 process.AlignmentTrackSelector.applyBasicCuts = True
1293 # Note that pMin is overridden and set to zero in
1294 # the offlineTemplate0T
1295 process.AlignmentTrackSelector.pMin = 3
1296 process.AlignmentTrackSelector.pMax = 9999.
1297 process.AlignmentTrackSelector.ptMin = 0.65
1298 process.AlignmentTrackSelector.ptMax = 9999.
1299 process.AlignmentTrackSelector.etaMin = -999.
1300 process.AlignmentTrackSelector.etaMax = 999.
1301 process.AlignmentTrackSelector.nHitMin = 8
1302 process.AlignmentTrackSelector.nHitMin2D = 2
1303 process.AlignmentTrackSelector.chi2nMax = 999.
1304 process.AlignmentTrackSelector.applyMultiplicityFilter = False
1305 process.AlignmentTrackSelector.maxMultiplicity = 1
1306 process.AlignmentTrackSelector.applyNHighestPt = False
1307 process.AlignmentTrackSelector.nHighestPt = 1
1308 process.AlignmentTrackSelector.seedOnlyFrom = 0
1309 process.AlignmentTrackSelector.applyIsolationCut = False
1310 process.AlignmentTrackSelector.minHitIsolation = 0.8
1311 process.AlignmentTrackSelector.applyChargeCheck = False
1312 process.AlignmentTrackSelector.minHitChargeStrip = 50.
1313 #process.AlignmentTrackSelector.trackQualities = ["highPurity"]
1314 #process.AlignmentTrackSelector.iterativeTrackingSteps = ["iter1","iter2"]
1317 process.TrackerTrackHitFilter.useTrajectories= True # this is needed only if you require some selections; but it will work even if you don't ask for them
1318 process.TrackerTrackHitFilter.minimumHits = 8
1319 process.TrackerTrackHitFilter.commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC")
1320 process.TrackerTrackHitFilter.detsToIgnore = [
1321 # see https://hypernews.cern.ch/HyperNews/CMS/get/tracker-performance/484.html
1323 #369136710, 369136714, 402668822,
1325 #436310989, 436310990, 436299301, 436299302,
1328 #470340521, 470063045, 470063046, 470114669, 470114670, 470161093, 470161094, 470164333, 470164334, 470312005, 470312006, 470312009, 470067405, 470067406, 470128813
1330 process.TrackerTrackHitFilter.replaceWithInactiveHits = True
1331 process.TrackerTrackHitFilter.stripAllInvalidHits = False
1332 process.TrackerTrackHitFilter.rejectBadStoNHits = True
1333 process.TrackerTrackHitFilter.StoNcommands = cms.vstring("ALL 12.0")
1334 process.TrackerTrackHitFilter.rejectLowAngleHits= True
1335 process.TrackerTrackHitFilter.TrackAngleCut= 0.17 # in rads, starting from the module surface
1336 process.TrackerTrackHitFilter.usePixelQualityFlag= True
1341 #bit 0 is selecting bunch crossing
1342 #bit 40 MinBias trigger
1345 process.triggerSelection=cms.Sequence(process.oneGoodVertexFilter)
1352 TrackSelectionIsolatedMuonsDef =
"""
1353 ##### For Tracks:collisions taken in deco mode
1354 # import CalibTracker.Configuration.Common.PoolDBESSource_cfi
1355 # process.trackerBowedSensors = CalibTracker.Configuration.Common.PoolDBESSource_cfi.poolDBESSource.clone(
1356 # connect = cms.string('.oO[dbpath]Oo.'),
1358 # toGet = cms.VPSet(cms.PSet(record = cms.string('TrackerSurfaceDeformationRcd'),
1359 # tag = cms.string('Deformations')
1363 # process.prefer_trackerBowedSensors = cms.ESPrefer("PoolDBESSource", "trackerBowedSensors")
1366 process.AlignmentTrackSelector.applyBasicCuts = True
1367 # Note that pMin is overridden and set to zero in
1368 # the offlineTemplate0T
1369 process.AlignmentTrackSelector.pMin = 3.
1370 process.AlignmentTrackSelector.pMax = 9999.
1371 process.AlignmentTrackSelector.ptMin = 5.
1372 process.AlignmentTrackSelector.ptMax = 9999.
1373 process.AlignmentTrackSelector.etaMin = -3.
1374 process.AlignmentTrackSelector.etaMax = 3.
1375 process.AlignmentTrackSelector.nHitMin = 10
1376 process.AlignmentTrackSelector.nHitMin2D = 2
1377 process.AlignmentTrackSelector.chi2nMax = 999.
1378 process.AlignmentTrackSelector.applyMultiplicityFilter = False
1379 process.AlignmentTrackSelector.maxMultiplicity = 1
1380 process.AlignmentTrackSelector.applyNHighestPt = False
1381 process.AlignmentTrackSelector.nHighestPt = 1
1382 process.AlignmentTrackSelector.seedOnlyFrom = 0
1383 process.AlignmentTrackSelector.applyIsolationCut = False
1384 process.AlignmentTrackSelector.minHitIsolation = 0.8
1385 process.AlignmentTrackSelector.applyChargeCheck = False
1386 process.AlignmentTrackSelector.minHitChargeStrip = 30.
1387 #process.AlignmentTrackSelector.trackQualities = ["highPurity"]
1388 #process.AlignmentTrackSelector.iterativeTrackingSteps = ["iter1","iter2"]
1391 process.TrackerTrackHitFilter.useTrajectories= True # this is needed only if you require some selections; but it will work even if you don't ask for them
1392 process.TrackerTrackHitFilter.minimumHits = 8
1393 process.TrackerTrackHitFilter.commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC")
1394 process.TrackerTrackHitFilter.detsToIgnore = [
1395 # see https://hypernews.cern.ch/HyperNews/CMS/get/tracker-performance/484.html
1397 #369136710, 369136714, 402668822,
1399 #436310989, 436310990, 436299301, 436299302,
1401 #470340521, 470063045, 470063046, 470114669, 470114670, 470161093, 470161094, 470164333, 470164334, 470312005, 470312006, 470312009, 470067405, 470067406, 470128813
1403 process.TrackerTrackHitFilter.replaceWithInactiveHits = True
1404 process.TrackerTrackHitFilter.stripAllInvalidHits = False
1405 process.TrackerTrackHitFilter.rejectBadStoNHits = True
1406 process.TrackerTrackHitFilter.StoNcommands = cms.vstring("ALL 12.0")
1407 process.TrackerTrackHitFilter.rejectLowAngleHits= True
1408 process.TrackerTrackHitFilter.TrackAngleCut= 0.17 # in rads, starting from the module surface
1409 process.TrackerTrackHitFilter.usePixelQualityFlag= True
1414 #bit 0 is selecting bunch crossing
1415 #bit xy for muons trigger
1418 #process.triggerSelection=cms.Sequence(process.bptxAnd)