CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Classes | Functions | Variables
confdb Namespace Reference

Classes

class  HLTProcess
 

Functions

def _fix_parameter
 
def addGlobalOptions
 untracked parameters with NO default in the code if 'hltHcalDataIntegrityMonitor' in %(dict)s: %(process)shltHcalDataIntegrityMonitor.RawDataLabel = cms.untracked.InputTag("rawDataCollector") if 'hltDt4DSegments' in %(dict)s: %(process)shltDt4DSegments.debug = cms.untracked.bool( False ) """ More...
 
def build_source
 
def buildOptions
 
def buildPathList
 
def dumppaths
 
def fixForFastSim
 
def fixForMC
 
def fixPrescales
 
def instrumentErrorEventType
 
def instrumentOpenMode
 
def instrumentTiming
 
def loadAdditionalConditions
 
def loadCff
 
def overrideGlobalTag
 
def overrideL1MenuXml
 
def overrideOutput
 
def overrideParameters
 
def overrideProcessName
 
def runL1Emulator
 
def runL1EmulatorGT
 
def splitter
 
def updateMessageLogger
 

Variables

 all_paths
 
 data
 
 source
 

Function Documentation

def confdb._fix_parameter (   self,
  args 
)
private
arguments:
    name:     parameter name (optional)
    type:     parameter type (look for tracked and untracked variants)
    value:    original value
    replace:  replacement value

Definition at line 319 of file confdb.py.

320  def _fix_parameter(self, **args):
321  """arguments:
322  name: parameter name (optional)
323  type: parameter type (look for tracked and untracked variants)
324  value: original value
325  replace: replacement value
326  """
327  if 'name' in args:
328  self.data = re.sub(
329  r'%(name)s = cms(?P<tracked>(?:\.untracked)?)\.%(type)s\( (?P<quote>["\']?)%(value)s(?P=quote)' % args,
330  r'%(name)s = cms\g<tracked>.%(type)s( \g<quote>%(replace)s\g<quote>' % args,
331  self.data)
332  else:
333  self.data = re.sub(
334  r'cms(?P<tracked>(?:\.untracked)?)\.%(type)s\( (?P<quote>["\']?)%(value)s(?P=quote)' % args,
335  r'cms\g<tracked>.%(type)s( \g<quote>%(replace)s\g<quote>' % args,
336  self.data)
337 
def _fix_parameter
Definition: confdb.py:319
def confdb.addGlobalOptions (   self)

untracked parameters with NO default in the code if 'hltHcalDataIntegrityMonitor' in %(dict)s: %(process)shltHcalDataIntegrityMonitor.RawDataLabel = cms.untracked.InputTag("rawDataCollector") if 'hltDt4DSegments' in %(dict)s: %(process)shltDt4DSegments.debug = cms.untracked.bool( False ) """

dummyfy hltGetConditions in cff's if 'hltGetConditions' in %(dict)s and 'HLTriggerFirstPath' in %(dict)s : %(process)shltDummyConditions = cms.EDFilter( "HLTBool", result = cms.bool( True ) ) %(process)sHLTriggerFirstPath.replace(%(process)shltGetConditions,%(process)shltDummyConditions) """

Definition at line 301 of file confdb.py.

302  def addGlobalOptions(self):
303  # add global options
304  self.data += """
305 # limit the number of events to be processed
306 %%(process)smaxEvents = cms.untracked.PSet(
307  input = cms.untracked.int32( %d )
308 )
309 """ % self.config.events
310 
311  if not self.config.profiling:
312  self.data += """
313 # enable the TrigReport and TimeReport
314 %(process)soptions = cms.untracked.PSet(
315  wantSummary = cms.untracked.bool( True )
316 )
317 """
318 
def addGlobalOptions
untracked parameters with NO default in the code if &#39;hltHcalDataIntegrityMonitor&#39; in %(dict)s: %(proc...
Definition: confdb.py:301
def confdb.build_source (   self)

Definition at line 1162 of file confdb.py.

1163  def build_source(self):
1164  if self.config.input:
1165  # if a dataset or a list of input files was given, use it
1166  if self.config.input[0:8] == 'dataset:':
1167  from dbsFileQuery import dbsFileQuery
1168  # extract the dataset name, and use DBS to fine the list of LFNs
1169  dataset = self.config.input[8:]
1170  query = 'find file where dataset=' + dataset
1171  files = dbsFileQuery(query)
1172  self.source = files
1173  else:
1174  # assume a list of input files
1175  self.source = self.config.input.split(',')
1176  elif self.config.online:
1177  # online we always run on data
1178  self.source = [ "file:/tmp/InputCollection.root" ]
1179  elif self.config.data:
1180  # offline we can run on data...
1181  self.source = [ "file:RelVal_Raw_%s_DATA.root" % self.config.type ]
1182  else:
1183  # ...or on mc
1184  self.source = [ "file:RelVal_Raw_%s_STARTUP.root" % self.config.type ]
1185 
1186  self.data += """
1187 %(process)ssource = cms.Source( "PoolSource",
1188  fileNames = cms.untracked.vstring(
1189 """
1190  if self.source:
1191  for line in self.source:
1192  self.data += " '%s',\n" % line
1193  self.data += """ ),
1194  secondaryFileNames = cms.untracked.vstring(
1195 """
1196  if self.parent:
1197  for line in self.parent:
1198  self.data += " '%s',\n" % line
1199  self.data += """ ),
1200  inputCommands = cms.untracked.vstring(
1201  'keep *'
1202  )
1203 )
1204 """
def build_source
Definition: confdb.py:1162
def confdb.buildOptions (   self)

Definition at line 871 of file confdb.py.

References python.multivaluedict.append().

872  def buildOptions(self):
873  # common configuration for all scenarios
874  self.options['services'].append( "-FUShmDQMOutputService" )
875  self.options['services'].append( "-DQM" )
876 
877  if self.config.fragment:
878  # extract a configuration file fragment
879  self.options['essources'].append( "-GlobalTag" )
880  self.options['essources'].append( "-HepPDTESSource" )
881  self.options['essources'].append( "-XMLIdealGeometryESSource" )
882  self.options['essources'].append( "-eegeom" )
883  self.options['essources'].append( "-es_hardcode" )
884  self.options['essources'].append( "-magfield" )
885 
886  self.options['esmodules'].append( "-AutoMagneticFieldESProducer" )
887  self.options['esmodules'].append( "-SlaveField0" )
888  self.options['esmodules'].append( "-SlaveField20" )
889  self.options['esmodules'].append( "-SlaveField30" )
890  self.options['esmodules'].append( "-SlaveField35" )
891  self.options['esmodules'].append( "-SlaveField38" )
892  self.options['esmodules'].append( "-SlaveField40" )
893  self.options['esmodules'].append( "-VBF0" )
894  self.options['esmodules'].append( "-VBF20" )
895  self.options['esmodules'].append( "-VBF30" )
896  self.options['esmodules'].append( "-VBF35" )
897  self.options['esmodules'].append( "-VBF38" )
898  self.options['esmodules'].append( "-VBF40" )
899  self.options['esmodules'].append( "-CSCGeometryESModule" )
900  self.options['esmodules'].append( "-CaloGeometryBuilder" )
901  self.options['esmodules'].append( "-CaloTowerHardcodeGeometryEP" )
902  self.options['esmodules'].append( "-CastorHardcodeGeometryEP" )
903  self.options['esmodules'].append( "-DTGeometryESModule" )
904  self.options['esmodules'].append( "-EcalBarrelGeometryEP" )
905  self.options['esmodules'].append( "-EcalElectronicsMappingBuilder" )
906  self.options['esmodules'].append( "-EcalEndcapGeometryEP" )
907  self.options['esmodules'].append( "-EcalLaserCorrectionService" )
908  self.options['esmodules'].append( "-EcalPreshowerGeometryEP" )
909  self.options['esmodules'].append( "-HcalHardcodeGeometryEP" )
910  self.options['esmodules'].append( "-HcalTopologyIdealEP" )
911  self.options['esmodules'].append( "-MuonNumberingInitialization" )
912  self.options['esmodules'].append( "-ParametrizedMagneticFieldProducer" )
913  self.options['esmodules'].append( "-RPCGeometryESModule" )
914  self.options['esmodules'].append( "-SiStripGainESProducer" )
915  self.options['esmodules'].append( "-SiStripRecHitMatcherESProducer" )
916  self.options['esmodules'].append( "-SiStripQualityESProducer" )
917  self.options['esmodules'].append( "-StripCPEfromTrackAngleESProducer" )
918  self.options['esmodules'].append( "-TrackerDigiGeometryESModule" )
919  self.options['esmodules'].append( "-TrackerGeometricDetESModule" )
920  self.options['esmodules'].append( "-VolumeBasedMagneticFieldESProducer" )
921  self.options['esmodules'].append( "-ZdcHardcodeGeometryEP" )
922  self.options['esmodules'].append( "-hcal_db_producer" )
923  self.options['esmodules'].append( "-L1GtTriggerMaskAlgoTrigTrivialProducer" )
924  self.options['esmodules'].append( "-L1GtTriggerMaskTechTrigTrivialProducer" )
925  self.options['esmodules'].append( "-hltESPEcalTrigTowerConstituentsMapBuilder" )
926  self.options['esmodules'].append( "-hltESPGlobalTrackingGeometryESProducer" )
927  self.options['esmodules'].append( "-hltESPMuonDetLayerGeometryESProducer" )
928  self.options['esmodules'].append( "-hltESPTrackerRecoGeometryESProducer" )
929  if not self.config.fastsim:
930  self.options['esmodules'].append( "-CaloTowerGeometryFromDBEP" )
931  self.options['esmodules'].append( "-CastorGeometryFromDBEP" )
932  self.options['esmodules'].append( "-EcalBarrelGeometryFromDBEP" )
933  self.options['esmodules'].append( "-EcalEndcapGeometryFromDBEP" )
934  self.options['esmodules'].append( "-EcalPreshowerGeometryFromDBEP" )
935  self.options['esmodules'].append( "-HcalGeometryFromDBEP" )
936  self.options['esmodules'].append( "-ZdcGeometryFromDBEP" )
937  self.options['esmodules'].append( "-XMLFromDBSource" )
938  self.options['esmodules'].append( "-sistripconn" )
939 
940  self.options['services'].append( "-MessageLogger" )
941  self.options['services'].append( "-DQMStore" )
942  self.options['services'].append( "-MicroStateService" )
943  self.options['services'].append( "-ModuleWebRegistry" )
944  self.options['services'].append( "-TimeProfilerService" )
945 
946  self.options['psets'].append( "-maxEvents" )
947  self.options['psets'].append( "-options" )
948 
949  if self.config.fragment or (self.config.prescale and (self.config.prescale.lower() == 'none')):
950  self.options['services'].append( "-PrescaleService" )
951 
952  if self.config.fragment or self.config.timing:
953  self.options['services'].append( "-FastTimerService" )
954 
955  if self.config.fastsim:
956  # remove components not supported or needed by fastsim
957  self.options['esmodules'].append( "-navigationSchoolESProducer" )
958  self.options['esmodules'].append( "-TransientTrackBuilderESProducer" )
959  self.options['esmodules'].append( "-SteppingHelixPropagatorAny" )
960  self.options['esmodules'].append( "-OppositeMaterialPropagator" )
961  self.options['esmodules'].append( "-MaterialPropagator" )
962  self.options['esmodules'].append( "-CaloTowerConstituentsMapBuilder" )
963  self.options['esmodules'].append( "-CaloTopologyBuilder" )
964 
965  self.options['modules'].append( "hltL3MuonIsolations" )
966  self.options['modules'].append( "hltPixelVertices" )
967  self.options['modules'].append( "-hltCkfL1SeededTrackCandidates" )
968  self.options['modules'].append( "-hltCtfL1SeededithMaterialTracks" )
969  self.options['modules'].append( "-hltCkf3HitL1SeededTrackCandidates" )
970  self.options['modules'].append( "-hltCtf3HitL1SeededWithMaterialTracks" )
971  self.options['modules'].append( "-hltCkf3HitActivityTrackCandidates" )
972  self.options['modules'].append( "-hltCtf3HitActivityWithMaterialTracks" )
973  self.options['modules'].append( "-hltActivityCkfTrackCandidatesForGSF" )
974  self.options['modules'].append( "-hltL1SeededCkfTrackCandidatesForGSF" )
975  self.options['modules'].append( "-hltMuCkfTrackCandidates" )
976  self.options['modules'].append( "-hltMuCtfTracks" )
977  self.options['modules'].append( "-hltTau3MuCkfTrackCandidates" )
978  self.options['modules'].append( "-hltTau3MuCtfWithMaterialTracks" )
979  self.options['modules'].append( "-hltMuTrackJpsiCkfTrackCandidates" )
980  self.options['modules'].append( "-hltMuTrackJpsiCtfTracks" )
981  self.options['modules'].append( "-hltMuTrackJpsiEffCkfTrackCandidates" )
982  self.options['modules'].append( "-hltMuTrackJpsiEffCtfTracks" )
983  self.options['modules'].append( "-hltJpsiTkPixelSeedFromL3Candidate" )
984  self.options['modules'].append( "-hltCkfTrackCandidatesJpsiTk" )
985  self.options['modules'].append( "-hltCtfWithMaterialTracksJpsiTk" )
986  self.options['modules'].append( "-hltMuTrackCkfTrackCandidatesOnia" )
987  self.options['modules'].append( "-hltMuTrackCtfTracksOnia" )
988 
989  self.options['modules'].append( "-hltESRegionalEgammaRecHit" )
990  self.options['modules'].append( "-hltEcalRegionalJetsFEDs" )
991  self.options['modules'].append( "-hltEcalRegionalMuonsFEDs" )
992  self.options['modules'].append( "-hltEcalRegionalEgammaFEDs" )
993  self.options['modules'].append( "-hltFEDSelector" )
994  self.options['modules'].append( "-hltL3TrajSeedOIHit" )
995  self.options['modules'].append( "-hltL3TrajSeedIOHit" )
996  self.options['modules'].append( "-hltL3NoFiltersTrajSeedOIHit" )
997  self.options['modules'].append( "-hltL3NoFiltersTrajSeedIOHit" )
998  self.options['modules'].append( "-hltL3TrackCandidateFromL2OIState" )
999  self.options['modules'].append( "-hltL3TrackCandidateFromL2OIHit" )
1000  self.options['modules'].append( "-hltL3TrackCandidateFromL2IOHit" )
1001  self.options['modules'].append( "-hltL3TrackCandidateFromL2NoVtx" )
1002  self.options['modules'].append( "-hltHcalDigis" )
1003  self.options['modules'].append( "-hltHoreco" )
1004  self.options['modules'].append( "-hltHfreco" )
1005  self.options['modules'].append( "-hltHbhereco" )
1006  self.options['modules'].append( "-hltEcalRegionalRestFEDs" )
1007  self.options['modules'].append( "-hltEcalRegionalESRestFEDs" )
1008  self.options['modules'].append( "-hltEcalRawToRecHitFacility" )
1009  self.options['modules'].append( "-hltESRawToRecHitFacility" )
1010  self.options['modules'].append( "-hltEcalRegionalJetsRecHit" )
1011  self.options['modules'].append( "-hltEcalRegionalMuonsRecHit" )
1012  self.options['modules'].append( "-hltEcalRegionalEgammaRecHit" )
1013  self.options['modules'].append( "-hltEcalRecHitAll" )
1014  self.options['modules'].append( "-hltESRecHitAll" )
1015  # === hltPF
1016  self.options['modules'].append( "-hltPFJetCkfTrackCandidates" )
1017  self.options['modules'].append( "-hltPFJetCtfWithMaterialTracks" )
1018  self.options['modules'].append( "-hltPFlowTrackSelectionHighPurity" )
1019  # === hltFastJet
1020  self.options['modules'].append( "-hltDisplacedHT250L1FastJetRegionalPixelSeedGenerator" )
1021  self.options['modules'].append( "-hltDisplacedHT250L1FastJetRegionalCkfTrackCandidates" )
1022  self.options['modules'].append( "-hltDisplacedHT250L1FastJetRegionalCtfWithMaterialTracks" )
1023  self.options['modules'].append( "-hltDisplacedHT300L1FastJetRegionalPixelSeedGenerator" )
1024  self.options['modules'].append( "-hltDisplacedHT300L1FastJetRegionalCkfTrackCandidates" )
1025  self.options['modules'].append( "-hltDisplacedHT300L1FastJetRegionalCtfWithMaterialTracks" )
1026  self.options['modules'].append( "-hltBLifetimeRegionalPixelSeedGeneratorbbPhiL1FastJet" )
1027  self.options['modules'].append( "-hltBLifetimeRegionalCkfTrackCandidatesbbPhiL1FastJet" )
1028  self.options['modules'].append( "-hltBLifetimeRegionalCtfWithMaterialTracksbbPhiL1FastJet" )
1029  self.options['modules'].append( "-hltBLifetimeRegionalPixelSeedGeneratorHbbVBF" )
1030  self.options['modules'].append( "-hltBLifetimeRegionalCkfTrackCandidatesHbbVBF" )
1031  self.options['modules'].append( "-hltBLifetimeRegionalCtfWithMaterialTracksHbbVBF" )
1032  self.options['modules'].append( "-hltBLifetimeBTagIP3D1stTrkRegionalPixelSeedGeneratorJet20HbbL1FastJet" )
1033  self.options['modules'].append( "-hltBLifetimeBTagIP3D1stTrkRegionalCkfTrackCandidatesJet20HbbL1FastJet" )
1034  self.options['modules'].append( "-hltBLifetimeBTagIP3D1stTrkRegionalCtfWithMaterialTracksJet20HbbL1FastJet" )
1035  self.options['modules'].append( "-hltBLifetimeDiBTagIP3D1stTrkRegionalPixelSeedGeneratorJet20HbbL1FastJet" )
1036  self.options['modules'].append( "-hltBLifetimeDiBTagIP3D1stTrkRegionalCkfTrackCandidatesJet20HbbL1FastJet" )
1037  self.options['modules'].append( "-hltBLifetimeDiBTagIP3D1stTrkRegionalCtfWithMaterialTracksJet20HbbL1FastJet" )
1038  # === hltBLifetimeRegional
1039  self.options['modules'].append( "-hltBLifetimeRegionalPixelSeedGeneratorHbb" )
1040  self.options['modules'].append( "-hltBLifetimeRegionalCkfTrackCandidatesHbb" )
1041  self.options['modules'].append( "-hltBLifetimeRegionalCtfWithMaterialTracksHbb" )
1042  self.options['modules'].append( "-hltBLifetimeRegionalPixelSeedGeneratorbbPhi" )
1043  self.options['modules'].append( "-hltBLifetimeRegionalCkfTrackCandidatesbbPhi" )
1044  self.options['modules'].append( "-hltBLifetimeRegionalCtfWithMaterialTracksbbPhi" )
1045  self.options['modules'].append( "-hltBLifetimeBTagIP3D1stTrkRegionalPixelSeedGeneratorJet20Hbb" )
1046  self.options['modules'].append( "-hltBLifetimeBTagIP3D1stTrkRegionalCkfTrackCandidatesJet20Hbb" )
1047  self.options['modules'].append( "-hltBLifetimeBTagIP3D1stTrkRegionalCtfWithMaterialTracksJet20Hbb" )
1048  self.options['modules'].append( "-hltBLifetimeDiBTagIP3D1stTrkRegionalPixelSeedGeneratorJet20Hbb" )
1049  self.options['modules'].append( "-hltBLifetimeDiBTagIP3D1stTrkRegionalCkfTrackCandidatesJet20Hbb" )
1050  self.options['modules'].append( "-hltBLifetimeDiBTagIP3D1stTrkRegionalCtfWithMaterialTracksJet20Hbb" )
1051  self.options['modules'].append( "-hltBLifetimeFastRegionalPixelSeedGeneratorHbbVBF" )
1052  self.options['modules'].append( "-hltBLifetimeFastRegionalCkfTrackCandidatesHbbVBF" )
1053  self.options['modules'].append( "-hltBLifetimeFastRegionalCtfWithMaterialTracksHbbVBF" )
1054  self.options['modules'].append( "-hltBLifetimeRegionalPixelSeedGeneratorbbPhiL1FastJetFastPV" )
1055  self.options['modules'].append( "-hltBLifetimeRegionalCkfTrackCandidatesbbPhiL1FastJetFastPV" )
1056  self.options['modules'].append( "-hltBLifetimeRegionalCtfWithMaterialTracksbbPhiL1FastJetFastPV" )
1057  self.options['modules'].append( "-hltFastPixelBLifetimeRegionalPixelSeedGeneratorHbb" )
1058  self.options['modules'].append( "-hltFastPixelBLifetimeRegionalCkfTrackCandidatesHbb" )
1059  self.options['modules'].append( "-hltFastPixelBLifetimeRegionalCtfWithMaterialTracksHbb" )
1060 
1061  self.options['modules'].append( "-hltPixelTracksForMinBias" )
1062  self.options['modules'].append( "-hltPixelTracksForHighMult" )
1063  self.options['modules'].append( "-hltRegionalPixelTracks" )
1064  self.options['modules'].append( "-hltPixelTracksReg" )
1065  self.options['modules'].append( "-hltPixelTracksL3Muon" )
1066  self.options['modules'].append( "-hltPixelTracksGlbTrkMuon" )
1067  self.options['modules'].append( "-hltPixelTracksHighPtTkMuIso" )
1068  self.options['modules'].append( "-hltPixelTracksHybrid" )
1069  self.options['modules'].append( "-hltPixelTracksForPhotons" )
1070  self.options['modules'].append( "-hltPixelTracksForEgamma" )
1071  self.options['modules'].append( "-hltPixelTracksElectrons" )
1072  self.options['modules'].append( "-hltIter4Merged" )
1073  self.options['modules'].append( "-hltIter4MergedForTau" )
1074  self.options['modules'].append( "-hltIter4Tau3MuMerged" )
1075  self.options['modules'].append( "-hltIter4MergedReg" )
1076  self.options['modules'].append( "-hltIter2MergedForElectrons" )
1077  self.options['modules'].append( "-hltIter2ElectronsMerged" )
1078  self.options['modules'].append( "-hltIter2MergedForPhotons" )
1079  self.options['modules'].append( "-hltIter2L3MuonMerged" )
1080  self.options['modules'].append( "-hltIter2L3MuonMergedReg" )
1081  self.options['modules'].append( "-hltIter2GlbTrkMuonMerged" )
1082  self.options['modules'].append( "-hltIter2HighPtTkMuIsoMerged" )
1083  self.options['modules'].append( "-hltIter2MergedForBTag" )
1084 
1085  self.options['modules'].append( "-hltFastPixelHitsVertex" )
1086  self.options['modules'].append( "-hltFastPixelTracks")
1087  self.options['modules'].append( "-hltFastPixelTracksRecover")
1088 
1089  self.options['modules'].append( "-hltPixelLayerPairs" )
1090  self.options['modules'].append( "-hltPixelLayerTriplets" )
1091  self.options['modules'].append( "-hltPixelLayerTripletsReg" )
1092  self.options['modules'].append( "-hltPixelLayerTripletsHITHB" )
1093  self.options['modules'].append( "-hltPixelLayerTripletsHITHE" )
1094  self.options['modules'].append( "-hltMixedLayerPairs" )
1095 
1096  self.options['modules'].append( "-hltFastPrimaryVertexbbPhi")
1097  self.options['modules'].append( "-hltPixelTracksFastPVbbPhi")
1098  self.options['modules'].append( "-hltPixelTracksRecoverbbPhi" )
1099  self.options['modules'].append( "-hltFastPixelHitsVertexVHbb" )
1100  self.options['modules'].append( "-hltFastPixelTracksVHbb" )
1101  self.options['modules'].append( "-hltFastPixelTracksRecoverVHbb" )
1102 
1103  self.options['modules'].append( "-hltFastPrimaryVertex")
1104  self.options['modules'].append( "-hltFastPVPixelVertexFilter")
1105  self.options['modules'].append( "-hltFastPVPixelTracks")
1106  self.options['modules'].append( "-hltFastPVPixelTracksRecover" )
1107 
1108  self.options['modules'].append( "-hltIter4Tau3MuMerged" )
1109  self.options['modules'].append( "hltPixelMatchElectronsActivity" )
1110 
1111  self.options['modules'].append( "-hltMuonCSCDigis" )
1112  self.options['modules'].append( "-hltMuonDTDigis" )
1113  self.options['modules'].append( "-hltMuonRPCDigis" )
1114  self.options['modules'].append( "-hltGtDigis" )
1115  self.options['modules'].append( "-hltL1GtTrigReport" )
1116  self.options['modules'].append( "hltCsc2DRecHits" )
1117  self.options['modules'].append( "hltDt1DRecHits" )
1118  self.options['modules'].append( "hltRpcRecHits" )
1119  self.options['modules'].append( "-hltScalersRawToDigi" )
1120 
1121  self.options['sequences'].append( "-HLTL1SeededEgammaRegionalRecoTrackerSequence" )
1122  self.options['sequences'].append( "-HLTEcalActivityEgammaRegionalRecoTrackerSequence" )
1123  self.options['sequences'].append( "-HLTPixelMatchElectronActivityTrackingSequence" )
1124  self.options['sequences'].append( "-HLTDoLocalStripSequence" )
1125  self.options['sequences'].append( "-HLTDoLocalPixelSequence" )
1126  self.options['sequences'].append( "-HLTDoLocalPixelSequenceRegL2Tau" )
1127  self.options['sequences'].append( "-HLTDoLocalStripSequenceReg" )
1128  self.options['sequences'].append( "-HLTDoLocalPixelSequenceReg" )
1129  self.options['sequences'].append( "-HLTDoLocalStripSequenceRegForBTag" )
1130  self.options['sequences'].append( "-HLTDoLocalPixelSequenceRegForBTag" )
1131  self.options['sequences'].append( "-hltSiPixelDigis" )
1132  self.options['sequences'].append( "-hltSiPixelClusters" )
1133  self.options['sequences'].append( "-hltSiPixelRecHits" )
1134  self.options['sequences'].append( "-HLTRecopixelvertexingSequence" )
1135  self.options['sequences'].append( "-HLTEndSequence" )
1136  self.options['sequences'].append( "-HLTBeginSequence" )
1137  self.options['sequences'].append( "-HLTBeginSequenceNZS" )
1138  self.options['sequences'].append( "-HLTBeginSequenceBPTX" )
1139  self.options['sequences'].append( "-HLTBeginSequenceAntiBPTX" )
1140  self.options['sequences'].append( "-HLTHBHENoiseSequence" )
1141  self.options['sequences'].append( "-HLTIterativeTrackingIter04" )
1142  self.options['sequences'].append( "-HLTIterativeTrackingIter02" )
1143  self.options['sequences'].append( "-HLTIterativeTracking" )
1144  self.options['sequences'].append( "-HLTIterativeTrackingTau3Mu" )
1145  self.options['sequences'].append( "-HLTIterativeTrackingReg" )
1146  self.options['sequences'].append( "-HLTIterativeTrackingForElectronsIter02" )
1147  self.options['sequences'].append( "-HLTIterativeTrackingForPhotonsIter02" )
1148  self.options['sequences'].append( "-HLTIterativeTrackingL3MuonIter02" )
1149  self.options['sequences'].append( "-HLTIterativeTrackingGlbTrkMuonIter02" )
1150  self.options['sequences'].append( "-HLTIterativeTrackingL3MuonRegIter02" )
1151  self.options['sequences'].append( "-HLTIterativeTrackingHighPtTkMu" )
1152  self.options['sequences'].append( "-HLTIterativeTrackingHighPtTkMuIsoIter02" )
1153  self.options['sequences'].append( "-HLTIterativeTrackingForBTagIter02" )
1154  self.options['sequences'].append( "-HLTIterativeTrackingForTauIter04" )
1155  self.options['sequences'].append( "-HLTRegionalCKFTracksForL3Isolation" )
1156  self.options['sequences'].append( "-HLTHBHENoiseCleanerSequence" )
1157 
1158  # remove HLTAnalyzerEndpath from fastsim cff's
1159  if self.config.fragment:
1160  self.options['paths'].append( "-HLTAnalyzerEndpath" )
1161 
def buildOptions
Definition: confdb.py:871
def confdb.buildPathList (   self)

Definition at line 814 of file confdb.py.

815  def buildPathList(self):
816  self.all_paths = self.getPathList()
817 
818  if self.config.paths:
819  # no path list was requested, dump the full table, minus unsupported / unwanted paths
820  paths = self.config.paths.split(',')
821  else:
822  # dump only the requested paths, plus the eventual output endpaths
823  paths = []
824 
825  if self.config.fragment or self.config.output in ('none', 'full'):
826  # 'full' removes all outputs (same as 'none') and then adds a single "keep *" output (see the overrideOutput method)
827  if self.config.paths:
828  # paths are removed by default
829  pass
830  else:
831  # drop all output endpaths
832  paths.append( "-*Output" )
833  elif self.config.output == 'minimal':
834  # drop all output endpaths but HLTDQMResultsOutput
835  if self.config.paths:
836  paths.append( "HLTDQMResultsOutput" )
837  else:
838  paths.append( "-*Output" )
839  paths.append( "HLTDQMResultsOutput" )
840  else:
841  # keep / add back all output endpaths
842  if self.config.paths:
843  paths.append( "*Output" )
844  else:
845  pass # paths are kepy by default
846 
847  # drop paths unsupported by fastsim
848  if self.config.fastsim:
849  paths.extend( "-%s" % path for path in self.fastsimUnsupportedPaths )
850 
851  # drop unwanted paths for profiling (and timing studies)
852  if self.config.profiling:
853  paths.append( "-HLTriggerFirstPath" )
854  paths.append( "-HLTAnalyzerEndpath" )
855 
856  # this should never be in any dump (nor online menu)
857  paths.append( "-OfflineOutput" )
858 
859  # expand all wildcards
860  paths = self.expandWildcards(paths, self.all_paths)
861 
862  if self.config.paths:
863  # do an "additive" consolidation
864  self.options['paths'] = self.consolidatePositiveList(paths)
865  if not self.options['paths']:
866  raise RuntimeError('Error: option "--paths %s" does not select any valid paths' % self.config.paths)
867  else:
868  # do a "subtractive" consolidation
869  self.options['paths'] = self.consolidateNegativeList(paths)
870 
def buildPathList
Definition: confdb.py:814
def confdb.dumppaths (   paths)
static

Definition at line 808 of file confdb.py.

809  def dumppaths(paths):
810  sys.stderr.write('Path selection:\n')
811  for path in paths:
812  sys.stderr.write('\t%s\n' % path)
813  sys.stderr.write('\n\n')
def dumppaths
Definition: confdb.py:808
def confdb.fixForFastSim (   self)

Definition at line 349 of file confdb.py.

350  def fixForFastSim(self):
351  if self.config.fastsim:
352  # adapt the hle configuration (fragment) to run under fastsim
353  self.data = re.sub( r'import FWCore.ParameterSet.Config as cms', r'\g<0>\nfrom FastSimulation.HighLevelTrigger.HLTSetup_cff import *', self.data)
354 
355  # remove the definition of streams and datasets
356  self.data = re.compile( r'^streams.*\n(.*\n)*?^\)\s*\n', re.MULTILINE ).sub( '', self.data )
357  self.data = re.compile( r'^datasets.*\n(.*\n)*?^\)\s*\n', re.MULTILINE ).sub( '', self.data )
358 
359  # fix the definition of module
360  # FIXME: this should be updated to take into accout the --l1-emulator option
361  self._fix_parameter( type = 'InputTag', value = 'hltL1extraParticles', replace = 'l1extraParticles')
362  self._fix_parameter(name = 'GMTReadoutCollection', type = 'InputTag', value = 'hltGtDigis', replace = 'gmtDigis')
363  self._fix_parameter( type = 'InputTag', value = 'hltGtDigis', replace = 'gtDigis')
364  self._fix_parameter( type = 'InputTag', value = 'hltL1GtObjectMap', replace = 'gtDigis')
365  self._fix_parameter(name = 'initialSeeds', type = 'InputTag', value = 'noSeedsHere', replace = 'globalPixelSeeds:GlobalPixel')
366  self._fix_parameter(name = 'preFilteredSeeds', type = 'bool', value = 'True', replace = 'False')
367  self._fix_parameter( type = 'InputTag', value = 'hltOfflineBeamSpot', replace = 'offlineBeamSpot')
368  self._fix_parameter( type = 'InputTag', value = 'hltOnlineBeamSpot', replace = 'offlineBeamSpot')
369  self._fix_parameter( type = 'InputTag', value = 'hltMuonCSCDigis', replace = 'simMuonCSCDigis')
370  self._fix_parameter( type = 'InputTag', value = 'hltMuonDTDigis', replace = 'simMuonDTDigis')
371  self._fix_parameter( type = 'InputTag', value = 'hltMuonRPCDigis', replace = 'simMuonRPCDigis')
372  self._fix_parameter( type = 'InputTag', value = 'hltRegionalTracksForL3MuonIsolation', replace = 'hltPixelTracks')
373  self._fix_parameter(name = 'src', type = 'InputTag', value = 'hltHcalTowerNoiseCleaner', replace = 'hltTowerMakerForAll')
374  self._fix_parameter(name = 'src', type = 'InputTag', value = 'hltIter4Tau3MuMerged', replace = 'hltIter4Merged')
375 
376  # MeasurementTrackerEvent
377  self._fix_parameter( type = 'InputTag', value = 'hltSiStripClusters', replace = 'MeasurementTrackerEvent')
378 
379  # fix the definition of sequences and paths
380  self.data = re.sub( r'hltMuonCSCDigis', r'cms.SequencePlaceholder( "simMuonCSCDigis" )', self.data )
381  self.data = re.sub( r'hltMuonDTDigis', r'cms.SequencePlaceholder( "simMuonDTDigis" )', self.data )
382  self.data = re.sub( r'hltMuonRPCDigis', r'cms.SequencePlaceholder( "simMuonRPCDigis" )', self.data )
383  self.data = re.sub( r'HLTEndSequence', r'cms.SequencePlaceholder( "HLTEndSequence" )', self.data )
384  self.data = re.sub( r'hltGtDigis', r'HLTBeginSequence', self.data )
385 
def fixForFastSim
Definition: confdb.py:349
def confdb.fixForMC (   self)

Definition at line 338 of file confdb.py.

339  def fixForMC(self):
340  if not self.config.data:
341  # customise the HLT menu for running on MC
342  if not self.config.fragment:
343  self.data += """
344 # customise the HLT menu for running on MC
345 from HLTrigger.Configuration.customizeHLTforMC import customizeHLTforMC
346 process = customizeHLTforMC(process)
347 """
348 
def fixForMC
Definition: confdb.py:338
def confdb.fixPrescales (   self)

Definition at line 386 of file confdb.py.

387  def fixPrescales(self):
388  # update the PrescaleService to match the new list of paths
389  if self.options['paths']:
390  if self.options['paths'][0][0] == '-':
391  # drop requested paths
392  for minuspath in self.options['paths']:
393  path = minuspath[1:]
394  self.data = re.sub(r' cms.PSet\( pathName = cms.string\( "%s" \),\n prescales = cms.vuint32\( .* \)\n \),?\n' % path, '', self.data)
395  else:
396  # keep requested paths
397  for path in self.all_paths:
398  if path not in self.options['paths']:
399  self.data = re.sub(r' cms.PSet\( pathName = cms.string\( "%s" \),\n prescales = cms.vuint32\( .* \)\n \),?\n' % path, '', self.data)
400 
401  if self.config.prescale and (self.config.prescale.lower() != 'none'):
402  # TO DO: check that the requested prescale column is valid
403  self.data += """
404 # force the use of a specific HLT prescale column
405 if 'PrescaleService' in %(dict)s:
406  %(process)sPrescaleService.forceDefault = True
407  %(process)sPrescaleService.lvl1DefaultLabel = '%(prescale)s'
408 """
409 
def fixPrescales
Definition: confdb.py:386
def confdb.instrumentErrorEventType (   self)

Definition at line 424 of file confdb.py.

425  def instrumentErrorEventType(self):
426  if self.config.errortype:
427  # change all HLTTriggerTypeFilter EDFilters to accept only error events (SelectedTriggerType = 0)
428  self._fix_parameter(name = 'SelectedTriggerType', type ='int32', value = '1', replace = '0')
429  self._fix_parameter(name = 'SelectedTriggerType', type ='int32', value = '2', replace = '0')
430  self._fix_parameter(name = 'SelectedTriggerType', type ='int32', value = '3', replace = '0')
431 
def instrumentErrorEventType
Definition: confdb.py:424
def confdb.instrumentOpenMode (   self)

Definition at line 410 of file confdb.py.

References join().

411  def instrumentOpenMode(self):
412  if self.config.open:
413  # find all EDfilters
414  filters = [ match[1] for match in re.findall(r'(process\.)?\b(\w+) = cms.EDFilter', self.data) ]
415  re_sequence = re.compile( r'cms\.(Path|Sequence)\((.*)\)' )
416  # remove existing 'cms.ignore' and '~' modifiers
417  self.data = re_sequence.sub( lambda line: re.sub( r'cms\.ignore *\( *((process\.)?\b(\w+)) *\)', r'\1', line.group(0) ), self.data )
418  self.data = re_sequence.sub( lambda line: re.sub( r'~', '', line.group(0) ), self.data )
419  # wrap all EDfilters with "cms.ignore( ... )", 1000 at a time (python 2.6 complains for too-big regular expressions)
420  for some in splitter(filters, 1000):
421  re_filters = re.compile( r'\b((process\.)?(' + r'|'.join(some) + r'))\b' )
422  self.data = re_sequence.sub( lambda line: re_filters.sub( r'cms.ignore( \1 )', line.group(0) ), self.data )
423 
static std::string join(char **cmd)
Definition: RemoteFile.cc:18
def instrumentOpenMode
Definition: confdb.py:410
def confdb.instrumentTiming (   self)

Definition at line 699 of file confdb.py.

700  def instrumentTiming(self):
701  if self.config.profiling:
702  # instrument the menu for profiling: remove the HLTAnalyzerEndpath, add/override the HLTriggerFirstPath, with hltGetRaw and hltGetConditions
703  text = ''
704 
705  if not 'hltGetRaw' in self.data:
706  # add hltGetRaw
707  text += """
708 %(process)shltGetRaw = cms.EDAnalyzer( "HLTGetRaw",
709  RawDataCollection = cms.InputTag( "rawDataCollector" )
710 )
711 """
712 
713  if not 'hltGetConditions' in self.data:
714  # add hltGetConditions
715  text += """
716 %(process)shltGetConditions = cms.EDAnalyzer( 'EventSetupRecordDataGetter',
717  verbose = cms.untracked.bool( False ),
718  toGet = cms.VPSet( )
719 )
720 """
721 
722  if not 'hltBoolFalse' in self.data:
723  # add hltBoolFalse
724  text += """
725 %(process)shltBoolFalse = cms.EDFilter( "HLTBool",
726  result = cms.bool( False )
727 )
728 """
729 
730  # add the definition of HLTriggerFirstPath
731  # FIXME in a cff, should also update the HLTSchedule
732  text += """
733 %(process)sHLTriggerFirstPath = cms.Path( %(process)shltGetRaw + %(process)shltGetConditions + %(process)shltBoolFalse )
734 """
735  self.data = re.sub(r'.*cms\.(End)?Path.*', text + r'\g<0>', self.data, 1)
736 
737 
738  # instrument the menu with the Service, EDProducer and EndPath needed for timing studies
739  # FIXME in a cff, should also update the HLTSchedule
740  if self.config.timing:
741  self.data += """
742 # instrument the menu with the modules and EndPath needed for timing studies
743 """
744 
745  hasFST = False
746  if 'FastTimerService' in self.data:
747  hasFST = True
748 
749  self.data += '\n# configure the FastTimerService\n'
750  if not hasFST:
751  self.loadCff('HLTrigger.Timer.FastTimerService_cfi')
752  self.data += """%(process)sFastTimerService.useRealTimeClock = False
753 %(process)sFastTimerService.enableTimingPaths = True
754 %(process)sFastTimerService.enableTimingModules = True
755 %(process)sFastTimerService.enableTimingExclusive = True
756 %(process)sFastTimerService.enableTimingSummary = True
757 %(process)sFastTimerService.skipFirstPath = True
758 %(process)sFastTimerService.enableDQM = True
759 %(process)sFastTimerService.enableDQMbyPathActive = True
760 %(process)sFastTimerService.enableDQMbyPathTotal = True
761 %(process)sFastTimerService.enableDQMbyPathOverhead = True
762 %(process)sFastTimerService.enableDQMbyPathDetails = True
763 %(process)sFastTimerService.enableDQMbyPathCounters = True
764 %(process)sFastTimerService.enableDQMbyPathExclusive = True
765 %(process)sFastTimerService.enableDQMbyModule = True
766 %(process)sFastTimerService.enableDQMbyModuleType = True
767 %(process)sFastTimerService.enableDQMSummary = True
768 %(process)sFastTimerService.enableDQMbyLuminosity = True
769 %(process)sFastTimerService.enableDQMbyLumiSection = True
770 %(process)sFastTimerService.enableDQMbyProcesses = False
771 %(process)sFastTimerService.dqmTimeRange = 1000.
772 %(process)sFastTimerService.dqmTimeResolution = 5.
773 %(process)sFastTimerService.dqmPathTimeRange = 100.
774 %(process)sFastTimerService.dqmPathTimeResolution = 0.5
775 %(process)sFastTimerService.dqmModuleTimeRange = 40.
776 %(process)sFastTimerService.dqmModuleTimeResolution = 0.2
777 %(process)sFastTimerService.dqmLuminosityRange = 1e+34
778 %(process)sFastTimerService.dqmLuminosityResolution = 1e+31
779 %(process)sFastTimerService.dqmLumiSectionsRange = 2500
780 %(process)sFastTimerService.dqmPath = 'HLT/TimerService'
781 %(process)sFastTimerService.luminosityProduct = cms.untracked.InputTag( 'hltScalersRawToDigi' )
782 %(process)sFastTimerService.supportedProcesses = cms.untracked.vuint32( )
783 """
784 
785  self.data += """
786 # FastTimerServiceClient
787 %(process)sfastTimerServiceClient = cms.EDAnalyzer( "FastTimerServiceClient",
788  dqmPath = cms.untracked.string( "HLT/TimerService" )
789 )
790 
791 # DQM file saver
792 %(process)sdqmFileSaver = cms.EDAnalyzer( "DQMFileSaver",
793  convention = cms.untracked.string( "Offline" ),
794  workflow = cms.untracked.string( "/HLT/FastTimerService/All" ),
795  dirName = cms.untracked.string( "." ),
796  saveByRun = cms.untracked.int32(1),
797  saveByLumiSection = cms.untracked.int32(-1),
798  saveByEvent = cms.untracked.int32(-1),
799  saveByTime = cms.untracked.int32(-1),
800  saveByMinute = cms.untracked.int32(-1),
801  saveAtJobEnd = cms.untracked.bool(False),
802  forceRunNumber = cms.untracked.int32(-1),
803 )
804 
805 %(process)sTimingOutput = cms.EndPath( %(process)sfastTimerServiceClient + %(process)sdqmFileSaver )
806 """
def instrumentTiming
Definition: confdb.py:699
def confdb.loadAdditionalConditions (   self,
  comment,
  conditions 
)

Definition at line 665 of file confdb.py.

666  def loadAdditionalConditions(self, comment, *conditions):
667  # load additional conditions
668  self.data += """
669 # %s
670 if 'GlobalTag' in %%(dict)s:
671 """ % comment
672  for condition in conditions:
673  self.data += """ %%(process)sGlobalTag.toGet.append(
674  cms.PSet(
675  record = cms.string( '%(record)s' ),
676  tag = cms.string( '%(tag)s' ),
677  label = cms.untracked.string( '%(label)s' ),
678  connect = cms.untracked.string( '%(connect)s' )
679  )
680  )
681 """ % condition
682 
def loadAdditionalConditions
Definition: confdb.py:665
def confdb.loadCff (   self,
  module 
)

Definition at line 683 of file confdb.py.

684  def loadCff(self, module):
685  # load a cfi or cff module
686  if self.config.fragment:
687  self.data += 'from %s import *\n' % module
688  else:
689  self.data += 'process.load( "%s" )\n' % module
690 
def loadCff
Definition: confdb.py:683
def confdb.overrideGlobalTag (   self)

Definition at line 432 of file confdb.py.

433  def overrideGlobalTag(self):
434  # overwrite GlobalTag
435  # the logic is:
436  # - always set the correct connection string and pfnPrefix
437  # - if a GlobalTag is specified on the command line:
438  # - override the global tag
439  # - if the GT is "auto:...", insert the code to read it from Configuration.AlCa.autoCond
440  # - if a GlobalTag is NOT specified on the command line:
441  # - when running on data, do nothing, and keep the global tag in the menu
442  # - when running on mc, take the GT from the configuration.type
443 
444  # override the GlobalTag connection string and pfnPrefix
445  text = """
446 # override the GlobalTag, connection string and pfnPrefix
447 if 'GlobalTag' in %(dict)s:
448 """
449 
450  # when running on MC, override the global tag even if not specified on the command line
451  if not self.config.data and not self.config.globaltag:
452  if self.config.type in globalTag:
453  self.config.globaltag = globalTag[self.config.type]
454  else:
455  self.config.globaltag = globalTag['GRun']
456 
457  # if requested, override the L1 menu from the GlobalTag (using the same connect as the GlobalTag itself)
458  if self.config.l1.override:
459  self.config.l1.record = 'L1GtTriggerMenuRcd'
460  self.config.l1.label = ''
461  self.config.l1.tag = self.config.l1.override
462  if not self.config.l1.connect:
463  self.config.l1.connect = '%(connect)s/CMS_COND_31X_L1T'
464  self.config.l1cond = '%(tag)s,%(record)s,%(connect)s' % self.config.l1.__dict__
465  else:
466  self.config.l1cond = None
467 
468  if self.config.globaltag or self.config.l1cond:
469  text += " from Configuration.AlCa.GlobalTag import GlobalTag as customiseGlobalTag\n"
470  text += " %(process)sGlobalTag = customiseGlobalTag(%(process)sGlobalTag"
471  if self.config.globaltag:
472  text += ", globaltag = %s" % repr(self.config.globaltag)
473  if self.config.l1cond:
474  text += ", conditions = %s" % repr(self.config.l1cond)
475  text += ")\n"
476 
477  text += """ %(process)sGlobalTag.connect = '%(connect)s/CMS_COND_31X_GLOBALTAG'
478  %(process)sGlobalTag.pfnPrefix = cms.untracked.string('%(connect)s/')
479  for pset in process.GlobalTag.toGet.value():
480  pset.connect = pset.connect.value().replace('frontier://FrontierProd/', '%(connect)s/')
481  # fix for multi-run processing
482  %(process)sGlobalTag.RefreshEachRun = cms.untracked.bool( False )
483  %(process)sGlobalTag.ReconnectEachRun = cms.untracked.bool( False )
484 """
485  self.data += text
def overrideGlobalTag
Definition: confdb.py:432
def confdb.overrideL1MenuXml (   self)

Definition at line 486 of file confdb.py.

487  def overrideL1MenuXml(self):
488  # if requested, override the L1 menu from the GlobalTag (Xml file)
489  if self.config.l1Xml.XmlFile:
490  text = """
491 # override the L1 menu from an Xml file
492 %%(process)sl1GtTriggerMenuXml = cms.ESProducer("L1GtTriggerMenuXmlProducer",
493  TriggerMenuLuminosity = cms.string('%(LumiDir)s'),
494  DefXmlFile = cms.string('%(XmlFile)s'),
495  VmeXmlFile = cms.string('')
496 )
497 %%(process)sL1GtTriggerMenuRcdSource = cms.ESSource("EmptyESSource",
498  recordName = cms.string('L1GtTriggerMenuRcd'),
499  iovIsRunNotTime = cms.bool(True),
500  firstValid = cms.vuint32(1)
501 )
502 %%(process)ses_prefer_l1GtParameters = cms.ESPrefer('L1GtTriggerMenuXmlProducer','l1GtTriggerMenuXml')
503 """
504  self.data += text % self.config.l1Xml.__dict__
def overrideL1MenuXml
Definition: confdb.py:486
def confdb.overrideOutput (   self)

Definition at line 584 of file confdb.py.

585  def overrideOutput(self):
586  # override the "online" ShmStreamConsumer output modules with "offline" PoolOutputModule's
587  self.data = re.sub(
588  r'\b(process\.)?hltOutput(\w+) *= *cms\.OutputModule\( *"ShmStreamConsumer" *,',
589  r'%(process)shltOutput\2 = cms.OutputModule( "PoolOutputModule",\n fileName = cms.untracked.string( "output\2.root" ),\n fastCloning = cms.untracked.bool( False ),\n dataset = cms.untracked.PSet(\n filterName = cms.untracked.string( "" ),\n dataTier = cms.untracked.string( "RAW" )\n ),',
590  self.data
591  )
592 
593  if not self.config.fragment and self.config.output == 'full':
594  # add a single "keep *" output
595  self.data += """
596 # add a single "keep *" output
597 %(process)shltOutputFULL = cms.OutputModule( "PoolOutputModule",
598  fileName = cms.untracked.string( "outputFULL.root" ),
599  fastCloning = cms.untracked.bool( False ),
600  dataset = cms.untracked.PSet(
601  dataTier = cms.untracked.string( 'RECO' ),
602  filterName = cms.untracked.string( '' )
603  ),
604  outputCommands = cms.untracked.vstring( 'keep *' )
605 )
606 %(process)sFULLOutput = cms.EndPath( %(process)shltOutputFULL )
607 """
608 
def overrideOutput
Definition: confdb.py:584
def confdb.overrideParameters (   self,
  module,
  parameters 
)

Definition at line 691 of file confdb.py.

692  def overrideParameters(self, module, parameters):
693  # override a module's parameter if the module is present in the configuration
694  self.data += "if '%s' in %%(dict)s:\n" % module
695  for (parameter, value) in parameters:
696  self.data += " %%(process)s%s.%s = %s\n" % (module, parameter, value)
697  self.data += "\n"
698 
def overrideParameters
Definition: confdb.py:691
def confdb.overrideProcessName (   self)

Definition at line 610 of file confdb.py.

611  def overrideProcessName(self):
612  if self.config.name is None:
613  return
614 
615  # override the process name
616  quote = '[\'\"]'
617  self.data = re.compile(r'^(process\s*=\s*cms\.Process\(\s*' + quote + r')\w+(' + quote + r'\s*\).*)$', re.MULTILINE).sub(r'\1%s\2' % self.config.name, self.data, 1)
618 
619  # the following was stolen and adapted from HLTrigger.Configuration.customL1THLT_Options
620  self.data += """
621 # adapt HLT modules to the correct process name
622 if 'hltTrigReport' in %%(dict)s:
623  %%(process)shltTrigReport.HLTriggerResults = cms.InputTag( 'TriggerResults', '', '%(name)s' )
624 
625 if 'hltPreExpressCosmicsOutputSmart' in %%(dict)s:
626  %%(process)shltPreExpressCosmicsOutputSmart.hltResults = cms.InputTag( 'TriggerResults', '', '%(name)s' )
627 
628 if 'hltPreExpressOutputSmart' in %%(dict)s:
629  %%(process)shltPreExpressOutputSmart.hltResults = cms.InputTag( 'TriggerResults', '', '%(name)s' )
630 
631 if 'hltPreDQMForHIOutputSmart' in %%(dict)s:
632  %%(process)shltPreDQMForHIOutputSmart.hltResults = cms.InputTag( 'TriggerResults', '', '%(name)s' )
633 
634 if 'hltPreDQMForPPOutputSmart' in %%(dict)s:
635  %%(process)shltPreDQMForPPOutputSmart.hltResults = cms.InputTag( 'TriggerResults', '', '%(name)s' )
636 
637 if 'hltPreHLTDQMResultsOutputSmart' in %%(dict)s:
638  %%(process)shltPreHLTDQMResultsOutputSmart.hltResults = cms.InputTag( 'TriggerResults', '', '%(name)s' )
639 
640 if 'hltPreHLTDQMOutputSmart' in %%(dict)s:
641  %%(process)shltPreHLTDQMOutputSmart.hltResults = cms.InputTag( 'TriggerResults', '', '%(name)s' )
642 
643 if 'hltPreHLTMONOutputSmart' in %%(dict)s:
644  %%(process)shltPreHLTMONOutputSmart.hltResults = cms.InputTag( 'TriggerResults', '', '%(name)s' )
645 
646 if 'hltDQMHLTScalers' in %%(dict)s:
647  %%(process)shltDQMHLTScalers.triggerResults = cms.InputTag( 'TriggerResults', '', '%(name)s' )
648  %%(process)shltDQMHLTScalers.processname = '%(name)s'
649 
650 if 'hltDQML1SeedLogicScalers' in %%(dict)s:
651  %%(process)shltDQML1SeedLogicScalers.processname = '%(name)s'
652 """ % self.config.__dict__
653 
def overrideProcessName
Definition: confdb.py:610
def confdb.runL1Emulator (   self)

Definition at line 536 of file confdb.py.

537  def runL1Emulator(self):
538  # if requested, run (part of) the L1 emulator
539  if self.config.emulator:
540  # FIXME this fragment used "process" explicitly
541  emulator = {
542  'RawToDigi': '',
543  'CustomL1T': '',
544  'CustomHLT': ''
545  }
546 
547  if self.config.data:
548  emulator['RawToDigi'] = 'RawToDigi_Data_cff'
549  else:
550  emulator['RawToDigi'] = 'RawToDigi_cff'
551 
552  if self.config.emulator == 'gt':
553  emulator['CustomL1T'] = 'customiseL1GtEmulatorFromRaw'
554  emulator['CustomHLT'] = 'switchToSimGtDigis'
555  elif self.config.emulator == 'gct,gt':
556  emulator['CustomL1T'] = 'customiseL1CaloAndGtEmulatorsFromRaw'
557  emulator['CustomHLT'] = 'switchToSimGctGtDigis'
558  elif self.config.emulator == 'gmt,gt':
559  # XXX currently unsupported
560  emulator['CustomL1T'] = 'customiseL1MuonAndGtEmulatorsFromRaw'
561  emulator['CustomHLT'] = 'switchToSimGmtGtDigis'
562  elif self.config.emulator in ('gmt,gct,gt', 'gct,gmt,gt', 'all'):
563  emulator['CustomL1T'] = 'customiseL1EmulatorFromRaw'
564  emulator['CustomHLT'] = 'switchToSimGmtGctGtDigis'
565  else:
566  # unsupported argument, default to running the whole emulator
567  emulator['CustomL1T'] = 'customiseL1EmulatorFromRaw'
568  emulator['CustomHLT'] = 'switchToSimGmtGctGtDigis'
569 
570  self.data += """
571 # customize the L1 emulator to run %(CustomL1T)s with HLT to %(CustomHLT)s
572 process.load( 'Configuration.StandardSequences.%(RawToDigi)s' )
573 process.load( 'Configuration.StandardSequences.SimL1Emulator_cff' )
574 import L1Trigger.Configuration.L1Trigger_custom
575 process = L1Trigger.Configuration.L1Trigger_custom.%(CustomL1T)s( process )
576 process = L1Trigger.Configuration.L1Trigger_custom.customiseResetPrescalesAndMasks( process )
577 
578 # customize the HLT to use the emulated results
579 import HLTrigger.Configuration.customizeHLTforL1Emulator
580 process = HLTrigger.Configuration.customizeHLTforL1Emulator.switchToL1Emulator( process )
581 process = HLTrigger.Configuration.customizeHLTforL1Emulator.%(CustomHLT)s( process )
582 """ % emulator
583 
def runL1Emulator
Definition: confdb.py:536
def confdb.runL1EmulatorGT (   self)

Definition at line 505 of file confdb.py.

506  def runL1EmulatorGT(self):
507  # if requested, run (part of) the L1 emulator, then repack the data into a new RAW collection, to be used by the HLT
508  if not self.config.emulator:
509  return
510 
511  if self.config.emulator != 'gt':
512  # only the GT emulator is currently supported
513  return
514 
515  # run the L1 GT emulator, then repack the data into a new RAW collection, to be used by the HLT
516  text = """
517 # run the L1 GT emulator, then repack the data into a new RAW collection, to be used by the HLT
518 """
519  if self.config.fragment:
520  # FIXME in a cff, should also update the HLTSchedule
521  text += "import Configuration.StandardSequences.SimL1EmulatorRepack_GT_cff\n"
522  else:
523  text += "process.load( 'Configuration.StandardSequences.SimL1EmulatorRepack_GT_cff' )\n"
524 
525  if not 'hltBoolFalse' in self.data:
526  # add hltBoolFalse
527  text += """
528 %(process)shltBoolFalse = cms.EDFilter( "HLTBool",
529  result = cms.bool( False )
530 )
531 """
532  text += "process.L1Emulator = cms.Path( process.SimL1Emulator + process.hltBoolFalse )\n\n"
533 
534  self.data = re.sub(r'.*cms\.(End)?Path.*', text + r'\g<0>', self.data, 1)
535 
def runL1EmulatorGT
Definition: confdb.py:505
def confdb.splitter (   iterator,
  n 
)

Definition at line 11 of file confdb.py.

References list().

Referenced by TotemT1Organization._FromUnitIDToData(), SplittingConfigurableHisto.fill(), HLTLogMonitorFilter.filter(), FWTriggerTableView.saveImageTo(), FWTableView.saveImageTo(), and SplittingConfigurableHisto.SplittingConfigurableHisto().

11 
12 def splitter(iterator, n):
13  i = iterator.__iter__()
14  while True:
15  l = list(islice(i, n))
16  if l:
17  yield l
18  else:
19  break
20 
def splitter
Definition: confdb.py:11
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger list("!*","!HLTx*"if it matches 2 triggers or more) will accept the event if all the matching triggers are FAIL.It will reject the event if any of the triggers are PASS or EXCEPTION(this matches the behavior of"!*"before the partial wildcard feature was incorporated).Triggers which are in the READY state are completely ignored.(READY should never be returned since the trigger paths have been run
def confdb.updateMessageLogger (   self)

Definition at line 654 of file confdb.py.

655  def updateMessageLogger(self):
656  # request summary informations from the MessageLogger
657  self.data += """
658 if 'MessageLogger' in %(dict)s:
659  %(process)sMessageLogger.categories.append('TriggerSummaryProducerAOD')
660  %(process)sMessageLogger.categories.append('L1GtTrigReport')
661  %(process)sMessageLogger.categories.append('HLTrigReport')
662  %(process)sMessageLogger.categories.append('FastReport')
663 """
664 
def updateMessageLogger
Definition: confdb.py:654

Variable Documentation

confdb.all_paths

Definition at line 815 of file confdb.py.

confdb.data

Definition at line 327 of file confdb.py.

confdb.source

Definition at line 1171 of file confdb.py.