CMS 3D CMS Logo

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

Functions

def MakePair
 
def ReadNewList
 

Variables

tuple defaultDict = MakePair(defaultList)
 
 defaultList = hcalLaserEventFilter.BadRunEventNumbers
 
tuple keys = defaultDict.keys()
 
tuple lines = open(i,'r')
 
tuple newBadDict = ReadNewList(newlines)
 
tuple newkeys = newBadDict.keys()
 
list newlines = []
 
dictionary notInNew = {}
 
dictionary notInOld = {}
 
tuple out = open("badEvents.py",'w')
 
tuple thistime = time.time()
 

Function Documentation

def GenerateHcalLaserBadRunList.MakePair (   startlist)

Definition at line 15 of file GenerateHcalLaserBadRunList.py.

Referenced by ReadNewList().

15 
16 def MakePair(startlist):
17  dict={}
18  for i in range(0,len(startlist),2):
19  key1=startlist[i]
20  key2=startlist[i+1]
21  runevent=(key1,key2)
22  dict[runevent]="%s,%s,"%(key1,key2)
23  return dict
def GenerateHcalLaserBadRunList.ReadNewList (   newlist)
Read a new list of bad runs from an input file, and
    creates a new list of output keys for the bad run/events.

Definition at line 24 of file GenerateHcalLaserBadRunList.py.

References MakePair().

24 
25 def ReadNewList(newlist):
26  ''' Read a new list of bad runs from an input file, and
27  creates a new list of output keys for the bad run/events.
28  '''
29  outlist=[]
30  for i in newlist:
31  temp=string.strip(i)
32  # Input is comma-separated
33  if temp.find(",")>-1:
34  temp=string.split(temp,",")
35  # Input is space-separated
36  else:
37  temp=string.split(temp)
38 
39  # Case 1: new input presented as "run lumi event" list
40  if len(temp)==3:
41  try:
42  run=string.atoi(temp[0])
43  evt=string.atoi(temp[2])
44  except:
45  print "Could not parse line '%s'"%i
46  # Case 2: new input presented as "run event" list
47  elif len(temp)==2:
48  try:
49  run=string.atoi(temp[0])
50  evt=string.atoi(temp[1])
51  except:
52  print "Could not parse line '%s'"%i
53  else:
54  print "Cannot parse line! ('%s')"%i
55  continue
56  outlist.append(run)
57  outlist.append(evt)
58  outDict=MakePair(outlist)
59  return outDict
60 

Variable Documentation

tuple GenerateHcalLaserBadRunList.defaultDict = MakePair(defaultList)

Definition at line 65 of file GenerateHcalLaserBadRunList.py.

GenerateHcalLaserBadRunList.defaultList = hcalLaserEventFilter.BadRunEventNumbers

Definition at line 64 of file GenerateHcalLaserBadRunList.py.

tuple GenerateHcalLaserBadRunList.keys = defaultDict.keys()

Definition at line 66 of file GenerateHcalLaserBadRunList.py.

tuple GenerateHcalLaserBadRunList.lines = open(i,'r')

Definition at line 79 of file GenerateHcalLaserBadRunList.py.

tuple GenerateHcalLaserBadRunList.newBadDict = ReadNewList(newlines)

Definition at line 82 of file GenerateHcalLaserBadRunList.py.

tuple GenerateHcalLaserBadRunList.newkeys = newBadDict.keys()

Definition at line 86 of file GenerateHcalLaserBadRunList.py.

list GenerateHcalLaserBadRunList.newlines = []

Definition at line 74 of file GenerateHcalLaserBadRunList.py.

dictionary GenerateHcalLaserBadRunList.notInNew = {}

Definition at line 89 of file GenerateHcalLaserBadRunList.py.

dictionary GenerateHcalLaserBadRunList.notInOld = {}

Definition at line 88 of file GenerateHcalLaserBadRunList.py.

tuple GenerateHcalLaserBadRunList.out = open("badEvents.py",'w')

Definition at line 91 of file GenerateHcalLaserBadRunList.py.

Referenced by ThreeThresholdAlgorithm.addFed(), MuonGeometrySVGTemplate.analyze(), cond::auth::Cipher.b64encrypt(), RawToText.beginJob(), sistrip::SpyIdentifyRunsModule.beginJob(), SiStripShotFilter.beginJob(), LHEWriter.beginRun(), HepMCEventWriter.beginRun(), ParticleDecayDrawer.decay(), cond::auth::Cipher.decrypt(), MedianCommonModeCalculator.doIt(), TT6CommonModeCalculator.doIt(), edm::ProcessDesc.dump(), EcalClusterCrackCorrXMLTranslator.dumpXML(), sistrip::SpyExtractRunModule.endJob(), testChannel.endJob(), ExternalLHEAsciiDumper.endRun(), MultiFileBlob.expand(), dqm::DQMFileSaverOnline.fillOrigin(), BadGlobalMuonTagger.filter(), ElectronIdMVAProducer.filter(), VBFGenJetFilter.filterGenJets(), MultiFileBlob.finalized(), DivisiveVertexFinder.findVertexesAlt(), GctDigiToPsbText.GctDigiToPsbText(), l1t::MicroGMTLUT.initialize(), fastmath.invSqrt(), SurveyAlignment.iterate(), main(), HLTTauDQMPlotter.match(), MaterialBudgetTxt.MaterialBudgetTxt(), MBLTProducer(), PrintVIDToString< reco::Muon >.operator()(), operator<<(), pat.operator<<(), triggerExpression.operator<<(), GenParticlesHelper.operator<<(), reco.operator<<(), TFWLiteSelector< TrackAnalysisAlgorithm >.preProcessing(), reco.print(), SiPixelFedCablingTree.print(), reco::GenericJet.print(), sipixelobjects::PixelFEDCabling.print(), reco::BasicJet.print(), HGCSample.print(), reco::PFClusterJet.print(), sipixelobjects::PixelFEDLink.print(), HGCDataFrame< HGCHEDetId, HGCSample >.print(), reco::TrackJet.print(), sipixelobjects::PixelROC.print(), reco::GenJet.print(), magfieldparam::rz_harm_poly.Print(), reco::JPTJet.print(), reco::CaloJet.print(), reco::PFJet.print(), magfieldparam::HarmBasis3DCyl.PrintBphiB(), magfieldparam::BFit3D.PrintBphiPoly(), magfieldparam::HarmBasis3DCyl.PrintBrB(), magfieldparam::BFit3D.PrintBrPoly(), magfieldparam::HarmBasis3DCyl.PrintBzB(), magfieldparam::BFit3D.PrintBzPoly(), sipixelobjects::PixelFEDLink.printForMap(), reco::CaloCluster.printHitAndFraction(), magfieldparam::rz_harm_poly.PrintLM(), magfieldparam::BFit3D.PrintPoly(), magfieldparam::HarmBasis3DCyl.PrintPtB(), magfieldparam::BFit3D.PrintPtnPoly(), EcalFenixEtTot.process(), MaskedMeasurementTrackerEventProducer.produce(), CalibratedPhotonProducerRun2T< T >.produce(), CandViewRefMerger.produce(), pat::PATTauSlimmer.produce(), PFClusterTimeSelector.produce(), CalibratedElectronProducerRun2T< T >.produce(), pat::PackedPFCandidateRefMixer.produce(), ElectronIDExternalProducer< algo >.produce(), PFRecHitProducer.produce(), PFTauViewRefMerger.produce(), ElectronPATIdMVAProducer.produce(), pat::PATMuonSlimmer.produce(), pat::PATGenJetSlimmer.produce(), MuonSelectionTypeValueMapProducer.produce(), DeltaBetaWeights.produce(), TriggerObjectFilterByCollection.produce(), CosmicsMuonIdProducer.produce(), MuPFIsoEmbedder.produce(), Timer.produce(), L1CaloHcalScale.rank(), L1CaloEcalScale.rank(), L1CaloEtScale.rank(), PdgEntryReplacer.replace(), G4RegionReporter.ReportRegions(), PFEGammaToCandidateRemapper.run(), EcalGeomPhiSymHelper.setup(), SimHitPrinter.SimHitPrinter(), testSerialization(), HCAL_HLX::TimeStamp.TimeStampYYYYMMDD(), TkSimHitPrinter.TkSimHitPrinter(), ErrorFrameTransformer.transform46(), FileBlob.write(), sistrip::EnsembleCalibrationLA.write_calibrations(), sistrip::EnsembleCalibrationLA.write_ensembles_text(), pos::PixelTrimCommon.writeASCII(), pos::PixelTrimCommon.writeBinary(), pos::PixelConfigList.writefile(), EcalTPGCrystalStatusXMLTranslator.writeXML(), HcalConstantsXMLWriter.writeXML(), ESGainXMLTranslator.writeXML(), EcalTimeBiasCorrectionsXMLTranslator.writeXML(), EcalAlignmentXMLTranslator.writeXML(), EcalTPGStripStatusXMLTranslator.writeXML(), EcalClusterCrackCorrXMLTranslator.writeXML(), EcalChannelStatusXMLTranslator.writeXML(), EcalTPGLinearizationConstXMLTranslator.writeXML(), EcalPulseSymmCovariancesXMLTranslator.writeXML(), EcalClusterLocalContCorrXMLTranslator.writeXML(), EcalClusterEnergyCorrectionObjectSpecificXMLTranslator.writeXML(), EcalADCToGeVXMLTranslator.writeXML(), EcalGainRatiosXMLTranslator.writeXML(), EcalTimeOffsetXMLTranslator.writeXML(), EcalClusterEnergyCorrectionXMLTranslator.writeXML(), and EcalWeightGroupXMLTranslator.writeXML().

tuple GenerateHcalLaserBadRunList.thistime = time.time()

Definition at line 93 of file GenerateHcalLaserBadRunList.py.