CMS 3D CMS Logo

ALCARECOHcalCalPedestalLocal_cff.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 #------------------------------------------------
4 #AlCaReco filtering for HCAL minbias:
5 #------------------------------------------------
6 
8 hcalDigiAlCaMB.InputLabel = 'source'
9 
11 hcalminbiasHLT = HLTrigger.HLTfilters.hltHighLevel_cfi.hltHighLevel.clone(
12 # HLTPaths = ['HLT_HcalPhiSym'],
13  eventSetupPathsKey='HcalCalMinBias',
14  throw = False #dont throw except on unknown path name
15 )
16 
17 import RecoLocalCalo.HcalRecProducers.HBHEPhase1Reconstructor_cfi
18 hbherecoMBNZS = RecoLocalCalo.HcalRecProducers.HBHEPhase1Reconstructor_cfi.hbheprereco.clone(
19  digiLabelQIE8 = "hcalDigiAlCaMB",
20  digiLabelQIE11 = "hcalDigiAlCaMB",
21 
22  dropZSmarkedPassed = False,
23  algorithm = dict(
24  useMahi = False,
25  useM2 = False,
26  useM3 = False
27  ),
28  processQIE11 = False,
29  setNegativeFlagsQIE8 = False,
30  setNegativeFlagsQIE11 = False,
31  setNoiseFlagsQIE8 = True,
32  setNoiseFlagsQIE11 = False,
33  setPulseShapeFlagsQIE8 = False,
34  setPulseShapeFlagsQIE11 = False,
35  setLegacyFlagsQIE8 = False,
36  setLegacyFlagsQIE11 = False,
37 )
38 
39 hbherecoMBNZS.algorithm.firstSampleShift = 0 # explicitly repeating the default
40 
41 import RecoLocalCalo.HcalRecProducers.hosimplereco_cfi
42 horecoMBNZS = RecoLocalCalo.HcalRecProducers.hosimplereco_cfi.hosimplereco.clone()
43 
44 horecoMBNZS.firstSample = 4
45 horecoMBNZS.samplesToAdd = 4
46 horecoMBNZS.digiLabel = 'hcalDigiAlCaMB'
47 horecoMBNZS.tsFromDB = False
48 horecoMBNZS.dropZSmarkedPassed = False
49 
50 import RecoLocalCalo.HcalRecProducers.hfsimplereco_cfi
51 hfrecoMBNZS = RecoLocalCalo.HcalRecProducers.hfsimplereco_cfi.hfsimplereco.clone()
52 
53 hfrecoMBNZS.firstSample = 2 # Run 2 default before 2017
54 hfrecoMBNZS.samplesToAdd = 2
55 hfrecoMBNZS.digiLabel = 'hcalDigiAlCaMB'
56 hfrecoMBNZS.tsFromDB = False
57 hfrecoMBNZS.dropZSmarkedPassed = False
58 
59 seqALCARECOHcalCalMinBiasDigi = cms.Sequence(hcalminbiasHLT*hcalDigiAlCaMB*gtDigisAlCaMB)
60 seqALCARECOHcalCalMinBiasDigiNoHLT = cms.Sequence(hcalDigiAlCaMB*gtDigisAlCaMB)
61 
62 seqALCARECOHcalCalMinBias = cms.Sequence(hbherecoMBNZS*horecoMBNZS*hbherecoNoise*hfrecoNoise*hfrecoMBNZS*horecoNoise)
63 #seqALCARECOHcalCalMinBias = cms.Sequence(hbherecoMBNZS*hbherecoNoise*hfrecoNoise*hfrecoMBNZS)
64 
65 import RecoLocalCalo.HcalRecProducers.hfprereco_cfi
66 hfprerecoNoise = RecoLocalCalo.HcalRecProducers.hfprereco_cfi.hfprereco.clone(
67  digiLabel = "hcalDigiAlCaMB",
68  dropZSmarkedPassed = False,
69  tsFromDB = False,
70  sumAllTimeSlices = False,
71  forceSOI = 0
72 )
73 hfprerecoMBNZS = RecoLocalCalo.HcalRecProducers.hfprereco_cfi.hfprereco.clone(
74  digiLabel = "hcalDigiAlCaMB",
75  dropZSmarkedPassed = False,
76  tsFromDB = False,
77  sumAllTimeSlices = True,
78  forceSOI = 1
79 )
80 
81 import RecoLocalCalo.HcalRecProducers.HFPhase1Reconstructor_cfi
82 _phase1_hfrecoNoise = RecoLocalCalo.HcalRecProducers.HFPhase1Reconstructor_cfi.hfreco.clone(
83  inputLabel = "hfprerecoNoise",
84  setNoiseFlags = False,
85  algorithm = dict(
86  Class = "HFSimpleTimeCheck",
87  rejectAllFailures = False
88  ),
89 )
90 _phase1_hfrecoMBNZS = RecoLocalCalo.HcalRecProducers.HFPhase1Reconstructor_cfi.hfreco.clone(
91  inputLabel = "hfprerecoMBNZS",
92  setNoiseFlags = False,
93  algorithm = dict(
94  Class = "HFSimpleTimeCheck",
95  rejectAllFailures = False
96  ),
97 )
98 
99 _phase1_seqALCARECOHcalCalMinBias = seqALCARECOHcalCalMinBias.copy()
100 _phase1_seqALCARECOHcalCalMinBias.insert(0,hfprerecoMBNZS)
101 _phase1_seqALCARECOHcalCalMinBias.insert(0,hfprerecoNoise)
102 
103 from Configuration.Eras.Modifier_run2_HF_2017_cff import run2_HF_2017
104 run2_HF_2017.toReplaceWith( seqALCARECOHcalCalMinBias, _phase1_seqALCARECOHcalCalMinBias )
105 run2_HF_2017.toReplaceWith( hfrecoNoise, _phase1_hfrecoNoise )
106 run2_HF_2017.toReplaceWith( hfrecoMBNZS, _phase1_hfrecoMBNZS )
107 
108 import RecoLocalCalo.HcalRecProducers.hbheplan1_cfi
109 hbheplan1MBNZS = RecoLocalCalo.HcalRecProducers.hbheplan1_cfi.hbheplan1.clone(
110  hbheInput = "hbheprerecoMBNZS"
111 )
112 hbheplan1Noise = RecoLocalCalo.HcalRecProducers.hbheplan1_cfi.hbheplan1.clone(
113  hbheInput = "hbheprerecoNoise"
114 )
115 
116 from Configuration.Eras.Modifier_run2_HCAL_2017_cff import run2_HCAL_2017
117 run2_HCAL_2017.toModify( hbherecoMBNZS,
118  processQIE11 = True,
119 # temporarily disabled until RecoLocalCalo/HcalRecProducers/python/HBHEPhase1Reconstructor_cfi.py:flagParametersQIE11 is filled
120 # setNoiseFlagsQIE11 = True,
121 )
122 run2_HCAL_2017.toModify( hbherecoNoise,
123  processQIE11 = True,
124 # temporarily disabled until RecoLocalCalo/HcalRecProducers/python/HBHEPhase1Reconstructor_cfi.py:flagParametersQIE11 is filled
125 # setNoiseFlagsQIE11 = True,
126 )
127 
128 _plan1_seqALCARECOHcalCalMinBias = _phase1_seqALCARECOHcalCalMinBias.copy()
129 hbheprerecoMBNZS = hbherecoMBNZS.clone()
130 hbheprerecoNoise = hbherecoNoise.clone()
131 _plan1_seqALCARECOHcalCalMinBias.insert(0,hbheprerecoNoise)
132 _plan1_seqALCARECOHcalCalMinBias.insert(0,hbheprerecoMBNZS)
133 from Configuration.Eras.Modifier_run2_HEPlan1_2017_cff import run2_HEPlan1_2017
134 run2_HEPlan1_2017.toReplaceWith(hbherecoMBNZS, hbheplan1MBNZS)
135 run2_HEPlan1_2017.toReplaceWith(hbherecoNoise, hbheplan1Noise)
136 run2_HEPlan1_2017.toReplaceWith(seqALCARECOHcalCalMinBias, _plan1_seqALCARECOHcalCalMinBias)