Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 11:58:31

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 process = cms.Process("DumpFileToDB")
0004 
0005 process.load("CondCore.CondDB.CondDB_cfi")
0006 
0007 process.source = cms.Source("EmptySource",
0008     numberEventsInRun = cms.untracked.uint32(1),
0009     firstRun = cms.untracked.uint32(300000)
0010 )
0011 
0012 process.maxEvents = cms.untracked.PSet(
0013     input = cms.untracked.int32(1)
0014 )
0015 
0016 
0017 process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
0018 process.GlobalTag.globaltag = "GR10_P_V5::All"
0019 #process.GlobalTag.pfnPrefix = cms.untracked.string('frontier://FrontierProd/')
0020 
0021 
0022 # process.calibDB = cms.ESSource("PoolDBESSource",
0023 #      process.CondDB,
0024 #      toGet = cms.VPSet(cms.PSet(
0025 #          # VDrift
0026 #          #record = cms.string("DTMtimeRcd"),
0027 #          #tag = cms.string("DT_vDrift_CRAFT_V02_offline")
0028 #          # TZero
0029 #          #record = cms.string("DTT0Rcd" ),
0030 #          #tag = cms.string("t0"),
0031 #          # TTrig
0032 #          record = cms.string('DTTtrigRcd'),
0033 #          tag = cms.string('ttrig_test')
0034 #      )),
0035 #  )
0036 #process.calibDB.connect = cms.string('sqlite_file:ttrig_test.db')
0037 
0038 # VDrift, TTrig, TZero, Noise or channels Map into DB
0039 process.PoolDBOutputService = cms.Service("PoolDBOutputService",
0040                                           process.CondDB,
0041                                           toPut = cms.VPSet(cms.PSet(record = cms.string("DTTtrigRcd"),
0042                                                                      tag = cms.string("ttrig"))))
0043 
0044 process.PoolDBOutputService.connect = cms.string("sqlite_file:ttrignew.db")
0045 #Module to dump a file into a DB
0046 process.dumpToDB = cms.EDFilter("DumpFileToDB",
0047                                 differentialMode = cms.untracked.bool(True),
0048                                 calibFileConfig = cms.untracked.PSet(calibConstFileName = cms.untracked.string("ttrig_prompt.txt"),
0049                                                                      calibConstGranularity = cms.untracked.string('bySL'),
0050                                                                      nFields = cms.untracked.int32(5)
0051                                                                      # VDrift & TTrig
0052                                                                      #untracked string calibConstGranularity = "bySL"
0053                                                                      #untracked int32 nFields = 4
0054                                                                      # TZero
0055                                                                      #untracked string calibConstGranularity = "byWire"
0056                                                                      #untracked int32 nFields = 6
0057                                                                      # Noise
0058                                                                      #untracked string calibConstGranularity = "byWire"
0059                                                                      #untracked int32 nFields = 7
0060                                                                      # Dead
0061                                                                      #untracked string calibConstGranularity = "byWire"
0062                                                                      #untracked int32 nFields = 7
0063                                                                      # No parameters required for ChannelDB
0064                                                                      ),
0065                                 #Choose what database you want to write
0066                                 #untracked string dbToDump = "VDriftDB"
0067                                 #untracked string dbToDump = "TZeroDB"
0068                                 #untracked string dbToDump = "TTrigDB"
0069                                 #untracked string dbToDump = "NoiseDB"
0070                                 #untracked string dbToDump = "DeadDB"
0071                                 dbToDump = cms.untracked.string('TTrigDB'))
0072                                 
0073 
0074 process.p = cms.Path(process.dumpToDB)
0075     
0076