Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-12-10 23:21:37

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 # import the needed ingredients
0004 from Calibration.TkAlCaRecoProducers.AlcaBeamSpotHarvester_cff import *
0005 from Calibration.TkAlCaRecoProducers.AlcaSiStripQualityHarvester_cff import *
0006 from Calibration.TkAlCaRecoProducers.AlcaSiStripGainsHarvester_cff import *
0007 from Calibration.TkAlCaRecoProducers.AlcaSiStripGainsAAGHarvester_cff import *
0008 from Calibration.TkAlCaRecoProducers.AlcaSiStripHitEfficiencyHarvester_cff import *
0009 from Calibration.TkAlCaRecoProducers.AlcaSiStripLorentzAngleHarvester_cff import *
0010 from Calibration.TkAlCaRecoProducers.AlcaSiPixelLorentzAngleHarvester_cff import *
0011 from Calibration.TkAlCaRecoProducers.AlcaSiPixelLorentzAngleHarvesterMCS_cff import *
0012 from Alignment.CommonAlignmentProducer.AlcaSiPixelAliHarvester_cff import *
0013 from Alignment.CommonAlignmentProducer.AlcaSiPixelAliHarvesterHG_cff import *
0014 from Alignment.CommonAlignmentProducer.AlcaSiPixelAliHarvesterHGCombined_cff import *
0015 from Alignment.CommonAlignmentProducer.AlcaSiPixelAliHarvesterHLTHGCombined_cff import *
0016 from Calibration.EcalCalibAlgos.AlcaEcalPedestalsHarvester_cff import *
0017 from Calibration.LumiAlCaRecoProducers.AlcaLumiPCCHarvester_cff import *
0018 from CalibTracker.SiPixelQuality.SiPixelStatusHarvester_cfi import *
0019 from CalibTracker.SiPixelQuality.DQMEventInfoSiPixelQuality_cff import *
0020 from CalibPPS.TimingCalibration.PPSTimingCalibrationHarvester_cff import *
0021 from CalibPPS.TimingCalibration.ALCARECOPPSDiamondSampicTimingCalibHarvester_cff import *
0022 from CalibPPS.AlignmentGlobal.PPSAlignmentHarvester_cff import *
0023 
0024 from CommonTools.ConditionDBWriter.PCLMetadataWriter_cfi import *
0025 
0026 # common ingredients
0027 from CondCore.CondDB.CondDB_cfi import CondDB
0028 CondDBOutput = CondDB.clone(connect = cms.string("sqlite_file:promptCalibConditions.db"))
0029 
0030 PoolDBOutputService = cms.Service("PoolDBOutputService",
0031                                   CondDBOutput,
0032                                   toPut = cms.VPSet(),
0033                                   #timetype = cms.untracked.string("runnumber"),
0034                                   #timetype = cms.untracked.string("lumiid"),
0035                                   )
0036 
0037 
0038 from DQMServices.Components.DQMFileSaver_cfi import * # FIXME
0039 dqmSaver.convention = 'Offline'
0040 dqmSaver.workflow = '/Express/PCLTest/ALCAPROMPT'
0041 #dqmSaver.saveAtJobEnd = True
0042 
0043 # workflow definitions
0044 # --------------------------------------------------------------------------------------
0045 # --------------------------------------------------------------------------------------
0046 # BeamSpot by Run
0047 ALCAHARVESTBeamSpotByRun = alcaBeamSpotHarvester.clone()
0048 ALCAHARVESTBeamSpotByRun.AlcaBeamSpotHarvesterParameters.BeamSpotOutputBase = cms.untracked.string("runbased")
0049 ALCAHARVESTBeamSpotByRun.AlcaBeamSpotHarvesterParameters.outputRecordName = cms.untracked.string("BeamSpotObjectsRcdByRun")
0050 
0051 ALCAHARVESTBeamSpotByRun_metadata = cms.PSet(record = cms.untracked.string('BeamSpotObjectsRcdByRun'))
0052 
0053 ALCAHARVESTBeamSpotByRun_dbOutput = cms.PSet(record = cms.string('BeamSpotObjectsRcdByRun'),
0054                                              tag = cms.string('BeamSpotObject_ByRun'),
0055                                              timetype   = cms.untracked.string('runnumber')
0056                                              )
0057 
0058 # --------------------------------------------------------------------------------------
0059 # BeamSpot by Lumi
0060 ALCAHARVESTBeamSpotByLumi = alcaBeamSpotHarvester.clone()
0061 ALCAHARVESTBeamSpotByLumi.AlcaBeamSpotHarvesterParameters.BeamSpotOutputBase = cms.untracked.string("lumibased")
0062 ALCAHARVESTBeamSpotByLumi.AlcaBeamSpotHarvesterParameters.outputRecordName = cms.untracked.string("BeamSpotObjectsRcdByLumi")
0063 
0064 # configuration of DropBox metadata and DB output
0065 ALCAHARVESTBeamSpotByLumi_metadata = cms.PSet(record = cms.untracked.string('BeamSpotObjectsRcdByLumi'))
0066 
0067 ALCAHARVESTBeamSpotByLumi_dbOutput = cms.PSet(record = cms.string('BeamSpotObjectsRcdByLumi'),
0068                                               tag = cms.string('BeamSpotObject_ByLumi'),
0069                                               timetype   = cms.untracked.string('lumiid')
0070                                               )
0071 
0072 # --------------------------------------------------------------------------------------
0073 # BeamSpot HP by Run
0074 ALCAHARVESTBeamSpotHPByRun = alcaBeamSpotHarvester.clone()
0075 ALCAHARVESTBeamSpotHPByRun.AlcaBeamSpotHarvesterParameters.BeamSpotOutputBase = cms.untracked.string("runbased")
0076 ALCAHARVESTBeamSpotHPByRun.AlcaBeamSpotHarvesterParameters.outputRecordName = cms.untracked.string("BeamSpotObjectsRcdHPByRun")
0077 ALCAHARVESTBeamSpotHPByRun.AlcaBeamSpotHarvesterParameters.BeamSpotModuleName = cms.untracked.string('alcaBeamSpotProducerHP')
0078 
0079 ALCAHARVESTBeamSpotHPByRun_metadata = cms.PSet(record = cms.untracked.string('BeamSpotObjectsRcdHPByRun'))
0080 
0081 ALCAHARVESTBeamSpotHPByRun_dbOutput = cms.PSet(record = cms.string('BeamSpotObjectsRcdHPByRun'),
0082                                              tag = cms.string('BeamSpotObjectHP_ByRun'),
0083                                              timetype   = cms.untracked.string('runnumber')
0084                                              )
0085 
0086 # --------------------------------------------------------------------------------------
0087 # BeamSpot HP by Lumi
0088 ALCAHARVESTBeamSpotHPByLumi = alcaBeamSpotHarvester.clone()
0089 ALCAHARVESTBeamSpotHPByLumi.AlcaBeamSpotHarvesterParameters.BeamSpotOutputBase = cms.untracked.string("lumibased")
0090 ALCAHARVESTBeamSpotHPByLumi.AlcaBeamSpotHarvesterParameters.outputRecordName = cms.untracked.string("BeamSpotObjectsRcdHPByLumi")
0091 ALCAHARVESTBeamSpotHPByLumi.AlcaBeamSpotHarvesterParameters.BeamSpotModuleName = cms.untracked.string('alcaBeamSpotProducerHP')
0092 ALCAHARVESTBeamSpotHPByLumi.AlcaBeamSpotHarvesterParameters.DumpTxt = cms.untracked.bool(True)
0093 
0094 # configuration of DropBox metadata and DB output
0095 ALCAHARVESTBeamSpotHPByLumi_metadata = cms.PSet(record = cms.untracked.string('BeamSpotObjectsRcdHPByLumi'))
0096 
0097 ALCAHARVESTBeamSpotHPByLumi_dbOutput = cms.PSet(record = cms.string('BeamSpotObjectsRcdHPByLumi'),
0098                                               tag = cms.string('BeamSpotObjectHP_ByLumi'),
0099                                               timetype   = cms.untracked.string('lumiid')
0100                                               )
0101 
0102 
0103 # --------------------------------------------------------------------------------------
0104 # BeamSpot HP - Low PU - by Run
0105 ALCAHARVESTBeamSpotHPLowPUByRun = ALCAHARVESTBeamSpotHPByRun.clone()
0106 ALCAHARVESTBeamSpotHPLowPUByRun.AlcaBeamSpotHarvesterParameters.BeamSpotModuleName = cms.untracked.string('alcaBeamSpotProducerHPLowPU')
0107 
0108 # configuration of DropBox metadata and DB output
0109 ALCAHARVESTBeamSpotHPLowPUByRun_metadata = cms.PSet(record = cms.untracked.string('BeamSpotObjectsRcdHPByRun'))
0110 
0111 ALCAHARVESTBeamSpotHPLowPUByRun_dbOutput = cms.PSet(record = cms.string('BeamSpotObjectsRcdHPByRun'),
0112                                                     tag = cms.string('BeamSpotObjectHP_ByRun'),
0113                                                     timetype   = cms.untracked.string('runnumber')
0114                                                     )
0115 
0116 # --------------------------------------------------------------------------------------
0117 # BeamSpot HP - Low PU - by Lumi
0118 ALCAHARVESTBeamSpotHPLowPUByLumi = ALCAHARVESTBeamSpotHPByLumi.clone()
0119 ALCAHARVESTBeamSpotHPLowPUByLumi.AlcaBeamSpotHarvesterParameters.BeamSpotModuleName = cms.untracked.string('alcaBeamSpotProducerHPLowPU')
0120 
0121 
0122 # configuration of DropBox metadata and DB output
0123 ALCAHARVESTBeamSpotHPLowPUByLumi_metadata = cms.PSet(record = cms.untracked.string('BeamSpotObjectsRcdHPByLumi'))
0124 
0125 ALCAHARVESTBeamSpotHPLowPUByLumi_dbOutput = cms.PSet(record = cms.string('BeamSpotObjectsRcdHPByLumi'),
0126                                                      tag = cms.string('BeamSpotObjectHP_ByLumi'),
0127                                                      timetype   = cms.untracked.string('lumiid')
0128                                                      )
0129 
0130 # --------------------------------------------------------------------------------------
0131 # SiStrip Quality
0132 ALCAHARVESTSiStripQuality_metadata = cms.PSet(record = cms.untracked.string('SiStripBadStripRcd'))
0133 
0134 ALCAHARVESTSiStripQuality_dbOutput = cms.PSet(record = cms.string('SiStripBadStripRcd'),
0135                                               tag = cms.string('SiStripBadStrip_pcl'),
0136                                               timetype   = cms.untracked.string('runnumber')
0137                                               )
0138 
0139 # --------------------------------------------------------------------------------------
0140 # SiStrip Gains
0141 ALCAHARVESTSiStripGains_metadata = cms.PSet(record = cms.untracked.string('SiStripApvGainRcd'))
0142 
0143 ALCAHARVESTSiStripGains_dbOutput = cms.PSet(record = cms.string('SiStripApvGainRcd'),
0144                                             tag = cms.string('SiStripApvGain_pcl'),
0145                                             timetype   = cms.untracked.string('runnumber')
0146                                             )
0147 
0148 # --------------------------------------------------------------------------------------
0149 # SiStrip Gains (AAG)
0150 ALCAHARVESTSiStripGainsAAG_metadata = cms.PSet(record = cms.untracked.string('SiStripApvGainRcdAAG'))
0151 
0152 ALCAHARVESTSiStripGainsAAG_dbOutput = cms.PSet(record = cms.string('SiStripApvGainRcdAAG'),
0153                                                          tag = cms.string('SiStripApvGainAAG_pcl'),
0154                                                          timetype   = cms.untracked.string('runnumber')
0155                                                          )
0156 # --------------------------------------------------------------------------------------
0157 # SiStrip Lorentz Angle
0158 ALCAHARVESTSiStripLA_metadata = cms.PSet(record = cms.untracked.string('SiStripLorentzAngleRcd'))
0159 
0160 ALCAHARVESTSiStripLA_dbOutput = cms.PSet(record = cms.string('SiStripLorentzAngleRcd'),
0161                                          tag = cms.string('SiStripLA_pcl'),
0162                                          timetype   = cms.untracked.string('runnumber')
0163                                          )
0164 
0165 # --------------------------------------------------------------------------------------
0166 # SiStrip Bad Components from Hit Efficiency analysis
0167 ALCAHARVESTSiStripHitEff_metadata = cms.PSet(record = cms.untracked.string('SiStripBadStripFromHitEffRcd'))
0168 
0169 ALCAHARVESTSiStripHitEff_dbOutput = cms.PSet(record = cms.string('SiStripBadStripFromHitEffRcd'),
0170                                                     tag = cms.string('SiStripBadStripRcdHitEff_pcl'),
0171                                                     timetype   = cms.untracked.string('runnumber')
0172                                                     )
0173 
0174 # --------------------------------------------------------------------------------------
0175 # SiPixel Alignment
0176 ALCAHARVESTSiPixelAli_metadata = cms.PSet(record = cms.untracked.string('TrackerAlignmentRcd'))
0177 
0178 ALCAHARVESTSiPixelAli_dbOutput = cms.PSet(record = cms.string('TrackerAlignmentRcd'),
0179                                           tag = cms.string('SiPixelAli_pcl'),
0180                                           timetype   = cms.untracked.string('runnumber')
0181                                           )
0182 
0183 # --------------------------------------------------------------------------------------
0184 # SiPixel Alignment HG
0185 ALCAHARVESTSiPixelAliHG_metadata = cms.PSet(record = cms.untracked.string('TrackerAlignmentHGRcd'))
0186 
0187 ALCAHARVESTSiPixelAliHG_dbOutput = cms.PSet(record = cms.string('TrackerAlignmentHGRcd'),
0188                                           tag = cms.string('SiPixelAliHG_pcl'),
0189                                           timetype   = cms.untracked.string('runnumber')
0190                                           )
0191 
0192 # --------------------------------------------------------------------------------------
0193 # SiPixel Alignment HG combined
0194 ALCAHARVESTSiPixelAliHGCombined_metadata = cms.PSet(record = cms.untracked.string('TrackerAlignmentHGCombinedRcd'))
0195 
0196 ALCAHARVESTSiPixelAliHGCombined_dbOutput = cms.PSet(record = cms.string('TrackerAlignmentHGCombinedRcd'),
0197                                                     tag = cms.string('SiPixelAliHGCombined_pcl'),
0198                                                     timetype   = cms.untracked.string('runnumber')
0199                                                     )
0200 # --------------------------------------------------------------------------------------
0201 # SiPixel Alignment HG combined for HLT Calibration
0202 ALCAHARVESTSiPixelAliHLTHGCombined_metadata = cms.PSet(record = cms.untracked.string('TrackerAlignmentHLTHGCombinedRcd'))
0203 
0204 ALCAHARVESTSiPixelAliHLTHGCombined_dbOutput = cms.PSet(record = cms.string('TrackerAlignmentHLTHGCombinedRcd'),
0205                                                        tag = cms.string('SiPixelAliHLTHGCombined_pcl'),
0206                                                        timetype   = cms.untracked.string('runnumber')
0207                                                        )
0208 
0209 
0210 # --------------------------------------------------------------------------------------
0211 # SiPixel Lorentz Angle
0212 ALCAHARVESTSiPixelLA_metadata = cms.PSet(record = cms.untracked.string('SiPixelLorentzAngleRcd'))
0213 
0214 ALCAHARVESTSiPixelLA_dbOutput = cms.PSet(record = cms.string('SiPixelLorentzAngleRcd'),
0215                                          tag = cms.string('SiPixelLA_pcl'),
0216                                          timetype   = cms.untracked.string('runnumber')
0217                                          )
0218 
0219 # --------------------------------------------------------------------------------------
0220 # SiPixel Lorentz Angle Minimal Cluster Size
0221 ALCAHARVESTSiPixelLAMCS_metadata = cms.PSet(record = cms.untracked.string('SiPixelLorentzAngleRcdMCS'))
0222 
0223 ALCAHARVESTSiPixelLAMCS_dbOutput = cms.PSet(record = cms.string('SiPixelLorentzAngleRcdMCS'),
0224                                             tag = cms.string('SiPixelLAMCS_pcl'),
0225                                             timetype   = cms.untracked.string('runnumber')
0226                                          )
0227 # --------------------------------------------------------------------------------------
0228 # ECAL Pedestals
0229 ALCAHARVESTEcalPedestals_metadata = cms.PSet(record = cms.untracked.string('EcalPedestalsRcd'))
0230 
0231 ALCAHARVESTEcalPedestals_dbOutput = cms.PSet(record = cms.string('EcalPedestalsRcd'),
0232                                              tag = cms.string('EcalPedestals_pcl'),
0233                                              timetype   = cms.untracked.string('runnumber')
0234                                              )
0235 
0236 # --------------------------------------------------------------------------------------
0237 # Lumi PCC
0238 ALCAHARVESTLumiPCC_metadata = cms.PSet(record = cms.untracked.string('LumiCorrectionsRcd'))
0239 
0240 ALCAHARVESTLumiPCC_dbOutput = cms.PSet(record = cms.string('LumiCorrectionsRcd'),
0241                                              tag = cms.string('LumiPCCCorrections_pcl'),
0242                                              timetype   = cms.untracked.string('lumiid')
0243                                              )
0244 
0245 
0246 
0247 # SiPixel Quality
0248 ALCAHARVESTSiPixelQuality = siPixelStatusHarvester.clone()
0249 ALCAHARVESTSiPixelQuality.SiPixelStatusManagerParameters.outputBase = cms.untracked.string("dynamicLumibased")
0250 ALCAHARVESTSiPixelQuality.SiPixelStatusManagerParameters.aveDigiOcc = cms.untracked.int32(20000)
0251 ALCAHARVESTSiPixelQuality.debug = cms.untracked.bool(False)
0252 
0253 ALCAHARVESTSiPixelQuality_metadata = cms.VPSet(cms.PSet(record = cms.untracked.string('SiPixelQualityFromDbRcd_prompt')),
0254                                                cms.PSet(record = cms.untracked.string('SiPixelQualityFromDbRcd_stuckTBM')),
0255                                                cms.PSet(record = cms.untracked.string('SiPixelQualityFromDbRcd_other')))
0256 ALCAHARVESTSiPixelQuality_dbOutput = cms.VPSet(cms.PSet(record = cms.string('SiPixelQualityFromDbRcd_prompt'),
0257                                                         tag = cms.string('SiPixelQualityFromDbRcd_prompt'),
0258                                                         timetype = cms.untracked.string('lumiid')
0259                                                         ),
0260                                                cms.PSet(record = cms.string('SiPixelQualityFromDbRcd_stuckTBM'),
0261                                                         tag = cms.string('SiPixelQualityFromDbRcd_stuckTBM'),
0262                                                         timetype = cms.untracked.string('lumiid'),
0263                                                         ),
0264                                                cms.PSet(record = cms.string('SiPixelQualityFromDbRcd_other'),
0265                                                         tag = cms.string('SiPixelQualityFromDbRcd_other'),
0266                                                         timetype = cms.untracked.string('lumiid')
0267                                                         )
0268                                                )
0269 
0270 if ALCAHARVESTSiPixelQuality.debug == cms.untracked.bool(True) :
0271    dbOutput_ext = cms.VPSet(
0272         cms.PSet(record = cms.string('SiPixelQualityFromDbRcd_PCL'),
0273                 tag = cms.string('SiPixelQualityFromDbRcd_PCL'),
0274                 timetype = cms.untracked.string('lumiid')
0275                 ),
0276         cms.PSet(record = cms.string('SiPixelQualityFromDbRcd_FEDerror25'),
0277                 tag = cms.string('SiPixelQualityFromDbRcd_FEDerror25'),
0278                 timetype = cms.untracked.string('lumiid'),
0279         ),
0280         cms.PSet(record = cms.string('SiPixelQualityFromDbRcd_permanentBad'),
0281                 tag = cms.string('SiPixelQualityFromDbRcd_permanentBad'),
0282                 timetype = cms.untracked.string('runnumber')
0283         )
0284    )
0285    ALCAHARVESTSiPixelQuality_dbOutput.extend(dbOutput_ext)
0286 
0287 # --------------------------------------------------------------------------------------
0288 # PPS calibration
0289 ALCAHARVESTPPSTimingCalibration_metadata = cms.PSet(record = cms.untracked.string('PPSTimingCalibrationRcd_HPTDC'))
0290 ALCAHARVESTPPSTimingCalibration_dbOutput = cms.PSet(record = cms.string('PPSTimingCalibrationRcd_HPTDC'),
0291                                                     tag = cms.string('PPSDiamondTimingCalibration_pcl'),
0292                                                     timetype = cms.untracked.string('runnumber')
0293                                                     )
0294 
0295 ALCAHARVESTPPSDiamondSampicTimingCalibration_metadata = cms.PSet(record = cms.untracked.string('PPSTimingCalibrationRcd_SAMPIC'))
0296 ALCAHARVESTPPSDiamondSampicTimingCalibration_dbOutput = cms.PSet(record = cms.string('PPSTimingCalibrationRcd_SAMPIC'),
0297                                             tag = cms.string('PPSDiamondSampicCalibration_pcl'),
0298                                             timetype = cms.untracked.string('runnumber'))
0299 
0300 ALCAHARVESTPPSAlignment_metadata = cms.PSet(record = cms.untracked.string('CTPPSRPAlignmentCorrectionsDataRcd'))
0301 ALCAHARVESTPPSAlignment_dbOutput = cms.PSet(record = cms.string('CTPPSRPAlignmentCorrectionsDataRcd'),
0302                                             tag = cms.string('CTPPSRPAlignment_real_pcl'),
0303                                             timetype = cms.untracked.string('runnumber'))
0304 
0305 # define all the paths
0306 BeamSpotByRun  = cms.Path(ALCAHARVESTBeamSpotByRun)
0307 BeamSpotByLumi = cms.Path(ALCAHARVESTBeamSpotByLumi)
0308 BeamSpotHPByRun  = cms.Path(ALCAHARVESTBeamSpotHPByRun)
0309 BeamSpotHPByLumi = cms.Path(ALCAHARVESTBeamSpotHPByLumi)
0310 BeamSpotHPLowPUByRun  = cms.Path(ALCAHARVESTBeamSpotHPLowPUByRun)
0311 BeamSpotHPLowPUByLumi = cms.Path(ALCAHARVESTBeamSpotHPLowPUByLumi)
0312 SiStripQuality = cms.Path(ALCAHARVESTSiStripQuality)
0313 SiStripGains   = cms.Path(ALCAHARVESTSiStripGains)
0314 SiStripGainsAAG = cms.Path(ALCAHARVESTSiStripGainsAAG)
0315 SiStripHitEff = cms.Path(ALCAHARVESTSiStripHitEfficiency)
0316 SiStripLA      = cms.Path(ALCAHARVESTSiStripLorentzAngle)
0317 SiPixelAli     = cms.Path(ALCAHARVESTSiPixelAli)
0318 SiPixelAliHG     = cms.Path(ALCAHARVESTSiPixelAliHG)
0319 SiPixelAliHGCombined = cms.Path(ALCAHARVESTSiPixelAliHGCombined)
0320 SiPixelAliHLTHGCombined = cms.Path(ALCAHARVESTSiPixelAliHLTHGCombined)
0321 SiPixelLA      = cms.Path(ALCAHARVESTSiPixelLorentzAngle)
0322 SiPixelLAMCS      = cms.Path(ALCAHARVESTSiPixelLorentzAngleMCS)
0323 EcalPedestals  = cms.Path(ALCAHARVESTEcalPedestals)
0324 LumiPCC = cms.Path(ALCAHARVESTLumiPCC)
0325 SiPixelQuality = cms.Path(dqmEnvSiPixelQuality+ALCAHARVESTSiPixelQuality)#+siPixelPhase1DQMHarvester)
0326 PPSTimingCalibration = cms.Path(ALCAHARVESTPPSTimingCalibration)
0327 PPSDiamondSampicTimingCalibration = cms.Path(ALCAHARVESTPPSDiamondSampicTimingCalibration)
0328 PPSAlignment = cms.Path(ALCAHARVESTPPSAlignment)
0329 
0330 ALCAHARVESTDQMSaveAndMetadataWriter = cms.Path(dqmSaver+pclMetadataWriter)
0331 
0332 #promptCalibHarvest = cms.Path(alcaBeamSpotHarvester)