CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes | Static Public Attributes | Private Member Functions
dirstructure.Comparison Class Reference
Inheritance diagram for dirstructure.Comparison:
dirstructure.Weighted

Public Member Functions

def __init__ (self, name, mother_dir, h1, h2, stat_test, draw_success=False, do_pngs=False, skip=False)
 
def __repr__ (self)
 
def tcanvas_slow (self, canvas)
 
- Public Member Functions inherited from dirstructure.Weighted
def __init__ (self, name, weight=1)
 

Public Attributes

 do_pngs
 
 draw_success
 
 img_name
 
 mother_dir
 
 name
 
 png_name
 
 rank
 
 status
 
 test_name
 
 test_thr
 
- Public Attributes inherited from dirstructure.Weighted
 name
 
 weight
 

Static Public Attributes

 canvas_xsize
 
 canvas_ysize
 

Private Member Functions

def __get_img_name (self)
 
def __make_image (self, obj1, obj2)
 
def __make_img_dir (self)
 

Detailed Description

Definition at line 361 of file dirstructure.py.

Constructor & Destructor Documentation

◆ __init__()

def dirstructure.Comparison.__init__ (   self,
  name,
  mother_dir,
  h1,
  h2,
  stat_test,
  draw_success = False,
  do_pngs = False,
  skip = False 
)

Definition at line 364 of file dirstructure.py.

364  def __init__(self,name,mother_dir,h1,h2,stat_test,draw_success=False,do_pngs=False, skip=False):
365  self.name=name
366  self.png_name="placeholder.png"
367  self.mother_dir=mother_dir
368  self.img_name=""
369  #self.draw_success=draw_success
370  Weighted.__init__(self,name)
371 
372  stat_test.set_operands(h1,h2)
373  if skip:
374  self.status = SKIPED
375  self.test_name=stat_test.name
376  self.test_name=stat_test.name
377  self.test_thr=stat_test.threshold
378  self.rank = 0
379  else:
380  self.status=stat_test.get_status()
381  self.rank=stat_test.get_rank()
382  self.test_name=stat_test.name
383  self.test_thr=stat_test.threshold
384  self.do_pngs=do_pngs
385  self.draw_success=draw_success or not do_pngs
386  if ((self.status==FAIL or self.status==NULL or self.status == SKIPED or self.draw_success) and self.do_pngs):
387  self.__make_image(h1,h2)
388  #self.__make_image(h1,h2)
389 
def __init__(self, dataset, job_number, job_id, job_name, isDA, isMC, applyBOWS, applyEXTRACOND, extraconditions, runboundary, lumilist, intlumi, maxevents, gt, allFromGT, alignmentDB, alignmentTAG, apeDB, apeTAG, bowDB, bowTAG, vertextype, tracktype, refittertype, ttrhtype, applyruncontrol, ptcut, CMSSW_dir, the_dir)

Member Function Documentation

◆ __get_img_name()

def dirstructure.Comparison.__get_img_name (   self)
private

Definition at line 394 of file dirstructure.py.

References dirstructure.Comparison.img_name, dirstructure.Directory.mother_dir, dirstructure.Comparison.mother_dir, ElectronMVAID.ElectronMVAID.name, AlignableObjectId::entry.name, average.Average.name, counter.Counter.name, histograms.Histograms.name, cond::persistency::TAG::NAME.name, cond::persistency::RUN_INFO::RUN_NUMBER.name, TmModule.name, FWLite.ElectronMVAID.name, cond::persistency::GTEditorData.name, cond::persistency::GLOBAL_TAG::NAME.name, cond::persistency::TAG::TIME_TYPE.name, cond::persistency::RUN_INFO::START_TIME.name, cond::persistency::GLOBAL_TAG::VALIDITY.name, cond::persistency::RUN_INFO::END_TIME.name, core.autovars.NTupleVariable.name, cond::persistency::TAG::OBJECT_TYPE.name, cond::persistency::GLOBAL_TAG::DESCRIPTION.name, cond::persistency::TAG::SYNCHRONIZATION.name, cond::persistency::GLOBAL_TAG::RELEASE.name, DQMRivetClient::NormOption.name, cond::persistency::TAG::END_OF_VALIDITY.name, MEPSet.name, cond::persistency::GLOBAL_TAG::SNAPSHOT_TIME.name, cond::persistency::O2O_RUN::JOB_NAME.name, cond::persistency::TAG::DESCRIPTION.name, cms::dd::NameValuePair< T >.name, cond::persistency::GLOBAL_TAG::INSERTION_TIME.name, cond::persistency::O2O_RUN::START_TIME.name, cond::persistency::TAG::LAST_VALIDATED_TIME.name, cond::persistency::O2O_RUN::END_TIME.name, cond::persistency::TAG::INSERTION_TIME.name, FWTGeoRecoGeometry::Info.name, cond::persistency::O2O_RUN::STATUS_CODE.name, cond::persistency::TAG::MODIFICATION_TIME.name, cond::persistency::O2O_RUN::LOG.name, ParameterSet.name, nanoaod::MergeableCounterTable::SingleColumn< T >.name, cond::persistency::TAG::PROTECTION_CODE.name, OutputMEPSet.name, AlignmentConstraint.name, PixelDCSObject< T >::Item.name, dataset.BaseDataset.name, SummaryTableOutputBranches::NamedBranchPtr.name, cms::dd::ValuePair< T, U >.name, fit::RootMinuitCommand.name, HcalForwardLibWriter::FileHandle.name, personalPlayback.Applet.name, EventStringOutputBranches::NamedBranchPtr.name, Types._Untracked.name, MagCylinder.name, analyzer.Analyzer.name, production_tasks.Task.name, heppy::ParSet.name, DQMRivetClient::LumiOption.name, cond::persistency::GTProxyData.name, TriggerOutputBranches::NamedBranchPtr.name, SingleObjectCondition.name, CharmTagger::MVAVar.name, TableOutputBranches::NamedBranchPtr.name, HeavyIonCSVTagger::MVAVar.name, edm::PathTimingSummary.name, DQMRivetClient::ScaleFactorOption.name, cms::DDAlgoArguments.name, EgHLTOfflineSummaryClient::SumHistBinData.name, RHStopTracer::StopPoint.name, Barrel.name, perftools::EdmEventSize::BranchRecord.name, core.autovars.NTupleObjectType.name, cond::TimeTypeSpecs.name, EcalLogicID.name, LumiOutputBranches::NamedBranchPtr.name, edm::PathSummary.name, lumi::TriggerInfo.name, XMLProcessor::_loaderBaseConfig.name, PixelEndcapLinkMaker::Item.name, MEtoEDM< T >::MEtoEDMObject.name, dirstructure.Weighted.name, FWTableViewManager::TableEntry.name, PixelBarrelLinkMaker::Item.name, ExpressionHisto< T >.name, DQMGenericClient::EfficOption.name, python.rootplot.utilities.Hist2D.name, TreeCrawler.Package.name, Supermodule.name, cond::persistency::GLOBAL_TAG_MAP::GLOBAL_TAG_NAME.name, CaloTrkProcessing::Detector.name, cond::persistency::GLOBAL_TAG_MAP::RECORD.name, options.ConnectionHLTMenu.name, cond::persistency::GLOBAL_TAG_MAP::LABEL.name, MVAVar.name, cms::DDParsingContext::CompositeMaterial.name, cond::persistency::GLOBAL_TAG_MAP::TAG_NAME.name, DisplayManager.DisplayManager.name, cond::Tag_t.name, FWLite.WorkingPoints.name, dqmoffline::l1t::HistDefinition.name, DQMGenericClient::ProfileOption.name, magneticfield::BaseVolumeHandle.name, nanoaod::MergeableCounterTable::VectorColumn< T >.name, FastHFShowerLibrary.name, emtf::Node.name, PhysicsTools::Variable::Value.name, h4DSegm.name, PrintMaterialBudgetInfo.name, DQMGenericClient::NormOption.name, BTagProbabilityToDiscriminator::Discriminator.name, core.TriggerMatchAnalyzer.TriggerMatchAnalyzer.name, DQMGenericClient::CDOption.name, CounterChecker.name, cond::TagInfo_t.name, TrackerSectorStruct.name, MuonGeometrySanityCheckPoint.name, PhysicsTools::Calibration::Variable.name, DQMGenericClient::NoFlowOption.name, EDMtoMEConverter.name, cond::persistency::PAYLOAD::HASH.name, cond::persistency::PAYLOAD::OBJECT_TYPE.name, looper.Looper.name, Mapper::definition< ScannerT >.name, cond::persistency::PAYLOAD::DATA.name, python.rootplot.tree2hists.Plot.name, cond::persistency::PAYLOAD::STREAMER_INFO.name, cond::persistency::PAYLOAD::VERSION.name, cond::persistency::PAYLOAD::INSERTION_TIME.name, PhysicsTools::TreeReader::Value.name, classes.MonitorData.name, PhysicsTools::ProcessRegistry< Base_t, CalibBase_t, Parent_t >.name, HistogramManager.name, classes.OutputData.name, BPHDecayToResResBuilderBase::DZSelect.name, Crystal.name, h2DSegm.name, cond::persistency::IOV::TAG_NAME.name, options.HLTProcessOptions.name, cond::persistency::IOV::SINCE.name, cond::persistency::IOV::PAYLOAD_HASH.name, cond::persistency::IOV::INSERTION_TIME.name, DQMNet::WaitObject.name, core.TriggerBitAnalyzer.TriggerBitAnalyzer.name, python.rootplot.utilities.Hist.name, AlpgenParameterName.name, config.Analyzer.name, geometry.Structure.name, hDigis.name, core.autovars.NTupleSubObject.name, Capsule.name, core.autovars.NTupleObject.name, Ceramic.name, SiStripMonitorDigi.name, PhysicsTools::Variable.name, config.Service.name, BulkSilicon.name, adaptToRunAtMiniAOD.adaptToRunAtMiniAOD.name, APD.name, core.autovars.NTupleCollection.name, CaloSD::Detector.name, BPHRecoBuilder::BPHRecoSource.name, nanoaod::FlatTable::Column.name, BPHRecoBuilder::BPHCompSource.name, StraightTrackAlignment::RPSetPlots.name, cond::persistency::TAG_AUTHORIZATION::TAG_NAME.name, lutNN::LutNeuronLayerFixedPoint< input_I, input_F, inputSize, lut_I, lut_F, neurons, output_I >.name, cond::persistency::TAG_AUTHORIZATION::ACCESS_TYPE.name, cond::persistency::TAG_AUTHORIZATION::CREDENTIAL.name, cond::persistency::TAG_AUTHORIZATION::CREDENTIAL_TYPE.name, InnerLayerVolume.name, cond::payloadInspector::TagReference.name, NanoAODDQM::SelGroupConfig.name, cond::persistency::TAG_LOG::TAG_NAME.name, cond::persistency::TAG_LOG::EVENT_TIME.name, cond::persistency::TAG_LOG::USER_NAME.name, cond::persistency::TAG_LOG::HOST_NAME.name, cond::persistency::TAG_LOG::COMMAND.name, cond::persistency::TAG_LOG::ACTION.name, cond::persistency::TAG_LOG::USER_TEXT.name, lutNN::LutNetworkFixedPointRegression2Outputs< input_I, input_F, inputSize, layer1_lut_I, layer1_lut_F, layer1_neurons, layer1_output_I, layer2_input_I, layer2_lut_I, layer2_lut_F, layer2_neurons, layer3_input_I, layer3_0_inputCnt, layer3_0_lut_I, layer3_0_lut_F, output0_I, output0_F, layer3_1_inputCnt, layer3_1_lut_I, layer3_1_lut_F, output1_I, output1_F >.name, personalPlayback.FrameworkJob.name, Grid.name, trklet::TrackletConfigBuilder::DTCinfo.name, Grille.name, BackPipe.name, plotscripts.SawTeethFunction.name, PatchPanel.name, BackCoolTank.name, DryAirTube.name, python.rootplot.utilities.RootFile.name, crabFunctions.CrabTask.name, MBCoolTube.name, hHits.name, MBManif.name, cscdqm::ParHistoDef.name, hDeltaR.name, hTMaxCell.name, hParam.name, hMuonStat.name, hTOF.name, hTDelay.name, hTimes< hTime >.name, SummaryOutputProducer::GenericSummary.name, python.rootplot.root2matplotlib.replace(), and nano_mu_digi_cff.strip.

Referenced by dirstructure.Comparison.__make_image().

394  def __get_img_name(self):
395  #self.__make_img_dir()
396  #print "MOTHER: ",self.mother_dir
397  self.img_name="%s/%s.png"%(self.mother_dir,self.name)
398  self.img_name=self.img_name.replace("Run summary","")
399  self.img_name=self.img_name.replace("/","_")
400  self.img_name=self.img_name.strip("_")
401  #print "IMAGE NAME: %s " %self.img_name
402  return self.img_name
403 
def replace(string, replacements)

◆ __make_image()

def dirstructure.Comparison.__make_image (   self,
  obj1,
  obj2 
)
private

Definition at line 425 of file dirstructure.py.

References dirstructure.Comparison.__get_img_name(), dirstructure.Comparison.img_name, ElectronMVAID.ElectronMVAID.name, AlignableObjectId::entry.name, average.Average.name, counter.Counter.name, histograms.Histograms.name, cond::persistency::TAG::NAME.name, cond::persistency::RUN_INFO::RUN_NUMBER.name, TmModule.name, FWLite.ElectronMVAID.name, cond::persistency::GTEditorData.name, cond::persistency::GLOBAL_TAG::NAME.name, cond::persistency::TAG::TIME_TYPE.name, cond::persistency::RUN_INFO::START_TIME.name, cond::persistency::GLOBAL_TAG::VALIDITY.name, cond::persistency::RUN_INFO::END_TIME.name, core.autovars.NTupleVariable.name, cond::persistency::TAG::OBJECT_TYPE.name, cond::persistency::GLOBAL_TAG::DESCRIPTION.name, cond::persistency::TAG::SYNCHRONIZATION.name, DQMRivetClient::NormOption.name, cond::persistency::GLOBAL_TAG::RELEASE.name, cond::persistency::TAG::END_OF_VALIDITY.name, MEPSet.name, cond::persistency::GLOBAL_TAG::SNAPSHOT_TIME.name, cond::persistency::O2O_RUN::JOB_NAME.name, cond::persistency::GLOBAL_TAG::INSERTION_TIME.name, cond::persistency::TAG::DESCRIPTION.name, cms::dd::NameValuePair< T >.name, cond::persistency::O2O_RUN::START_TIME.name, cond::persistency::TAG::LAST_VALIDATED_TIME.name, cond::persistency::O2O_RUN::END_TIME.name, cond::persistency::TAG::INSERTION_TIME.name, FWTGeoRecoGeometry::Info.name, cond::persistency::O2O_RUN::STATUS_CODE.name, cond::persistency::TAG::MODIFICATION_TIME.name, cond::persistency::O2O_RUN::LOG.name, ParameterSet.name, nanoaod::MergeableCounterTable::SingleColumn< T >.name, cond::persistency::TAG::PROTECTION_CODE.name, OutputMEPSet.name, AlignmentConstraint.name, PixelDCSObject< T >::Item.name, dataset.BaseDataset.name, SummaryTableOutputBranches::NamedBranchPtr.name, cms::dd::ValuePair< T, U >.name, fit::RootMinuitCommand.name, HcalForwardLibWriter::FileHandle.name, personalPlayback.Applet.name, EventStringOutputBranches::NamedBranchPtr.name, Types._Untracked.name, MagCylinder.name, analyzer.Analyzer.name, production_tasks.Task.name, heppy::ParSet.name, DQMRivetClient::LumiOption.name, cond::persistency::GTProxyData.name, TriggerOutputBranches::NamedBranchPtr.name, CharmTagger::MVAVar.name, SingleObjectCondition.name, TableOutputBranches::NamedBranchPtr.name, HeavyIonCSVTagger::MVAVar.name, edm::PathTimingSummary.name, DQMRivetClient::ScaleFactorOption.name, cms::DDAlgoArguments.name, EgHLTOfflineSummaryClient::SumHistBinData.name, RHStopTracer::StopPoint.name, Barrel.name, perftools::EdmEventSize::BranchRecord.name, cond::TimeTypeSpecs.name, core.autovars.NTupleObjectType.name, EcalLogicID.name, LumiOutputBranches::NamedBranchPtr.name, edm::PathSummary.name, lumi::TriggerInfo.name, PixelEndcapLinkMaker::Item.name, XMLProcessor::_loaderBaseConfig.name, MEtoEDM< T >::MEtoEDMObject.name, dirstructure.Weighted.name, FWTableViewManager::TableEntry.name, PixelBarrelLinkMaker::Item.name, ExpressionHisto< T >.name, DQMGenericClient::EfficOption.name, python.rootplot.utilities.Hist2D.name, TreeCrawler.Package.name, Supermodule.name, cond::persistency::GLOBAL_TAG_MAP::GLOBAL_TAG_NAME.name, CaloTrkProcessing::Detector.name, cond::persistency::GLOBAL_TAG_MAP::RECORD.name, options.ConnectionHLTMenu.name, cond::persistency::GLOBAL_TAG_MAP::LABEL.name, cms::DDParsingContext::CompositeMaterial.name, MVAVar.name, cond::persistency::GLOBAL_TAG_MAP::TAG_NAME.name, DisplayManager.DisplayManager.name, cond::Tag_t.name, FWLite.WorkingPoints.name, DQMGenericClient::ProfileOption.name, dqmoffline::l1t::HistDefinition.name, magneticfield::BaseVolumeHandle.name, nanoaod::MergeableCounterTable::VectorColumn< T >.name, FastHFShowerLibrary.name, emtf::Node.name, PhysicsTools::Variable::Value.name, h4DSegm.name, BTagProbabilityToDiscriminator::Discriminator.name, PrintMaterialBudgetInfo.name, DQMGenericClient::NormOption.name, core.TriggerMatchAnalyzer.TriggerMatchAnalyzer.name, DQMGenericClient::CDOption.name, CounterChecker.name, cond::TagInfo_t.name, TrackerSectorStruct.name, MuonGeometrySanityCheckPoint.name, PhysicsTools::Calibration::Variable.name, cond::persistency::PAYLOAD::HASH.name, DQMGenericClient::NoFlowOption.name, EDMtoMEConverter.name, looper.Looper.name, Mapper::definition< ScannerT >.name, cond::persistency::PAYLOAD::OBJECT_TYPE.name, cond::persistency::PAYLOAD::DATA.name, python.rootplot.tree2hists.Plot.name, cond::persistency::PAYLOAD::STREAMER_INFO.name, cond::persistency::PAYLOAD::VERSION.name, cond::persistency::PAYLOAD::INSERTION_TIME.name, PhysicsTools::TreeReader::Value.name, classes.MonitorData.name, PhysicsTools::ProcessRegistry< Base_t, CalibBase_t, Parent_t >.name, HistogramManager.name, classes.OutputData.name, BPHDecayToResResBuilderBase::DZSelect.name, Crystal.name, h2DSegm.name, options.HLTProcessOptions.name, cond::persistency::IOV::TAG_NAME.name, cond::persistency::IOV::SINCE.name, cond::persistency::IOV::PAYLOAD_HASH.name, cond::persistency::IOV::INSERTION_TIME.name, DQMNet::WaitObject.name, core.TriggerBitAnalyzer.TriggerBitAnalyzer.name, python.rootplot.utilities.Hist.name, AlpgenParameterName.name, config.Analyzer.name, geometry.Structure.name, hDigis.name, core.autovars.NTupleSubObject.name, Capsule.name, core.autovars.NTupleObject.name, Ceramic.name, PhysicsTools::Variable.name, SiStripMonitorDigi.name, config.Service.name, BulkSilicon.name, adaptToRunAtMiniAOD.adaptToRunAtMiniAOD.name, APD.name, core.autovars.NTupleCollection.name, BPHRecoBuilder::BPHRecoSource.name, CaloSD::Detector.name, nanoaod::FlatTable::Column.name, BPHRecoBuilder::BPHCompSource.name, StraightTrackAlignment::RPSetPlots.name, lutNN::LutNeuronLayerFixedPoint< input_I, input_F, inputSize, lut_I, lut_F, neurons, output_I >.name, cond::persistency::TAG_AUTHORIZATION::TAG_NAME.name, cond::persistency::TAG_AUTHORIZATION::ACCESS_TYPE.name, cond::persistency::TAG_AUTHORIZATION::CREDENTIAL.name, cond::persistency::TAG_AUTHORIZATION::CREDENTIAL_TYPE.name, InnerLayerVolume.name, cond::payloadInspector::TagReference.name, NanoAODDQM::SelGroupConfig.name, cond::persistency::TAG_LOG::TAG_NAME.name, cond::persistency::TAG_LOG::EVENT_TIME.name, cond::persistency::TAG_LOG::USER_NAME.name, cond::persistency::TAG_LOG::HOST_NAME.name, cond::persistency::TAG_LOG::COMMAND.name, cond::persistency::TAG_LOG::ACTION.name, cond::persistency::TAG_LOG::USER_TEXT.name, lutNN::LutNetworkFixedPointRegression2Outputs< input_I, input_F, inputSize, layer1_lut_I, layer1_lut_F, layer1_neurons, layer1_output_I, layer2_input_I, layer2_lut_I, layer2_lut_F, layer2_neurons, layer3_input_I, layer3_0_inputCnt, layer3_0_lut_I, layer3_0_lut_F, output0_I, output0_F, layer3_1_inputCnt, layer3_1_lut_I, layer3_1_lut_F, output1_I, output1_F >.name, personalPlayback.FrameworkJob.name, Grid.name, trklet::TrackletConfigBuilder::DTCinfo.name, Grille.name, BackPipe.name, plotscripts.SawTeethFunction.name, PatchPanel.name, BackCoolTank.name, DryAirTube.name, python.rootplot.utilities.RootFile.name, crabFunctions.CrabTask.name, MBCoolTube.name, hHits.name, MBManif.name, cscdqm::ParHistoDef.name, hDeltaR.name, hTMaxCell.name, hParam.name, hMuonStat.name, hTOF.name, hTDelay.name, hTimes< hTime >.name, SummaryOutputProducer::GenericSummary.name, print(), l1t::EMTFTrack.rank, dirstructure.Comparison.rank, runall.testit.status, WorkFlowRunner.WorkFlowRunner.status, EcalRechitChannelStatusGPU::Product.status, SiPixelHitStatusAndCharge.status, HcalChannelQualityGPU::Product.status, lheh5::Particle.status, addOnTests.testit.status, RPCDQMObject::DQMObjectItem.status, TMatacq.status, MCMultiParticleMassFilter.status, SiPixelFedFillerWordEventNumber.status, PythiaFilterMultiMother.status, online::CTPPS_v1.status, EcalPerEvtMatacqAnalyzer.status, MCSmartSingleParticleFilter.status, DJpsiFilter.status, MCSingleParticleYPt.status, MCSingleParticleFilter.status, pixelCPEforDevice::ClusParamsT< N >.status, MCParticlePairFilter.status, PythiaFilter.status, RawToDigiConverter::Record.status, PythiaFilterMultiAncestor.status, l1tVertexFinder::VertexNTupler::GenParticlesBranchData.status, TotemVFATStatus.status, HemisphereAlgo.status, heppy::Megajet.status, EcalMatacqAnalyzer.status, pixelCPEforGPU::ClusParamsT< N >.status, heppy::Hemisphere.status, FastTimerService::ResourcesPerPath.status, HCAL_HLX::CMS_STATUS_DATA.status, dirstructure.Comparison.status, reco::GsfElectron::MvaOutput.status, dirstructure.Comparison.tcanvas_slow(), and dirstructure.Comparison.test_name.

425  def __make_image(self,obj1,obj2):
426  self.img_name=self.__get_img_name()
427  if self.rank==-1:
428  return 0
429 
430  canvas=ROOT.TCanvas(self.name,self.name,Comparison.canvas_xsize,Comparison.canvas_ysize)
431  objs=(obj1,obj2)
432 
433  # Add some specifics for the graphs
434  obj1.SetTitle(self.name)
435 
436  if obj1.GetNbinsY()!=0 and not "2" in obj1.ClassName() :
437  obj1 .SetLineWidth(2)
438  obj2 .SetLineWidth(2)
439 
440  obj1.SetMarkerStyle(8)
441  obj1.SetMarkerSize(.8)
442 
443  obj2.SetMarkerStyle(8)
444  obj2.SetMarkerSize(.8)
445 
446  obj1.SetMarkerColor(ROOT.kBlue)
447  obj1.SetLineColor(ROOT.kBlue)
448 
449  obj2.SetMarkerColor(ROOT.kRed)
450  obj2.SetLineColor(ROOT.kRed)
451 
452  obj1.Draw("EP")
453  #Statsbox
454  obj2.Draw("HistSames")
455  #ROOT.gPad.Update()
456  #if 'stats' in map(lambda o: o.GetName(),list(ROOT.gPad.GetListOfPrimitives())):
457  #st = gPad.GetPrimitive("stats")
458  #st.SetY1NDC(0.575)
459  #st.SetY2NDC(0.735)
460  #st.SetLineColor(ROOT.kRed)
461  #st.SetTextColor(ROOT.kRed)
462  #print st
463  else:
464  obj1.Draw("Colz")
465  ROOT.gPad.Update()
466  #if 'stats' in map(lambda o: o.GetName(),list(ROOT.gPad.GetListOfPrimitives())):
467  #st = ROOT.gPad.GetPrimitive("stats")
468  #st.SetY1NDC(0.575)
469  #st.SetY2NDC(0.735)
470  #st.SetLineColor(ROOT.kRed)
471  #st.SetTextColor(ROOT.kRed)
472  #print st
473  obj2.Draw("ColSame")
474 
475  # Put together the TLatex for the stat test if possible
476  color=ROOT.kGreen+2 # which is green, as everybody knows
477  if self.status==FAIL:
478  print("This comparison failed %f" %self.rank)
479  color=ROOT.kRed
480  elif self.status==NULL:
481  color=ROOT.kYellow
482  elif self.status==SKIPED:
483  color=ROOT.kBlue #check if kBlue exists ;)
484 
485  lat_text="#scale[.7]{#color[%s]{%s: %2.2f}}" %(color,self.test_name,self.rank)
486  lat=ROOT.TLatex(.1,.91,lat_text)
487  lat.SetNDC()
488  lat.Draw()
489 
490  # Put also the stats together!
491  n1=obj1.GetEntries()
492  if n1> 100000:
493  n1="%e"%n1
494  else:
495  n1="%s"%n1
496  n2=obj2.GetEntries()
497  if n2> 100000:
498  n2="%e"%n2
499  else:
500  n2="%s"%n2
501 
502  lat_text1="#scale[.7]{#color[%s]{Entries: %s}}" %(obj1.GetLineColor(),n1)
503  lat1=ROOT.TLatex(.3,.91,lat_text1)
504  lat1.SetNDC()
505  lat1.Draw()
506 
507 
508  lat_text2="#scale[.7]{#color[%s]{Entries: %s}}" %(obj2.GetLineColor(),n2)
509  lat2=ROOT.TLatex(.6,.91,lat_text2)
510  lat2.SetNDC()
511  lat2.Draw()
512 
513 
514  self.tcanvas_slow(canvas)
515 
void print(TMatrixD &m, const char *label=nullptr, bool mathematicaFormat=false)
Definition: Utilities.cc:47

◆ __make_img_dir()

def dirstructure.Comparison.__make_img_dir (   self)
private

Definition at line 390 of file dirstructure.py.

References dirstructure.Directory.mother_dir, and dirstructure.Comparison.mother_dir.

390  def __make_img_dir(self):
391  if not exists(self.mother_dir):
392  makedirs(self.mother_dir)
393 

◆ __repr__()

def dirstructure.Comparison.__repr__ (   self)

Definition at line 516 of file dirstructure.py.

References dirstructure.Comparison.img_name, ElectronMVAID.ElectronMVAID.name, AlignableObjectId::entry.name, average.Average.name, counter.Counter.name, histograms.Histograms.name, cond::persistency::RUN_INFO::RUN_NUMBER.name, TmModule.name, cond::persistency::TAG::NAME.name, cond::persistency::GTEditorData.name, cond::persistency::GLOBAL_TAG::NAME.name, FWLite.ElectronMVAID.name, cond::persistency::TAG::TIME_TYPE.name, cond::persistency::RUN_INFO::START_TIME.name, cond::persistency::GLOBAL_TAG::VALIDITY.name, cond::persistency::TAG::OBJECT_TYPE.name, cond::persistency::RUN_INFO::END_TIME.name, core.autovars.NTupleVariable.name, cond::persistency::GLOBAL_TAG::DESCRIPTION.name, cond::persistency::TAG::SYNCHRONIZATION.name, cond::persistency::GLOBAL_TAG::RELEASE.name, DQMRivetClient::NormOption.name, cond::persistency::TAG::END_OF_VALIDITY.name, MEPSet.name, cond::persistency::GLOBAL_TAG::SNAPSHOT_TIME.name, cond::persistency::O2O_RUN::JOB_NAME.name, cond::persistency::TAG::DESCRIPTION.name, cms::dd::NameValuePair< T >.name, cond::persistency::GLOBAL_TAG::INSERTION_TIME.name, cond::persistency::O2O_RUN::START_TIME.name, cond::persistency::TAG::LAST_VALIDATED_TIME.name, cond::persistency::O2O_RUN::END_TIME.name, cond::persistency::TAG::INSERTION_TIME.name, FWTGeoRecoGeometry::Info.name, cond::persistency::O2O_RUN::STATUS_CODE.name, cond::persistency::TAG::MODIFICATION_TIME.name, cond::persistency::O2O_RUN::LOG.name, ParameterSet.name, nanoaod::MergeableCounterTable::SingleColumn< T >.name, cond::persistency::TAG::PROTECTION_CODE.name, OutputMEPSet.name, PixelDCSObject< T >::Item.name, dataset.BaseDataset.name, SummaryTableOutputBranches::NamedBranchPtr.name, AlignmentConstraint.name, cms::dd::ValuePair< T, U >.name, fit::RootMinuitCommand.name, HcalForwardLibWriter::FileHandle.name, personalPlayback.Applet.name, EventStringOutputBranches::NamedBranchPtr.name, Types._Untracked.name, MagCylinder.name, analyzer.Analyzer.name, production_tasks.Task.name, heppy::ParSet.name, DQMRivetClient::LumiOption.name, cond::persistency::GTProxyData.name, TriggerOutputBranches::NamedBranchPtr.name, SingleObjectCondition.name, CharmTagger::MVAVar.name, TableOutputBranches::NamedBranchPtr.name, HeavyIonCSVTagger::MVAVar.name, edm::PathTimingSummary.name, DQMRivetClient::ScaleFactorOption.name, cms::DDAlgoArguments.name, EgHLTOfflineSummaryClient::SumHistBinData.name, RHStopTracer::StopPoint.name, Barrel.name, perftools::EdmEventSize::BranchRecord.name, cond::TimeTypeSpecs.name, core.autovars.NTupleObjectType.name, EcalLogicID.name, LumiOutputBranches::NamedBranchPtr.name, edm::PathSummary.name, lumi::TriggerInfo.name, PixelEndcapLinkMaker::Item.name, XMLProcessor::_loaderBaseConfig.name, MEtoEDM< T >::MEtoEDMObject.name, dirstructure.Weighted.name, FWTableViewManager::TableEntry.name, PixelBarrelLinkMaker::Item.name, ExpressionHisto< T >.name, DQMGenericClient::EfficOption.name, python.rootplot.utilities.Hist2D.name, TreeCrawler.Package.name, Supermodule.name, CaloTrkProcessing::Detector.name, cond::persistency::GLOBAL_TAG_MAP::GLOBAL_TAG_NAME.name, cond::persistency::GLOBAL_TAG_MAP::RECORD.name, options.ConnectionHLTMenu.name, cms::DDParsingContext::CompositeMaterial.name, MVAVar.name, cond::persistency::GLOBAL_TAG_MAP::LABEL.name, cond::persistency::GLOBAL_TAG_MAP::TAG_NAME.name, DisplayManager.DisplayManager.name, cond::Tag_t.name, FWLite.WorkingPoints.name, dqmoffline::l1t::HistDefinition.name, DQMGenericClient::ProfileOption.name, magneticfield::BaseVolumeHandle.name, nanoaod::MergeableCounterTable::VectorColumn< T >.name, FastHFShowerLibrary.name, emtf::Node.name, PhysicsTools::Variable::Value.name, h4DSegm.name, BTagProbabilityToDiscriminator::Discriminator.name, DQMGenericClient::NormOption.name, PrintMaterialBudgetInfo.name, core.TriggerMatchAnalyzer.TriggerMatchAnalyzer.name, DQMGenericClient::CDOption.name, CounterChecker.name, cond::TagInfo_t.name, TrackerSectorStruct.name, MuonGeometrySanityCheckPoint.name, PhysicsTools::Calibration::Variable.name, cond::persistency::PAYLOAD::HASH.name, DQMGenericClient::NoFlowOption.name, EDMtoMEConverter.name, looper.Looper.name, Mapper::definition< ScannerT >.name, cond::persistency::PAYLOAD::OBJECT_TYPE.name, cond::persistency::PAYLOAD::DATA.name, python.rootplot.tree2hists.Plot.name, cond::persistency::PAYLOAD::STREAMER_INFO.name, cond::persistency::PAYLOAD::VERSION.name, cond::persistency::PAYLOAD::INSERTION_TIME.name, PhysicsTools::TreeReader::Value.name, classes.MonitorData.name, PhysicsTools::ProcessRegistry< Base_t, CalibBase_t, Parent_t >.name, HistogramManager.name, classes.OutputData.name, BPHDecayToResResBuilderBase::DZSelect.name, Crystal.name, h2DSegm.name, options.HLTProcessOptions.name, cond::persistency::IOV::TAG_NAME.name, cond::persistency::IOV::SINCE.name, cond::persistency::IOV::PAYLOAD_HASH.name, cond::persistency::IOV::INSERTION_TIME.name, DQMNet::WaitObject.name, core.TriggerBitAnalyzer.TriggerBitAnalyzer.name, python.rootplot.utilities.Hist.name, AlpgenParameterName.name, config.Analyzer.name, geometry.Structure.name, hDigis.name, core.autovars.NTupleSubObject.name, Capsule.name, core.autovars.NTupleObject.name, Ceramic.name, PhysicsTools::Variable.name, SiStripMonitorDigi.name, config.Service.name, BulkSilicon.name, adaptToRunAtMiniAOD.adaptToRunAtMiniAOD.name, APD.name, core.autovars.NTupleCollection.name, BPHRecoBuilder::BPHRecoSource.name, CaloSD::Detector.name, nanoaod::FlatTable::Column.name, BPHRecoBuilder::BPHCompSource.name, StraightTrackAlignment::RPSetPlots.name, lutNN::LutNeuronLayerFixedPoint< input_I, input_F, inputSize, lut_I, lut_F, neurons, output_I >.name, cond::persistency::TAG_AUTHORIZATION::TAG_NAME.name, cond::persistency::TAG_AUTHORIZATION::ACCESS_TYPE.name, cond::persistency::TAG_AUTHORIZATION::CREDENTIAL.name, cond::persistency::TAG_AUTHORIZATION::CREDENTIAL_TYPE.name, InnerLayerVolume.name, cond::payloadInspector::TagReference.name, NanoAODDQM::SelGroupConfig.name, cond::persistency::TAG_LOG::TAG_NAME.name, cond::persistency::TAG_LOG::EVENT_TIME.name, cond::persistency::TAG_LOG::USER_NAME.name, cond::persistency::TAG_LOG::HOST_NAME.name, cond::persistency::TAG_LOG::COMMAND.name, cond::persistency::TAG_LOG::ACTION.name, cond::persistency::TAG_LOG::USER_TEXT.name, lutNN::LutNetworkFixedPointRegression2Outputs< input_I, input_F, inputSize, layer1_lut_I, layer1_lut_F, layer1_neurons, layer1_output_I, layer2_input_I, layer2_lut_I, layer2_lut_F, layer2_neurons, layer3_input_I, layer3_0_inputCnt, layer3_0_lut_I, layer3_0_lut_F, output0_I, output0_F, layer3_1_inputCnt, layer3_1_lut_I, layer3_1_lut_F, output1_I, output1_F >.name, personalPlayback.FrameworkJob.name, Grid.name, trklet::TrackletConfigBuilder::DTCinfo.name, Grille.name, BackPipe.name, plotscripts.SawTeethFunction.name, PatchPanel.name, BackCoolTank.name, DryAirTube.name, python.rootplot.utilities.RootFile.name, crabFunctions.CrabTask.name, MBCoolTube.name, hHits.name, MBManif.name, cscdqm::ParHistoDef.name, hDeltaR.name, hTMaxCell.name, hParam.name, hMuonStat.name, hTOF.name, hTDelay.name, hTimes< hTime >.name, SummaryOutputProducer::GenericSummary.name, l1t::EMTFTrack.rank, dirstructure.Comparison.rank, runall.testit.status, WorkFlowRunner.WorkFlowRunner.status, SiPixelHitStatusAndCharge.status, EcalRechitChannelStatusGPU::Product.status, HcalChannelQualityGPU::Product.status, lheh5::Particle.status, addOnTests.testit.status, RPCDQMObject::DQMObjectItem.status, TMatacq.status, MCMultiParticleMassFilter.status, SiPixelFedFillerWordEventNumber.status, PythiaFilterMultiMother.status, online::CTPPS_v1.status, EcalPerEvtMatacqAnalyzer.status, MCSmartSingleParticleFilter.status, DJpsiFilter.status, MCSingleParticleYPt.status, MCSingleParticleFilter.status, pixelCPEforDevice::ClusParamsT< N >.status, MCParticlePairFilter.status, PythiaFilter.status, RawToDigiConverter::Record.status, PythiaFilterMultiAncestor.status, l1tVertexFinder::VertexNTupler::GenParticlesBranchData.status, TotemVFATStatus.status, HemisphereAlgo.status, heppy::Megajet.status, EcalMatacqAnalyzer.status, pixelCPEforGPU::ClusParamsT< N >.status, heppy::Hemisphere.status, FastTimerService::ResourcesPerPath.status, HCAL_HLX::CMS_STATUS_DATA.status, dirstructure.Comparison.status, reco::GsfElectron::MvaOutput.status, and dirstructure.Comparison.test_name.

516  def __repr__(self):
517  return "%s , (%s=%s). IMG=%s. status=%s" %(self.name,self.test_name,self.rank,self.img_name,self.status)
518 
519 #-------------------------------------------------------------------------------
520 

◆ tcanvas_slow()

def dirstructure.Comparison.tcanvas_slow (   self,
  canvas 
)

Definition at line 404 of file dirstructure.py.

References dirstructure.Comparison.img_name, and FastTimerService_cff.range.

Referenced by dirstructure.Comparison.__make_image().

404  def tcanvas_slow(self,canvas):
405  #print "About to print %s" %self.img_name
406  #print_multi_threaded(canvas,self.img_name)
407  #print "-->Printed"
408 
409  p = Process(target=print_multi_threaded, args=(canvas,self.img_name))
410  p.start()
411  tcanvas_print_processes.append(p)
412  n_proc=len(tcanvas_print_processes)
413  if n_proc>3:
414  p_to_remove=[]
415  for iprocess in range(0,n_proc):
416  p=tcanvas_print_processes[iprocess]
417  p.join()
418  p_to_remove.append(iprocess)
419 
420  adjustment=0
421  for iprocess in p_to_remove:
422  tcanvas_print_processes.pop(iprocess-adjustment)
423  adjustment+=1
424 

Member Data Documentation

◆ canvas_xsize

dirstructure.Comparison.canvas_xsize
static

Definition at line 362 of file dirstructure.py.

◆ canvas_ysize

dirstructure.Comparison.canvas_ysize
static

Definition at line 363 of file dirstructure.py.

◆ do_pngs

dirstructure.Comparison.do_pngs

Definition at line 384 of file dirstructure.py.

Referenced by dqm_interfaces.DirWalkerDB.run().

◆ draw_success

dirstructure.Comparison.draw_success

Definition at line 385 of file dirstructure.py.

◆ img_name

◆ mother_dir

dirstructure.Comparison.mother_dir

◆ name

◆ png_name

dirstructure.Comparison.png_name

Definition at line 366 of file dirstructure.py.

◆ rank

◆ status

dirstructure.Comparison.status

◆ test_name

dirstructure.Comparison.test_name

◆ test_thr

dirstructure.Comparison.test_thr

Definition at line 377 of file dirstructure.py.