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 process.GlobalTag.globaltag = ''
16 
17 process.load("CondCore.CondDB.CondDB_cfi")
18 
19 process.load("CalibMuon.DTCalibration.dtVDriftSegmentWriter_cfi")
20 
21 process.source = cms.Source("EmptySource",
22  numberEventsInRun = cms.untracked.uint32(1),
23  firstRun = cms.untracked.uint32(1)
24 )
25 
26 process.maxEvents = cms.untracked.PSet(
27  input = cms.untracked.int32(1)
28 )
29 
30 RECORD = 'DTMtimeRcd'
31 if NEWDBFORMAT :
32  RECORD = 'DTRecoConditionsVdriftRcd'
33  process.dtVDriftSegmentWriter.writeLegacyVDriftDB = False
34  # The following needs to be set as well if calibration should start use
35  # constants written in the new format as a starting point.
36  # process.dtVDriftSegmentWriter.vDriftAlgoConfig.readLegacyVDriftDB = False
37 
38 process.PoolDBOutputService = cms.Service("PoolDBOutputService",
39  process.CondDB,
40  timetype = cms.untracked.string('runnumber'),
41  toPut = cms.VPSet(cms.PSet(
42  record = cms.string(RECORD),
43  tag = cms.string('vDrift')
44  ))
45 )
46 process.PoolDBOutputService.connect = cms.string('sqlite_file:vDrift.db')
47 
48 process.p = cms.Path(process.dtVDriftSegmentWriter)