forked from cms-sw/cmssw
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
DD4hep migration for DB payload tester
- Loading branch information
Showing
48 changed files
with
1,857 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
import FWCore.ParameterSet.Config as cms | ||
from Configuration.AlCa.autoCond import autoCond | ||
|
||
from Configuration.Eras.Era_Run3_dd4hep_cff import Run3_dd4hep | ||
|
||
process = cms.Process("GeometryWriter", Run3_dd4hep) | ||
|
||
from Configuration.ProcessModifiers.dd4hep_cff import dd4hep | ||
|
||
process.load('CondCore.CondDB.CondDB_cfi') | ||
process.load('Configuration.StandardSequences.GeometryDB_cff') | ||
process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') | ||
process.GlobalTag.globaltag = autoCond['updgrade2021'] | ||
|
||
process.source = cms.Source("EmptyIOVSource", | ||
lastValue = cms.uint64(1), | ||
timetype = cms.string('runnumber'), | ||
firstValue = cms.uint64(1), | ||
interval = cms.uint64(1) | ||
) | ||
|
||
process.GeometryTester = cms.EDAnalyzer("GeometryTester", | ||
XMLTest = cms.untracked.bool(True), | ||
TrackerTest = cms.untracked.bool(True), | ||
EcalTest = cms.untracked.bool(True), | ||
HcalTest = cms.untracked.bool(True), | ||
HGCalTest = cms.untracked.bool(False), | ||
CaloTowerTest = cms.untracked.bool(True), | ||
CastorTest = cms.untracked.bool(False), | ||
ZDCTest = cms.untracked.bool(True), | ||
CSCTest = cms.untracked.bool(True), | ||
DTTest = cms.untracked.bool(True), | ||
RPCTest = cms.untracked.bool(True), | ||
geomLabel = cms.untracked.string("Extended"), | ||
roundValues = cms.untracked.bool(False) | ||
) | ||
|
||
process.maxEvents = cms.untracked.PSet( | ||
input = cms.untracked.int32(1) | ||
) | ||
|
||
process.p1 = cms.Path(process.GeometryTester) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
63 changes: 63 additions & 0 deletions
63
DetectorDescription/DDCMS/test/python/testTGeoIteratorDB.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
import FWCore.ParameterSet.Config as cms | ||
|
||
from Configuration.Eras.Era_Run3_dd4hep_cff import Run3_dd4hep | ||
|
||
process = cms.Process("DDCMSDetectorTest", Run3_dd4hep) | ||
|
||
process.source = cms.Source("EmptySource") | ||
process.maxEvents = cms.untracked.PSet( | ||
input = cms.untracked.int32(1) | ||
) | ||
|
||
process.MessageLogger = cms.Service("MessageLogger", | ||
cerr = cms.untracked.PSet( | ||
enable = cms.untracked.bool(False) | ||
), | ||
cout = cms.untracked.PSet( | ||
enable = cms.untracked.bool(True), | ||
enableStatistics = cms.untracked.bool(False), | ||
noLineBreaks = cms.untracked.bool(True), | ||
threshold = cms.untracked.string('WARNING') | ||
), | ||
files = cms.untracked.PSet( | ||
navGeometry = cms.untracked.PSet( | ||
DEBUG = cms.untracked.PSet( | ||
limit = cms.untracked.int32(0) | ||
), | ||
ERROR = cms.untracked.PSet( | ||
limit = cms.untracked.int32(0) | ||
), | ||
DumpGeometry = cms.untracked.PSet( | ||
limit = cms.untracked.int32(-1) | ||
), | ||
INFO = cms.untracked.PSet( | ||
limit = cms.untracked.int32(0) | ||
), | ||
WARNING = cms.untracked.PSet( | ||
limit = cms.untracked.int32(0) | ||
), | ||
enableStatistics = cms.untracked.bool(False), | ||
noLineBreaks = cms.untracked.bool(True), | ||
threshold = cms.untracked.string('INFO') | ||
) | ||
) | ||
) | ||
|
||
process.load("Configuration.StandardSequences.GeometryDB_cff") | ||
process.load('CondCore.CondDB.CondDB_cfi') | ||
process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') | ||
from Configuration.AlCa.autoCond import autoCond | ||
process.GlobalTag.globaltag = autoCond['upgrade2021'] | ||
|
||
process.DDDetectorESProducer = cms.ESSource("DDDetectorESProducer", | ||
rootDDName = cms.string('cms:OCMS'), | ||
label = cms.string('Extended'), | ||
fromDB = cms.bool(True), | ||
appendToDataLabel = cms.string('CMS') | ||
) | ||
|
||
process.test = cms.EDAnalyzer("DDTestDumpGeometry", | ||
DDDetector = cms.ESInputTag('','CMS') | ||
) | ||
|
||
process.p = cms.Path(process.test) |
84 changes: 84 additions & 0 deletions
84
DetectorDescription/DDCMS/test/python/testTGeoIteratorLocalDB.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
import FWCore.ParameterSet.Config as cms | ||
|
||
from Configuration.Eras.Era_Run3_dd4hep_cff import Run3_dd4hep | ||
|
||
process = cms.Process("DDCMSDetectorTest", Run3_dd4hep) | ||
|
||
process.source = cms.Source("EmptySource") | ||
process.maxEvents = cms.untracked.PSet( | ||
input = cms.untracked.int32(1) | ||
) | ||
|
||
process.MessageLogger = cms.Service("MessageLogger", | ||
cerr = cms.untracked.PSet( | ||
enable = cms.untracked.bool(False) | ||
), | ||
cout = cms.untracked.PSet( | ||
enable = cms.untracked.bool(True), | ||
enableStatistics = cms.untracked.bool(False), | ||
noLineBreaks = cms.untracked.bool(True), | ||
threshold = cms.untracked.string('WARNING') | ||
), | ||
files = cms.untracked.PSet( | ||
navGeometry = cms.untracked.PSet( | ||
DEBUG = cms.untracked.PSet( | ||
limit = cms.untracked.int32(0) | ||
), | ||
ERROR = cms.untracked.PSet( | ||
limit = cms.untracked.int32(0) | ||
), | ||
DumpGeometry = cms.untracked.PSet( | ||
limit = cms.untracked.int32(-1) | ||
), | ||
INFO = cms.untracked.PSet( | ||
limit = cms.untracked.int32(0) | ||
), | ||
WARNING = cms.untracked.PSet( | ||
limit = cms.untracked.int32(0) | ||
), | ||
enableStatistics = cms.untracked.bool(False), | ||
noLineBreaks = cms.untracked.bool(True), | ||
threshold = cms.untracked.string('INFO') | ||
) | ||
) | ||
) | ||
|
||
process.load("Configuration.StandardSequences.GeometryDB_cff") | ||
process.load('CondCore.CondDB.CondDB_cfi') | ||
process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') | ||
from Configuration.AlCa.autoCond import autoCond | ||
process.GlobalTag.globaltag = autoCond['upgrade2021'] | ||
|
||
process.DDDetectorESProducer = cms.ESSource("DDDetectorESProducer", | ||
rootDDName = cms.string('cms:OCMS'), | ||
label = cms.string('Extended'), | ||
fromDB = cms.bool(True), | ||
appendToDataLabel = cms.string('CMS') | ||
) | ||
|
||
process.CondDB.timetype = cms.untracked.string('runnumber') | ||
process.CondDB.connect = cms.string('sqlite_file:myfile.db') | ||
process.PoolDBESSourceGeometry = cms.ESSource("PoolDBESSource", | ||
process.CondDB, | ||
toGet = cms.VPSet(cms.PSet(record = cms.string('GeometryFileRcd'),tag = cms.string('XMLFILE_Geometry_TagXX_Extended2021_mc')), | ||
cms.PSet(record = cms.string('IdealGeometryRecord'),tag = cms.string('TKRECO_Geometry_TagXX')), | ||
cms.PSet(record = cms.string('PEcalBarrelRcd'), tag = cms.string('EBRECO_Geometry_TagXX')), | ||
cms.PSet(record = cms.string('PEcalEndcapRcd'), tag = cms.string('EERECO_Geometry_TagXX')), | ||
cms.PSet(record = cms.string('PEcalPreshowerRcd'),tag = cms.string('EPRECO_Geometry_TagXX')), | ||
cms.PSet(record = cms.string('PHcalRcd'), tag = cms.string('HCALRECO_Geometry_TagXX')), | ||
cms.PSet(record = cms.string('PCaloTowerRcd'), tag = cms.string('CTRECO_Geometry_TagXX')), | ||
cms.PSet(record = cms.string('PZdcRcd'), tag = cms.string('ZDCRECO_Geometry_TagXX')), | ||
cms.PSet(record = cms.string('PCastorRcd'), tag = cms.string('CASTORRECO_Geometry_TagXX')), | ||
cms.PSet(record = cms.string('CSCRecoGeometryRcd'),tag = cms.string('CSCRECO_Geometry_TagXX')), | ||
cms.PSet(record = cms.string('CSCRecoDigiParametersRcd'),tag = cms.string('CSCRECODIGI_Geometry_TagXX')), | ||
cms.PSet(record = cms.string('DTRecoGeometryRcd'),tag = cms.string('DTRECO_Geometry_TagXX')), | ||
cms.PSet(record = cms.string('RPCRecoGeometryRcd'),tag = cms.string('RPCRECO_Geometry_TagXX')) | ||
) | ||
) | ||
|
||
process.es_prefer_geometry = cms.ESPrefer( "PoolDBESSource", "PoolDBESSourceGeometry" ) | ||
process.test = cms.EDAnalyzer("DDTestDumpGeometry", | ||
DDDetector = cms.ESInputTag('','CMS') | ||
) | ||
|
||
process.p = cms.Path(process.test) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# Configuration file to run CSCGeometryAnalyzer | ||
|
||
import FWCore.ParameterSet.Config as cms | ||
|
||
from Configuration.Eras.Era_Run3_dd4hep_cff import Run3_dd4hep | ||
|
||
process = cms.Process("CSCGeometryAnalyzer", Run3_dd4hep) | ||
|
||
|
||
# Endcap Muon geometry | ||
# ==================== | ||
process.load('Configuration.Geometry.GeometryDD4hepExtended2021Reco_cff') | ||
|
||
# Fake alignment is/should be ideal geometry | ||
# ========================================== | ||
process.load('Alignment.CommonAlignmentProducer.FakeAlignmentSource_cfi') | ||
process.preferFakeAlign = cms.ESPrefer('FakeAlignmentSource') | ||
|
||
# flags for modelling of CSC layer & strip geometry | ||
# ================================================= | ||
process.load('Geometry.CSCGeometry.cscGeometry_cfi') | ||
|
||
process.source = cms.Source('EmptySource') | ||
|
||
process.maxEvents = cms.untracked.PSet( | ||
input = cms.untracked.int32(1) | ||
) | ||
|
||
process.load('FWCore.MessageLogger.MessageLogger_cfi') | ||
process.MessageLogger.debugModules.append('CSCGeometryESModule') | ||
process.MessageLogger.cout = cms.untracked.PSet( | ||
threshold = cms.untracked.string('DEBUG'), | ||
default = cms.untracked.PSet( limit = cms.untracked.int32(0) ), | ||
CSCGeometry = cms.untracked.PSet( limit = cms.untracked.int32(-1) ), | ||
CSCGeometryBuilder = cms.untracked.PSet( limit = cms.untracked.int32(-1) ) | ||
) | ||
|
||
process.producer = cms.EDAnalyzer('CSCGeometryAnalyzer') | ||
|
||
process.p1 = cms.Path(process.producer) |
37 changes: 37 additions & 0 deletions
37
Geometry/CSCGeometry/test/testCSCGeometryFromDBDD4hep_cfg.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
# Configuration file to run stubs/CSCGeometryAnalyser | ||
|
||
import FWCore.ParameterSet.Config as cms | ||
|
||
from Configuration.Eras.Era_Run3_dd4hep_cff import Run3_dd4hep | ||
|
||
process = cms.Process("GeometryTest", Run3_dd4hep) | ||
|
||
process.load("Configuration.StandardSequences.GeometryRecoDB_cff") | ||
process.load('CondCore.CondDB.CondDB_cfi') | ||
process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') | ||
from Configuration.AlCa.autoCond import autoCond | ||
process.GlobalTag.globaltag = autoCond['upgrade2021'] | ||
|
||
process.load("Alignment.CommonAlignmentProducer.FakeAlignmentSource_cfi") | ||
process.preferFakeAlign = cms.ESPrefer("FakeAlignmentSource") | ||
|
||
process.source = cms.Source("EmptySource") | ||
|
||
process.maxEvents = cms.untracked.PSet( | ||
input = cms.untracked.int32(1) | ||
) | ||
|
||
process.load("FWCore.MessageLogger.MessageLogger_cfi") | ||
process.MessageLogger.debugModules.append('CSCGeometryESModule') | ||
process.MessageLogger.cout = cms.untracked.PSet( | ||
threshold = cms.untracked.string('DEBUG'), | ||
default = cms.untracked.PSet( limit = cms.untracked.int32(0) ), | ||
CSCGeometry = cms.untracked.PSet( limit = cms.untracked.int32(-1) ), | ||
CSCGeometryBuilder = cms.untracked.PSet( limit = cms.untracked.int32(-1) ) | ||
) | ||
|
||
process.producer = cms.EDAnalyzer("CSCGeometryAnalyzer") | ||
|
||
process.p1 = cms.Path(process.producer) | ||
process.CSCGeometryESModule.debugV = True | ||
|
Oops, something went wrong.