Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-08-25 23:07:27

0001 #! /usr/bin/env cmsRun
0002 # cmsRun listIds_PhaseII.py fromDB=False
0003 
0004 import FWCore.ParameterSet.Config as cms
0005 from FWCore.ParameterSet.VarParsing import VarParsing
0006 
0007 ###################################################################
0008 # Set default phase-2 settings
0009 ###################################################################
0010 import Configuration.Geometry.defaultPhase2ConditionsEra_cff as _settings
0011 _PH2_GLOBAL_TAG, _PH2_ERA = _settings.get_era_and_conditions(_settings.DEFAULT_VERSION)
0012 
0013 process = cms.Process("MaterialAnalyser",_PH2_ERA)
0014 
0015 options = VarParsing('analysis')
0016 
0017 options.register('fromDB',
0018                  False,
0019                  VarParsing.multiplicity.singleton,
0020                  VarParsing.varType.bool,
0021                  'Read Geometry from DB?',
0022 )
0023 
0024 options.parseArguments()
0025 
0026 if options.fromDB :
0027    process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff')
0028    from Configuration.AlCa.GlobalTag import GlobalTag
0029    process.GlobalTag = GlobalTag(process.GlobalTag, _PH2_GLOBAL_TAG, '')
0030 else:
0031    process.load('Configuration.Geometry.GeometryExtended2026DefaultReco_cff')
0032    process.trackerGeometry.applyAlignment = False # needed to avoid to pass the Global Position Record
0033 
0034 process.load('FWCore.MessageService.MessageLogger_cfi')
0035 
0036 process.maxEvents = cms.untracked.PSet(
0037     input = cms.untracked.int32(1)
0038 )
0039 
0040 process.source = cms.Source("EmptySource",
0041     numberEventsInRun = cms.untracked.uint32(1),
0042         firstRun = cms.untracked.uint32(1)
0043 )
0044 
0045 process.listIds = cms.EDAnalyzer("ListIds",
0046                                 materials = cms.untracked.vstring("materials:Silicon", "tracker:tkLayout_SenSi"),
0047                                 printMaterial = cms.untracked.bool(True)
0048                                 )
0049 process.path = cms.Path(process.listIds)
0050 
0051