Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2023-03-17 11:19:34

0001 import FWCore.ParameterSet.Config as cms
0002 from Configuration.Eras.Modifier_run3_common_cff import run3_common
0003 from Configuration.ProcessModifiers.gpu_cff import gpu
0004 
0005 # conditions used *only* by the modules running on GPU
0006 from CalibTracker.SiPixelESProducers.siPixelROCsStatusAndMappingWrapperESProducer_cfi import siPixelROCsStatusAndMappingWrapperESProducer
0007 from CalibTracker.SiPixelESProducers.siPixelGainCalibrationForHLTGPU_cfi import siPixelGainCalibrationForHLTGPU
0008 
0009 # SwitchProducer wrapping the legacy pixel cluster producer or an alias for the pixel clusters information converted from SoA
0010 from RecoLocalTracker.SiPixelClusterizer.SiPixelClusterizerPreSplitting_cfi import siPixelClustersPreSplitting
0011 
0012 siPixelClustersPreSplittingTask = cms.Task(
0013     # SwitchProducer wrapping the legacy pixel cluster producer or an alias for the pixel clusters information converted from SoA
0014     siPixelClustersPreSplitting
0015 )
0016 
0017 # reconstruct the pixel digis and clusters on the gpu
0018 from RecoLocalTracker.SiPixelClusterizer.siPixelRawToClusterCUDA_cfi import siPixelRawToClusterCUDA as _siPixelRawToClusterCUDA
0019 siPixelClustersPreSplittingCUDA = _siPixelRawToClusterCUDA.clone()
0020 
0021 run3_common.toModify(siPixelClustersPreSplittingCUDA,
0022                      # use the pixel channel calibrations scheme for Run 3
0023                      isRun2 = False,
0024                      clusterThreshold_layer1 = 4000)
0025 
0026 # convert the pixel digis (except errors) and clusters to the legacy format
0027 from RecoLocalTracker.SiPixelClusterizer.siPixelDigisClustersFromSoAPhase1_cfi import siPixelDigisClustersFromSoAPhase1 as _siPixelDigisClustersFromSoAPhase1
0028 from RecoLocalTracker.SiPixelClusterizer.siPixelDigisClustersFromSoAPhase2_cfi import siPixelDigisClustersFromSoAPhase2 as _siPixelDigisClustersFromSoAPhase2
0029 
0030 siPixelDigisClustersPreSplitting = _siPixelDigisClustersFromSoAPhase1.clone()
0031 
0032 run3_common.toModify(siPixelDigisClustersPreSplitting,
0033                      clusterThreshold_layer1 = 4000)
0034 
0035 from Configuration.Eras.Modifier_phase2_tracker_cff import phase2_tracker
0036 
0037 gpu.toReplaceWith(siPixelClustersPreSplittingTask, cms.Task(
0038     # conditions used *only* by the modules running on GPU
0039     siPixelROCsStatusAndMappingWrapperESProducer,
0040     siPixelGainCalibrationForHLTGPU,
0041     # reconstruct the pixel digis and clusters on the gpu
0042     siPixelClustersPreSplittingCUDA,
0043     # convert the pixel digis (except errors) and clusters to the legacy format
0044     siPixelDigisClustersPreSplitting,
0045     # SwitchProducer wrapping the legacy pixel cluster producer or an alias for the pixel clusters information converted from SoA
0046     siPixelClustersPreSplittingTask.copy()
0047 ))
0048 
0049 from RecoLocalTracker.SiPixelClusterizer.siPixelPhase2DigiToClusterCUDA_cfi import siPixelPhase2DigiToClusterCUDA as _siPixelPhase2DigiToClusterCUDA
0050 # for phase2 no pixel raw2digi is available at the moment
0051 # so we skip the raw2digi step and run on pixel digis copied to gpu
0052 
0053 phase2_tracker.toReplaceWith(siPixelClustersPreSplittingCUDA,_siPixelPhase2DigiToClusterCUDA.clone())
0054 
0055 from EventFilter.SiPixelRawToDigi.siPixelDigisSoAFromCUDA_cfi import siPixelDigisSoAFromCUDA as _siPixelDigisSoAFromCUDA
0056 siPixelDigisPhase2SoA = _siPixelDigisSoAFromCUDA.clone(
0057     src = "siPixelClustersPreSplittingCUDA"
0058 )
0059 
0060 phase2_tracker.toReplaceWith(siPixelDigisClustersPreSplitting, _siPixelDigisClustersFromSoAPhase2.clone(
0061                         clusterThreshold_layer1 = 4000,
0062                         clusterThreshold_otherLayers = 4000,
0063                         src = "siPixelDigisPhase2SoA",
0064                         #produceDigis = False
0065                         ))
0066 
0067 (gpu & phase2_tracker).toReplaceWith(siPixelClustersPreSplittingTask, cms.Task(
0068                             # reconstruct the pixel clusters on the gpu from copied digis
0069                             siPixelClustersPreSplittingCUDA,
0070                             # copy from gpu to cpu
0071                             siPixelDigisPhase2SoA,
0072                             # convert the pixel digis (except errors) and clusters to the legacy format
0073                             siPixelDigisClustersPreSplitting,
0074                             # SwitchProducer wrapping the legacy pixel cluster producer or an alias for the pixel clusters information converted from SoA
0075                             siPixelClustersPreSplitting))