1 import FWCore.ParameterSet.Config
as cms
2 from HeterogeneousCore.CUDACore.SwitchProducerCUDA
import SwitchProducerCUDA
6 siPixelRecHits = cms.EDProducer(
"SiPixelRecHitConverter",
7 src = cms.InputTag(
"siPixelClusters"),
8 CPE = cms.string(
'PixelCPEGeneric'),
9 VerboseLevel = cms.untracked.int32(0)
14 cpu = siPixelRecHits.clone(
15 src =
'siPixelClustersPreSplitting' 20 from Configuration.Eras.Modifier_phase2_tracker_cff
import phase2_tracker
22 from Configuration.ProcessModifiers.pp_on_AA_cff
import pp_on_AA
25 from RecoLocalTracker.SiPixelRecHits.siPixelRecHitSoAFromLegacyPhase1_cfi
import siPixelRecHitSoAFromLegacyPhase1
as _siPixelRecHitsPreSplittingSoA
26 from RecoLocalTracker.SiPixelRecHits.siPixelRecHitSoAFromLegacyPhase2_cfi
import siPixelRecHitSoAFromLegacyPhase2
as _siPixelRecHitsPreSplittingSoAPhase2
27 from RecoLocalTracker.SiPixelRecHits.siPixelRecHitSoAFromLegacyHIonPhase1_cfi
import siPixelRecHitSoAFromLegacyHIonPhase1
as _siPixelRecHitsPreSplittingSoAHIonPhase1
29 siPixelRecHitsPreSplittingCPU = _siPixelRecHitsPreSplittingSoA.clone(convertToLegacy=
True)
30 (pp_on_AA & ~phase2_tracker).toReplaceWith(siPixelRecHitsPreSplittingCPU, _siPixelRecHitsPreSplittingSoAHIonPhase1.clone(convertToLegacy=
True, CPE = cms.string(
'PixelCPEFastHIonPhase1')))
31 phase2_tracker.toReplaceWith(siPixelRecHitsPreSplittingCPU, _siPixelRecHitsPreSplittingSoAPhase2.clone(convertToLegacy=
True, CPE = cms.string(
'PixelCPEFastPhase2')))
34 from Configuration.ProcessModifiers.pixelNtupletFit_cff
import pixelNtupletFit
35 pixelNtupletFit.toModify(siPixelRecHitsPreSplitting,
37 siPixelRecHitsPreSplittingCPU = cms.VPSet(
38 cms.PSet(type = cms.string(
"SiPixelRecHitedmNewDetSetVector")),
39 cms.PSet(type = cms.string(
"uintAsHostProduct"))
44 siPixelRecHitsPreSplittingTask = cms.Task(
46 siPixelRecHitsPreSplitting
50 from RecoLocalTracker.SiPixelRecHits.siPixelRecHitCUDAPhase1_cfi
import siPixelRecHitCUDAPhase1
as _siPixelRecHitCUDAPhase1
51 from RecoLocalTracker.SiPixelRecHits.siPixelRecHitCUDAPhase2_cfi
import siPixelRecHitCUDAPhase2
as _siPixelRecHitCUDAPhase2
52 from RecoLocalTracker.SiPixelRecHits.siPixelRecHitCUDAHIonPhase1_cfi
import siPixelRecHitCUDAHIonPhase1
as _siPixelRecHitCUDAHIonPhase1
54 siPixelRecHitsPreSplittingCUDA = _siPixelRecHitCUDAPhase1.clone(
55 beamSpot =
"offlineBeamSpotToCUDA" 57 (pp_on_AA & ~phase2_tracker).toReplaceWith(siPixelRecHitsPreSplittingCUDA,_siPixelRecHitCUDAHIonPhase1.clone(
58 beamSpot =
"offlineBeamSpotToCUDA" 60 phase2_tracker.toReplaceWith(siPixelRecHitsPreSplittingCUDA,_siPixelRecHitCUDAPhase2.clone(
61 beamSpot =
"offlineBeamSpotToCUDA" 67 siPixelRecHitsPreSplittingCPU = cms.VPSet(
68 cms.PSet(type = cms.string(
"pixelTopologyPhase1TrackingRecHitSoAHost")),
69 cms.PSet(type = cms.string(
"uintAsHostProduct"))
73 (pp_on_AA & ~phase2_tracker).toModify(siPixelRecHitsPreSplittingSoA,
75 siPixelRecHitsPreSplittingCPU = cms.VPSet(
76 cms.PSet(type = cms.string(
"pixelTopologyHIonPhase1TrackingRecHitSoAHost")),
77 cms.PSet(type = cms.string(
"uintAsHostProduct"))
80 phase2_tracker.toModify(siPixelRecHitsPreSplittingSoA,
82 siPixelRecHitsPreSplittingCPU = cms.VPSet(
83 cms.PSet(type = cms.string(
"pixelTopologyPhase2TrackingRecHitSoAHost")),
84 cms.PSet(type = cms.string(
"uintAsHostProduct"))
87 from RecoLocalTracker.SiPixelRecHits.siPixelRecHitSoAFromCUDAPhase1_cfi
import siPixelRecHitSoAFromCUDAPhase1
as _siPixelRecHitSoAFromCUDA
88 from RecoLocalTracker.SiPixelRecHits.siPixelRecHitSoAFromCUDAHIonPhase1_cfi
import siPixelRecHitSoAFromCUDAHIonPhase1
as _siPixelRecHitSoAFromCUDAHIonPhase1
89 from RecoLocalTracker.SiPixelRecHits.siPixelRecHitSoAFromCUDAPhase2_cfi
import siPixelRecHitSoAFromCUDAPhase2
as _siPixelRecHitSoAFromCUDAPhase2
91 (gpu & pixelNtupletFit).toModify(siPixelRecHitsPreSplittingSoA, cuda = _siPixelRecHitSoAFromCUDA.clone())
92 (gpu & pixelNtupletFit & phase2_tracker).toModify(siPixelRecHitsPreSplittingSoA, cuda = _siPixelRecHitSoAFromCUDAPhase2.clone())
95 from RecoLocalTracker.SiPixelRecHits.siPixelRecHitFromCUDAPhase1_cfi
import siPixelRecHitFromCUDAPhase1
as _siPixelRecHitFromCUDA
96 from RecoLocalTracker.SiPixelRecHits.siPixelRecHitFromCUDAHIonPhase1_cfi
import siPixelRecHitFromCUDAHIonPhase1
as _siPixelRecHitFromCUDAHIonPhase1
97 from RecoLocalTracker.SiPixelRecHits.siPixelRecHitFromCUDAPhase2_cfi
import siPixelRecHitFromCUDAPhase2
as _siPixelRecHitFromCUDAPhase2
99 (gpu & pixelNtupletFit).toModify(siPixelRecHitsPreSplitting, cuda = _siPixelRecHitFromCUDA.clone())
100 (gpu & pixelNtupletFit & pp_on_AA).toModify(siPixelRecHitsPreSplitting, cuda = _siPixelRecHitFromCUDAHIonPhase1.clone())
101 (gpu & pixelNtupletFit & phase2_tracker).toModify(siPixelRecHitsPreSplitting, cuda = _siPixelRecHitFromCUDAPhase2.clone())
104 pixelNtupletFit.toReplaceWith(siPixelRecHitsPreSplittingTask, cms.Task(
107 siPixelRecHitsPreSplittingCPU,
109 siPixelRecHitsPreSplittingTask.copy(),
111 siPixelRecHitsPreSplittingSoA)
118 (gpu & pixelNtupletFit).toReplaceWith(siPixelRecHitsPreSplittingTask, cms.Task(
121 siPixelRecHitsPreSplittingCUDA,
122 siPixelRecHitsPreSplittingCPU,
124 siPixelRecHitsPreSplittingTask.copy(),
126 siPixelRecHitsPreSplittingSoA