Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:20:41

0001 from __future__ import absolute_import
0002 import FWCore.ParameterSet.Config as cms
0003 
0004 import SimCalorimetry.HGCalSimProducers.hgcalDigitizer_cfi as digiparam
0005 import RecoLocalCalo.HGCalRecProducers.HGCalUncalibRecHit_cfi as recoparam
0006 import RecoLocalCalo.HGCalRecProducers.HGCalRecHit_cfi as recocalibparam
0007 from . import hgcalLayersCalibrationCoefficients_cfi as layercalibparam
0008 
0009 from Configuration.Eras.Modifier_phase2_hgcalV10_cff import phase2_hgcalV10
0010 
0011 c2d_calib_pset = cms.PSet(calibSF_cluster=cms.double(1.),
0012                           layerWeights=layercalibparam.TrgLayer_weights,
0013                           applyLayerCalibration=cms.bool(True))
0014 
0015 c2d_thresholds_pset = cms.PSet(seeding_threshold_silicon=cms.double(5.),
0016                                seeding_threshold_scintillator=cms.double(5.),
0017                                clustering_threshold_silicon=cms.double(2.),
0018                                clustering_threshold_scintillator=cms.double(2.))
0019 
0020 # >= V9 samples have a different definition of the dEdx calibrations. To account for it
0021 # we rescale the thresholds for the clustering
0022 # (see https://indico.cern.ch/event/806845/contributions/3359859/attachments/1815187/2966402/19-03-20_EGPerf_HGCBE.pdf
0023 # for more details)
0024 phase2_hgcalV10.toModify(c2d_thresholds_pset,
0025                         seeding_threshold_silicon=3.75,
0026                         seeding_threshold_scintillator=3.75,
0027                         clustering_threshold_silicon=1.5,
0028                         clustering_threshold_scintillator=1.5,
0029                         )
0030 
0031 # we still don't have layer calibrations for >=V9 geometry. Switching this off we
0032 # use the dEdx calibrated energy of the TCs
0033 phase2_hgcalV10.toModify(c2d_calib_pset,
0034                         applyLayerCalibration=False
0035                         )
0036 
0037 
0038 dummy_C2d_params = cms.PSet(c2d_calib_pset,
0039                             clusterType=cms.string('dummyC2d')
0040                             )
0041 
0042 
0043 distance_C2d_params = cms.PSet(c2d_calib_pset,
0044                                c2d_thresholds_pset,
0045                                clusterType=cms.string('dRC2d'),
0046                                dR_cluster=cms.double(6.),
0047                                )
0048 
0049 topological_C2d_params = cms.PSet(c2d_calib_pset,
0050                                   c2d_thresholds_pset,
0051                                   clusterType=cms.string('NNC2d'),
0052                                   )
0053 
0054 constrTopological_C2d_params = cms.PSet(c2d_calib_pset,
0055                                         c2d_thresholds_pset,
0056                                         clusterType=cms.string('dRNNC2d'),
0057                                         dR_cluster=cms.double(6.),
0058                                         )
0059 
0060 ntcs_72links = [ 1,  4, 13, 13, 10, 10,  8,  8,  8,  7,  7,  6,  6,  6,  6,  6,  5,  5,  5,  5,  5,  5,  5,  4,  4,  4,  4,  4,  4,  4,  4,  4,  3,  2,  2,  2,  2,  2,  2,  2,  2,  1]
0061 ntcs_120links = [ 2,  7, 27, 24, 19, 17, 16, 15, 14, 14, 13, 13, 13, 12, 12, 12, 11, 11, 11, 10, 10, 10, 10, 10,  9,  9, 10,  9,  9,  9,  8,  8,  7,  5,  3,  3,  3,  3,  3,  3,  3,  3]
0062 
0063 phi_edges = [0.98901991,0.72722052,0.6981317,0.87266463,0.93084227,0.90175345,
0064 0.87266463,0.90175345,0.95993109,0.95993109,0.93084227,0.93084227,
0065 0.95993109,0.98901991,0.95993109,0.95993109,0.95993109,0.98901991,
0066 0.98901991,0.95993109,0.95993109,0.98901991,0.98901991,0.98901991,
0067 0.98901991,0.98901991,1.01810873,0.98901991,0.98901991,0.98901991,
0068 0.98901991,0.98901991,0.98901991,0.98901991,1.04719755,1.04719755,
0069 1.04719755,1.04719755,1.01810873,1.04719755,1.01810873,1.01810873]
0070 
0071 truncation_params = cms.PSet(rozMin=cms.double(0.07587128),
0072         rozMax=cms.double(0.55508006),
0073         rozBins=cms.uint32(42),
0074         maxTcsPerBin=cms.vuint32(ntcs_120links),
0075         phiSectorEdges=cms.vdouble(phi_edges),
0076         doTruncation=cms.bool(True)
0077         )
0078 
0079 truncation_paramsSA = cms.PSet(AlgoName=cms.string('HGCalStage1TruncationWrapper'),
0080         rozMin=cms.double(0.07587128),
0081         rozMax=cms.double(0.55508006),
0082         rozBins=cms.uint32(42),
0083         maxTcsPerBin=cms.vuint32(ntcs_120links),
0084         phiSectorEdges=cms.vdouble(phi_edges),
0085         doTruncation=cms.bool(True)
0086         )
0087 
0088 
0089 layer1truncation_proc = cms.PSet(ProcessorName  = cms.string('HGCalBackendLayer1Processor'),
0090                    C2d_parameters = dummy_C2d_params.clone(),
0091                    truncation_parameters = truncation_params.clone()
0092                    )
0093 stage1truncation_proc = cms.PSet(ProcessorName  = cms.string('HGCalBackendStage1Processor'),
0094                    truncation_parameters = truncation_paramsSA.clone()
0095                    )
0096 
0097 be_proc = cms.PSet(ProcessorName  = cms.string('HGCalBackendLayer1Processor2DClustering'),
0098                    C2d_parameters = dummy_C2d_params.clone()
0099                    )
0100 
0101 l1tHGCalBackEndLayer1Producer = cms.EDProducer(
0102     "HGCalBackendLayer1Producer",
0103     InputTriggerCells = cms.InputTag('l1tHGCalConcentratorProducer:HGCalConcentratorProcessorSelection'),
0104     ProcessorParameters = be_proc.clone()
0105     )
0106 
0107 l1tHGCalBackEndStage1Producer = cms.EDProducer(
0108     "HGCalBackendStage1Producer",
0109     InputTriggerCells = cms.InputTag('l1tHGCalConcentratorProducer:HGCalConcentratorProcessorSelection'),
0110     C2d_parameters = dummy_C2d_params.clone(),
0111     ProcessorParameters = stage1truncation_proc.clone()
0112     )
0113 
0114 l1tHGCalBackEndLayer1ProducerHFNose = l1tHGCalBackEndLayer1Producer.clone(
0115     InputTriggerCells = 'l1tHGCalConcentratorProducerHFNose:HGCalConcentratorProcessorSelection'
0116 )