CMS 3D CMS Logo

dtVDriftSegmentWriter_cfg.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 process = cms.Process("DTVDriftWriter")
4 
5 
6 NEWDBFORMAT = False
7 
8 
9 process.load("CalibMuon.DTCalibration.messageLoggerDebug_cff")
10 process.MessageLogger.debugModules = cms.untracked.vstring('dtVDriftSegmentWriter')
11 
12 process.load("Configuration.StandardSequences.GeometryDB_cff")
13 process.load("Configuration.StandardSequences.MagneticField_AutoFromDBCurrent_cff")
14 process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
15 from Configuration.AlCa.autoCond import autoCond
16 process.GlobalTag.globaltag=autoCond['run3_data']
17 
18 process.load("CondCore.CondDB.CondDB_cfi")
19 
20 process.load("CalibMuon.DTCalibration.dtVDriftSegmentWriter_cfi")
21 
22 process.source = cms.Source("EmptySource",
23  numberEventsInRun = cms.untracked.uint32(1),
24  firstRun = cms.untracked.uint32(1)
25 )
26 
27 process.maxEvents = cms.untracked.PSet(
28  input = cms.untracked.int32(1)
29 )
30 
31 RECORD = 'DTMtimeRcd'
32 if NEWDBFORMAT :
33  RECORD = 'DTRecoConditionsVdriftRcd'
34  process.dtVDriftSegmentWriter.writeLegacyVDriftDB = False
35  # The following needs to be set as well if calibration should start use
36  # constants written in the new format as a starting point.
37  # process.dtVDriftSegmentWriter.vDriftAlgoConfig.readLegacyVDriftDB = False
38 
39 process.PoolDBOutputService = cms.Service("PoolDBOutputService",
40  process.CondDB,
41  timetype = cms.untracked.string('runnumber'),
42  toPut = cms.VPSet(cms.PSet(
43  record = cms.string(RECORD),
44  tag = cms.string('vDrift')
45  ))
46 )
47 process.PoolDBOutputService.connect = cms.string('sqlite_file:vDrift.db')
48 
49 process.p = cms.Path(process.dtVDriftSegmentWriter)