CMS 3D CMS Logo

Functions | Variables
dumpRecoGeometry_cfg Namespace Reference

Functions

def help ()
 
def recoGeoLoad (score, properties)
 
def versionCheck (ver)
 

Variables

 Calo
 
 defaultOutputFileName
 
 defaultVersion
 
 dump
 
 era
 
 era_key
 
 input
 
 level
 
 maxEvents
 
 Muon
 
 options
 
 out
 
 outputFileName
 
 p
 
 process
 
 prop_key
 
 ResetRootErrHandler
 
 source
 
 tagInfo
 
 Timing
 
 Tracker
 
 varType
 
 version_key
 

Function Documentation

◆ help()

def dumpRecoGeometry_cfg.help ( )

Definition at line 11 of file dumpRecoGeometry_cfg.py.

References print().

Referenced by recoGeoLoad(), and versionCheck().

11 def help():
12  print("Usage: cmsRun dumpFWRecoGeometry_cfg.py tag=TAG ")
13  print(" tag=tagname")
14  print(" identify geometry condition database tag")
15  print(" ", varType.keys())
16  print("")
17  print(" version=versionNumber")
18  print(" scenario version from 2026 dictionary")
19  print("")
20  print(" tgeo=bool")
21  print(" dump in TGeo format to browse in geometry viewer")
22  print(" import this in Fireworks with option --sim-geom-file")
23  print("")
24  print(" tracker=bool")
25  print(" include Tracker subdetectors")
26  print("")
27  print(" muon=bool")
28  print(" include Muon subdetectors")
29  print("")
30  print(" calo=bool")
31  print(" include Calo subdetectors")
32  print("")
33  print(" timing=bool")
34  print(" include Timing subdetectors")
35  print("")
36  print("")
37  os._exit(1);
38 
void print(TMatrixD &m, const char *label=nullptr, bool mathematicaFormat=false)
Definition: Utilities.cc:47

◆ recoGeoLoad()

def dumpRecoGeometry_cfg.recoGeoLoad (   score,
  properties 
)

Definition at line 46 of file dumpRecoGeometry_cfg.py.

References help(), print(), and versionCheck().

46 def recoGeoLoad(score, properties):
47  print("Loading configuration for tag ", options.tag ,"...\n")
48 
49  if score == "Run1":
50  process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
51  from Configuration.AlCa.autoCond import autoCond
52  process.GlobalTag.globaltag = autoCond['run1_mc']
53  process.load("Configuration.StandardSequences.GeometryDB_cff")
54 
55  elif score == "2015":
56  process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
57  from Configuration.AlCa.autoCond import autoCond
58  process.GlobalTag.globaltag = autoCond['run2_mc']
59  process.load("Configuration.StandardSequences.GeometryDB_cff")
60 
61  elif score == "2017":
62  process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
63  from Configuration.AlCa.autoCond import autoCond
64  process.GlobalTag.globaltag = autoCond['upgrade2017']
65  process.load('Configuration.Geometry.GeometryExtended2017Reco_cff')
66 
67  elif score == "2021":
68  process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
69  from Configuration.AlCa.autoCond import autoCond
70  process.GlobalTag.globaltag = autoCond['upgrade2021']
71 
72  process.load('Geometry.TrackerGeometryBuilder.trackerParameters_cfi')
73  process.load('Configuration.Geometry.GeometryExtended2021Reco_cff')
74 
75  process.DTGeometryESModule.applyAlignment = cms.bool(False)
76  process.CSCGeometryESModule.applyAlignment = cms.bool(False)
77 
78  elif "2026" in score:
79  versionCheck(options.version)
80  process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
81 
82  # Import the required configuration from the CMSSW module
83  from Configuration.AlCa.autoCond import autoCond # Ensure autoCond is imported
84 
85  # Ensure options.version is defined and set correctly
86  version_key = '2026' + options.version # This constructs the key for accessing the properties dictionary
87  print(f"Constructed version key: {version_key}")
88 
89  # Check if the key exists in properties for 2026
90  if version_key in properties[2026]:
91  # Get the specific global tag for this version
92  global_tag_key = properties[2026][version_key]['GT']
93  print(f"Global tag key from properties: {global_tag_key}")
94 
95  # Check if this key exists in autoCond
96  if global_tag_key.replace("auto:", "") in autoCond:
97  # Set the global tag
98  from Configuration.AlCa.GlobalTag import GlobalTag
99  process.GlobalTag = GlobalTag(process.GlobalTag, global_tag_key, '')
100  else:
101  raise KeyError(f"Global tag key '{global_tag_key}' not found in autoCond.")
102  else:
103  raise KeyError(f"Version key '{version_key}' not found in properties[2026].")
104  process.load('Configuration.Geometry.GeometryExtended2026'+options.version+'Reco_cff')
105  process.trackerGeometry.applyAlignment = cms.bool(False)
106 
107  elif score == "MaPSA":
108  process.load('Geometry.TrackerGeometryBuilder.idealForDigiTrackerGeometry_cff')
109  process.load('Geometry.TrackerCommonData.mapsaGeometryXML_cfi')
110  process.load('Geometry.TrackerNumberingBuilder.trackerNumberingGeometry_cfi')
111  process.load('Geometry.TrackerNumberingBuilder.trackerTopology_cfi')
112  process.load('Geometry.TrackerGeometryBuilder.trackerParameters_cfi')
113  process.load('Geometry.TrackerGeometryBuilder.trackerGeometry_cfi')
114  process.trackerGeometry.applyAlignment = cms.bool(False)
115  process.load('RecoTracker.GeometryESProducer.TrackerRecoGeometryESProducer_cfi')
116 
117  process.load('Geometry.CommonTopologies.bareGlobalTrackingGeometry_cfi')
118 
119  elif score == "HGCTB160":
120  process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
121  from Configuration.AlCa.autoCond import autoCond
122  process.GlobalTag.globaltag = autoCond['mc']
123  process.load('Geometry.HGCalTBCommonData.hgcalTBParametersInitialization_cfi')
124  process.load('Geometry.HGCalTBCommonData.hgcalTBNumberingInitialization_cfi')
125  process.load('Geometry.CaloEventSetup.HGCalTBTopology_cfi')
126  process.load('Geometry.HGCalGeometry.HGCalTBGeometryESProducer_cfi')
127  process.load('Geometry.CaloEventSetup.CaloTopology_cfi')
128  process.load('Geometry.CaloEventSetup.CaloGeometryBuilder_cfi')
129  process.CaloGeometryBuilder = cms.ESProducer(
130  "CaloGeometryBuilder",
131  SelectedCalos = cms.vstring("HGCalEESensitive")
132  )
133  process.load("SimG4CMS.HGCalTestBeam.HGCalTB160XML_cfi")
134 
135  else:
136  help()
137 
138 
def recoGeoLoad(score, properties)
void print(TMatrixD &m, const char *label=nullptr, bool mathematicaFormat=false)
Definition: Utilities.cc:47

◆ versionCheck()

def dumpRecoGeometry_cfg.versionCheck (   ver)

Definition at line 39 of file dumpRecoGeometry_cfg.py.

References help(), and print().

Referenced by recoGeoLoad().

39 def versionCheck(ver):
40  if ver == "":
41  print("Please, specify 2026 scenario version\n")
42  print(sorted([x[1] for x in detectorVersionDict.items()]))
43  print("")
44  help()
45 
void print(TMatrixD &m, const char *label=nullptr, bool mathematicaFormat=false)
Definition: Utilities.cc:47

Variable Documentation

◆ Calo

dumpRecoGeometry_cfg.Calo

◆ defaultOutputFileName

dumpRecoGeometry_cfg.defaultOutputFileName

Definition at line 141 of file dumpRecoGeometry_cfg.py.

◆ defaultVersion

dumpRecoGeometry_cfg.defaultVersion

Definition at line 9 of file dumpRecoGeometry_cfg.py.

◆ dump

dumpRecoGeometry_cfg.dump

Definition at line 229 of file dumpRecoGeometry_cfg.py.

◆ era

dumpRecoGeometry_cfg.era

◆ era_key

dumpRecoGeometry_cfg.era_key

Definition at line 207 of file dumpRecoGeometry_cfg.py.

◆ input

dumpRecoGeometry_cfg.input

Definition at line 216 of file dumpRecoGeometry_cfg.py.

◆ level

dumpRecoGeometry_cfg.level

Definition at line 242 of file dumpRecoGeometry_cfg.py.

◆ maxEvents

dumpRecoGeometry_cfg.maxEvents

Definition at line 216 of file dumpRecoGeometry_cfg.py.

◆ Muon

dumpRecoGeometry_cfg.Muon

◆ options

dumpRecoGeometry_cfg.options

Definition at line 139 of file dumpRecoGeometry_cfg.py.

◆ out

dumpRecoGeometry_cfg.out

Definition at line 223 of file dumpRecoGeometry_cfg.py.

◆ outputFileName

dumpRecoGeometry_cfg.outputFileName

Definition at line 231 of file dumpRecoGeometry_cfg.py.

◆ p

dumpRecoGeometry_cfg.p

Definition at line 248 of file dumpRecoGeometry_cfg.py.

◆ process

dumpRecoGeometry_cfg.process

Definition at line 211 of file dumpRecoGeometry_cfg.py.

◆ prop_key

dumpRecoGeometry_cfg.prop_key

Definition at line 196 of file dumpRecoGeometry_cfg.py.

◆ ResetRootErrHandler

dumpRecoGeometry_cfg.ResetRootErrHandler

Definition at line 214 of file dumpRecoGeometry_cfg.py.

◆ source

dumpRecoGeometry_cfg.source

Definition at line 215 of file dumpRecoGeometry_cfg.py.

◆ tagInfo

dumpRecoGeometry_cfg.tagInfo

Definition at line 230 of file dumpRecoGeometry_cfg.py.

Referenced by cms::HTTTopJetProducer.addHTTTopJetTagInfoCollection(), SoftLeptonTagPlotter.analyzeTag(), TrackCountingTagPlotter.analyzeTag(), IPTagPlotter< Container, Base >.analyzeTag(), TrackProbabilityTagPlotter.analyzeTag(), CandidateBoostedDoubleSecondaryVertexComputer.discriminator(), MuonTagger.discriminator(), CandidateChargeBTagComputer.discriminator(), LeptonTaggerByPt.discriminator(), ElectronTagger.discriminator(), MuonTaggerNoIP.discriminator(), CharmTagger.discriminator(), LeptonTaggerByIP.discriminator(), HeavyIonCSVTagger.discriminator(), LeptonTaggerDistance.discriminator(), cond::payloadInspector::RunHistoryPlot< PayloadType, std::pair< double, double > >.fill(), cond::payloadInspector::TimeHistoryPlot< PayloadType, std::pair< double, double > >.fill(), popcon::RpcDataFebmap.getNewObjects(), popcon::RpcDataGasMix.getNewObjects(), popcon::RpcObGasData.getNewObjects(), popcon::RPCObPVSSmapData.getNewObjects(), popcon::RpcDataI.getNewObjects(), popcon::RpcDataS.getNewObjects(), popcon::RpcDataT.getNewObjects(), popcon::RpcDataUXC.getNewObjects(), popcon::RpcDataV.getNewObjects(), SiStripDQMPopConSourceHandler< SiStripBadStrip >.getNewObjects(), popcon::L1RPCHwConfigSourceHandler.getNewObjects(), popcon::RPCEMapSourceHandler.getNewObjects(), popcon::EcalSRPHandler.getNewObjects(), popcon::EcalLaser_weekly_Linearization.getNewObjects(), popcon::EcalTPGFineGrainEBIdMapHandler.getNewObjects(), popcon::EcalTPGWeightIdMapHandler.getNewObjects(), popcon::EcalTPGLinConstHandler.getNewObjects(), popcon::EcalTPGLutIdMapHandler.getNewObjects(), popcon::EcalTPGOddWeightIdMapHandler.getNewObjects(), popcon::EcalTPGBadStripHandler.getNewObjects(), popcon::EcalTPGPhysicsConstHandler.getNewObjects(), popcon::EcalTPGBadTTHandler.getNewObjects(), popcon::EcalTPGTPModeHandler.getNewObjects(), popcon::EcalDAQHandler.getNewObjects(), popcon::EcalTPGLinPed.getNewObjects(), popcon::EcalTPGPedfromFile.getNewObjects(), popcon::EcalTPGBadXTHandler.getNewObjects(), popcon::EcalTPGFineGrainTowerEEHandler.getNewObjects(), popcon::EcalTPGFineGrainEBGroupHandler.getNewObjects(), popcon::EcalTPGWeightGroupHandler.getNewObjects(), popcon::EcalTPGSlidingWindowHandler.getNewObjects(), popcon::EcalLaserHandler.getNewObjects(), popcon::EcalTPGOddWeightGroupHandler.getNewObjects(), popcon::EcalADCToGeVHandler.getNewObjects(), popcon::EcalLaser_weekly_Handler.getNewObjects(), popcon::EcalTPGFineGrainStripEEHandler.getNewObjects(), popcon::EcalTPGPedestalsHandler.getNewObjects(), popcon::EcalTPGLutGroupHandler.getNewObjects(), popcon::EcalTPGSpikeThresholdHandler.getNewObjects(), popcon::EcalDCSHandler.getNewObjects(), popcon::EcalChannelStatusHandler.getNewObjects(), popcon::EcalPedestalsHandler.getNewObjectsH2(), popcon::EcalPedestalsHandler.getNewObjectsP5(), BTVHLTOfflineSource.getOfflineBTagTracks(), SiStripDQMPopConSourceHandler< SiStripBadStrip >.isTransferNeeded(), JetTagProducer.JetTagProducer(), l1t::DataWriter.lastPayloadToken(), l1t::DataWriterExt.lastPayloadToken(), SoftPFElectronTagInfoProducer.produce(), JetTagProducer.produce(), SoftPFMuonTagInfoProducer.produce(), CATopJetTagger.produce(), PixelClusterTagInfoProducer.produce(), SiStripDQMPopConSourceHandler< SiStripBadStrip >.setForTransfer(), l1t::DataWriter.updateIOV(), and l1t::DataWriterExt.updateIOV().

◆ Timing

dumpRecoGeometry_cfg.Timing

Definition at line 228 of file dumpRecoGeometry_cfg.py.

◆ Tracker

dumpRecoGeometry_cfg.Tracker

Definition at line 225 of file dumpRecoGeometry_cfg.py.

◆ varType

dumpRecoGeometry_cfg.varType

◆ version_key

dumpRecoGeometry_cfg.version_key

Definition at line 197 of file dumpRecoGeometry_cfg.py.