CMS 3D CMS Logo

Functions

phase1TkCustoms Namespace Reference

Functions

def add_detailed_pixel_dqm
def customise
def customise_condOverRides
def customise_Digi
def customise_DigiToRaw
def customise_DQM
def customise_harvesting
def customise_RawToDigi
def customise_Reco
def customise_Validation
def remove_pixel_ineff

Function Documentation

def phase1TkCustoms::add_detailed_pixel_dqm (   process)

Definition at line 129 of file phase1TkCustoms.py.

00130                                    :
00131     #enable modOn
00132     process.SiPixelRawDataErrorSource.modOn = cms.untracked.bool(True)
00133     process.SiPixelDigiSource.modOn = cms.untracked.bool(True)
00134     process.SiPixelClusterSource.modOn = cms.untracked.bool(True)
00135     process.SiPixelRecHitSource.modOn = cms.untracked.bool(True)
00136     process.SiPixelTrackResidualSource.modOn = cms.untracked.bool(True)
00137     process.SiPixelHitEfficiencySource.modOn = cms.untracked.bool(True)
00138 
00139     return process
00140 

def phase1TkCustoms::customise (   process)

Definition at line 7 of file phase1TkCustoms.py.

00008                       :
00009     if hasattr(process,'DigiToRaw'):
00010         process=customise_DigiToRaw(process)
00011     if hasattr(process,'RawToDigi'):
00012         process=customise_RawToDigi(process)
00013     n=0
00014     if hasattr(process,'reconstruction') or hasattr(process,'dqmoffline_step'):
00015         if hasattr(process,'mix'): 
00016             if hasattr(process.mix,'input'):
00017                 n=process.mix.input.nbPileupEvents.averageNumber.value()
00018         else:
00019             print 'phase1TkCustoms requires a --pileup option to cmsDriver to run the reconstruction/dqm'
00020             print 'Please provide one!'
00021             sys.exit(1)
00022     if hasattr(process,'reconstruction'):
00023         process=customise_Reco(process,float(n))
00024                 
00025     if hasattr(process,'digitisation_step'):
00026         process=customise_Digi(process)
00027     if hasattr(process,'dqmoffline_step'):
00028         process=customise_DQM(process,n)
00029     if hasattr(process,'dqmHarvesting'):
00030         process=customise_harvesting(process)
00031     if hasattr(process,'validation_step'):
00032         process=customise_Validation(process)
00033     process=customise_condOverRides(process)
00034     
00035     return process

def phase1TkCustoms::customise_condOverRides (   process)

Definition at line 115 of file phase1TkCustoms.py.

00116                                     :
00117     process.load('SLHCUpgradeSimulations.Geometry.fakeConditions_Phase1_R30F12_cff')
00118     process.trackerTopologyConstants.pxb_layerStartBit = cms.uint32(20)
00119     process.trackerTopologyConstants.pxb_ladderStartBit = cms.uint32(12)
00120     process.trackerTopologyConstants.pxb_moduleStartBit = cms.uint32(2)
00121     process.trackerTopologyConstants.pxb_layerMask = cms.uint32(15)
00122     process.trackerTopologyConstants.pxb_ladderMask = cms.uint32(255)
00123     process.trackerTopologyConstants.pxb_moduleMask = cms.uint32(1023)
00124     process.trackerTopologyConstants.pxf_diskStartBit = cms.uint32(18)
00125     process.trackerTopologyConstants.pxf_bladeStartBit = cms.uint32(12)
00126     process.trackerTopologyConstants.pxf_panelStartBit = cms.uint32(10)
00127     process.trackerTopologyConstants.pxf_moduleMask = cms.uint32(255)
00128     return process

def phase1TkCustoms::customise_Digi (   process)

Definition at line 46 of file phase1TkCustoms.py.

00047                            :
00048     process.mix.digitizers.pixel.MissCalibrate = False
00049     process.mix.digitizers.pixel.LorentzAngle_DB = False
00050     process.mix.digitizers.pixel.killModules = False
00051     process.mix.digitizers.pixel.useDB = False
00052     process.mix.digitizers.pixel.DeadModules_DB = False
00053     process.mix.digitizers.pixel.NumPixelBarrel = cms.int32(4)
00054     process.mix.digitizers.pixel.NumPixelEndcap = cms.int32(3)
00055     process.mix.digitizers.pixel.ThresholdInElectrons_FPix = cms.double(2000.0)
00056     process.mix.digitizers.pixel.ThresholdInElectrons_BPix = cms.double(2000.0)
00057     process.mix.digitizers.pixel.ThresholdInElectrons_BPix_L1 = cms.double(2000.0)
00058     process.mix.digitizers.pixel.thePixelColEfficiency_BPix4 = cms.double(0.999)
00059     process.mix.digitizers.pixel.thePixelEfficiency_BPix4 = cms.double(0.999)
00060     process.mix.digitizers.pixel.thePixelChipEfficiency_BPix4 = cms.double(0.999)
00061     process.mix.digitizers.pixel.thePixelColEfficiency_FPix3 = cms.double(0.999)
00062     process.mix.digitizers.pixel.thePixelEfficiency_FPix3 = cms.double(0.999)
00063     process.mix.digitizers.pixel.thePixelChipEfficiency_FPix3 = cms.double(0.999)
00064     process.mix.digitizers.pixel.AddPixelInefficiencyFromPython = cms.bool(True)
00065 
00066     process=customise_pixelMixing_PU(process)
00067     return process
00068 
00069 
# DQM steps change
def phase1TkCustoms::customise_DigiToRaw (   process)

Definition at line 36 of file phase1TkCustoms.py.

00037                                 :
00038     process.digi2raw_step.remove(process.siPixelRawData)
00039     process.digi2raw_step.remove(process.castorRawData)
00040     return process

def phase1TkCustoms::customise_DQM (   process,
  pileup 
)

Definition at line 70 of file phase1TkCustoms.py.

00071                                  :
00072     # We cut down the number of iterative tracking steps
00073 #    process.dqmoffline_step.remove(process.TrackMonStep3)
00074 #    process.dqmoffline_step.remove(process.TrackMonStep4)
00075 #    process.dqmoffline_step.remove(process.TrackMonStep5)
00076 #    process.dqmoffline_step.remove(process.TrackMonStep6)
00077     #
00078     process.dqmoffline_step.remove(process.muonAnalyzer)
00079     process.dqmoffline_step.remove(process.jetMETAnalyzer)
00080 #    process.dqmoffline_step.remove(process.TrackMonStep9)
00081 #    process.dqmoffline_step.remove(process.TrackMonStep10)
00082 #    process.dqmoffline_step.remove(process.PixelTrackingRecHitsValid)
00083 
00084     #put isUpgrade flag==true
00085     process.SiPixelRawDataErrorSource.isUpgrade = cms.untracked.bool(True)
00086     process.SiPixelDigiSource.isUpgrade = cms.untracked.bool(True)
00087     process.SiPixelClusterSource.isUpgrade = cms.untracked.bool(True)
00088     process.SiPixelRecHitSource.isUpgrade = cms.untracked.bool(True)
00089     process.SiPixelTrackResidualSource.isUpgrade = cms.untracked.bool(True)
00090     process.SiPixelHitEfficiencySource.isUpgrade = cms.untracked.bool(True)
00091 
00092     from DQM.TrackingMonitor.customizeTrackingMonitorSeedNumber import customise_trackMon_IterativeTracking_PHASE1PU140
00093     from DQM.TrackingMonitor.customizeTrackingMonitorSeedNumber import customise_trackMon_IterativeTracking_PHASE1PU70
00094 
00095     if pileup>100:
00096         process=customise_trackMon_IterativeTracking_PHASE1PU140(process)
00097     else:
00098         process=customise_trackMon_IterativeTracking_PHASE1PU70(process)
00099     return process

def phase1TkCustoms::customise_harvesting (   process)

Definition at line 108 of file phase1TkCustoms.py.

00109                                  :
00110     process.dqmHarvesting.remove(process.jetMETDQMOfflineClient)
00111     process.dqmHarvesting.remove(process.dataCertificationJetMET)
00112     process.dqmHarvesting.remove(process.sipixelEDAClient)
00113     process.dqmHarvesting.remove(process.sipixelCertification)
00114     return (process)        

def phase1TkCustoms::customise_RawToDigi (   process)

Definition at line 41 of file phase1TkCustoms.py.

00042                                 :
00043     process.raw2digi_step.remove(process.siPixelDigis)
00044     process.raw2digi_step.remove(process.castorDigis)
00045     return process

def phase1TkCustoms::customise_Reco (   process,
  pileup 
)

Definition at line 148 of file phase1TkCustoms.py.

00149                                   :
00150 
00151     #this code supports either 70 or 140 pileup configurations - should fix as to support 0
00152     nPU=70
00153     if pileup>100: nPU=140
00154     
00155     #use with latest pixel geometry
00156     process.ClusterShapeHitFilterESProducer.PixelShapeFile = cms.string('RecoPixelVertexing/PixelLowPtUtilities/data/pixelShape_Phase1Tk.par')
00157     # Need this line to stop error about missing siPixelDigis.
00158     process.MeasurementTracker.inactivePixelDetectorLabels = cms.VInputTag()
00159 
00160     # new layer list (3/4 pixel seeding) in InitialStep and pixelTracks
00161     process.pixellayertriplets.layerList = cms.vstring( 'BPix1+BPix2+BPix3',
00162                                                         'BPix2+BPix3+BPix4',
00163                                                         'BPix1+BPix3+BPix4',
00164                                                         'BPix1+BPix2+BPix4',
00165                                                         'BPix2+BPix3+FPix1_pos',
00166                                                         'BPix2+BPix3+FPix1_neg',
00167                                                         'BPix1+BPix2+FPix1_pos',
00168                                                         'BPix1+BPix2+FPix1_neg',
00169                                                         'BPix2+FPix1_pos+FPix2_pos',
00170                                                         'BPix2+FPix1_neg+FPix2_neg',
00171                                                         'BPix1+FPix1_pos+FPix2_pos',
00172                                                         'BPix1+FPix1_neg+FPix2_neg',
00173                                                         'FPix1_pos+FPix2_pos+FPix3_pos',
00174                                                         'FPix1_neg+FPix2_neg+FPix3_neg' )
00175 
00176     # New tracking.  This is really ugly because it redefines globalreco and reconstruction.
00177     # It can be removed if change one line in Configuration/StandardSequences/python/Reconstruction_cff.py
00178     # from RecoTracker_cff.py to RecoTrackerPhase1PU140_cff.py
00179 
00180     # remove all the tracking first
00181     itIndex=process.globalreco.index(process.trackingGlobalReco)
00182     grIndex=process.reconstruction.index(process.globalreco)
00183 
00184     process.reconstruction.remove(process.globalreco)
00185     process.globalreco.remove(process.iterTracking)
00186     process.globalreco.remove(process.electronSeedsSeq)
00187     process.reconstruction_fromRECO.remove(process.trackingGlobalReco)
00188     del process.iterTracking
00189     del process.ckftracks
00190     del process.ckftracks_woBH
00191     del process.ckftracks_wodEdX
00192     del process.ckftracks_plus_pixelless
00193     del process.trackingGlobalReco
00194     del process.electronSeedsSeq
00195     del process.InitialStep
00196     del process.LowPtTripletStep
00197     del process.PixelPairStep
00198     del process.DetachedTripletStep
00199     del process.MixedTripletStep
00200     del process.PixelLessStep
00201     del process.TobTecStep
00202     del process.earlyGeneralTracks
00203     del process.ConvStep
00204     # add the correct tracking back in
00205     process.load("RecoTracker.Configuration.RecoTrackerPhase1PU"+str(nPU)+"_cff")
00206 
00207     process.globalreco.insert(itIndex,process.trackingGlobalReco)
00208     process.reconstruction.insert(grIndex,process.globalreco)
00209     #Note process.reconstruction_fromRECO is broken
00210     
00211     # End of new tracking configuration which can be removed if new Reconstruction is used.
00212 
00213 
00214     process.reconstruction.remove(process.castorreco)
00215     process.reconstruction.remove(process.CastorTowerReco)
00216     process.reconstruction.remove(process.ak7BasicJets)
00217     process.reconstruction.remove(process.ak7CastorJetID)
00218 
00219     #the quadruplet merger configuration     
00220     process.load("RecoPixelVertexing.PixelTriplets.quadrupletseedmerging_cff")
00221     process.pixelseedmergerlayers.BPix.TTRHBuilder = cms.string("PixelTTRHBuilderWithoutAngle" )
00222     process.pixelseedmergerlayers.BPix.HitProducer = cms.string("siPixelRecHits" )
00223     process.pixelseedmergerlayers.FPix.TTRHBuilder = cms.string("PixelTTRHBuilderWithoutAngle" )
00224     process.pixelseedmergerlayers.FPix.HitProducer = cms.string("siPixelRecHits" )    
00225     
00226     # Need these until pixel templates are used
00227     process.load("SLHCUpgradeSimulations.Geometry.recoFromSimDigis_cff")
00228     # PixelCPEGeneric #
00229     process.PixelCPEGenericESProducer.Upgrade = cms.bool(True)
00230     process.PixelCPEGenericESProducer.UseErrorsFromTemplates = cms.bool(False)
00231     process.PixelCPEGenericESProducer.LoadTemplatesFromDB = cms.bool(False)
00232     process.PixelCPEGenericESProducer.TruncatePixelCharge = cms.bool(False)
00233     process.PixelCPEGenericESProducer.IrradiationBiasCorrection = False
00234     process.PixelCPEGenericESProducer.DoCosmics = False
00235     # CPE for other steps
00236     process.siPixelRecHits.CPE = cms.string('PixelCPEGeneric')
00237     # Turn of template use in tracking (iterative steps handled inside their configs)
00238     process.mergedDuplicateTracks.TTRHBuilder = 'WithTrackAngle'
00239     process.ctfWithMaterialTracks.TTRHBuilder = 'WithTrackAngle'
00240     process.muonSeededSeedsInOut.TrackerRecHitBuilder=cms.string('WithTrackAngle')
00241     process.muonSeededTracksInOut.TTRHBuilder=cms.string('WithTrackAngle')
00242     process.muonSeededTracksOutIn.TTRHBuilder=cms.string('WithTrackAngle')
00243     process.muons1stStep.TrackerKinkFinderParameters.TrackerRecHitBuilder=cms.string('WithTrackAngle')
00244     process.regionalCosmicTracks.TTRHBuilder=cms.string('WithTrackAngle')
00245     process.cosmicsVetoTracksRaw.TTRHBuilder=cms.string('WithTrackAngle')
00246     # End of pixel template needed section
00247     
00248     # Make pixelTracks use quadruplets
00249     process.pixelTracks.SeedMergerPSet = cms.PSet(
00250         layerListName = cms.string('PixelSeedMergerQuadruplets'),
00251         addRemainingTriplets = cms.bool(False),
00252         mergeTriplets = cms.bool(True),
00253         ttrhBuilderLabel = cms.string('PixelTTRHBuilderWithoutAngle')
00254         )
00255     process.pixelTracks.FilterPSet.chi2 = cms.double(50.0)
00256     process.pixelTracks.FilterPSet.tipMax = cms.double(0.05)
00257     process.pixelTracks.RegionFactoryPSet.RegionPSet.originRadius =  cms.double(0.02)
00258 
00259 
00260 
00261     return process
def phase1TkCustoms::customise_Validation (   process)

Definition at line 100 of file phase1TkCustoms.py.

00101                                  :
00102     process.validation_step.remove(process.PixelTrackingRecHitsValid)
00103     # We don't run the HLT
00104     process.validation_step.remove(process.HLTSusyExoVal)
00105     process.validation_step.remove(process.hltHiggsValidator)
00106     process.validation_step.remove(process.relvalMuonBits)
00107     return process

def phase1TkCustoms::remove_pixel_ineff (   process)

Definition at line 141 of file phase1TkCustoms.py.

00142                                :
00143     if hasattr(process,'mix'):
00144         process.mix.digitizers.pixel.AddPixelInefficiencyFromPython = cms.bool(False) 
00145 
00146     return process
00147