Public Member Functions | |
def | __init__ (self, name, plots, kwargs) |
def | append (self, plot) |
def | clear (self) |
def | create (self, tdirectoryNEvents, requireAllHistograms=False) |
def | draw (self, legendLabels, prefix=None, separate=False, saveFormat=".pdf", ratio=True, directory="") |
def | getName (self) |
def | getPlot (self, name) |
def | getPlots (self) |
def | onlyForPileup (self) |
def | remove (self, name) |
def | setProperties (self, kwargs) |
Private Member Functions | |
def | _createLegend (self, plot, legendLabels, lx1, ly1, lx2, ly2, textSize=0.016, denomUncertainty=True) |
def | _drawSeparate (self, legendLabels, prefix, saveFormat, ratio, directory) |
def | _modifyPadForRatio (self, pad) |
def | _save (self, canvas, saveFormat, prefix=None, postfix=None, single=False, directory="") |
Private Attributes | |
_name | |
_plots | |
_ratioFactor | |
Group of plots, results a TCanvas
Definition at line 2229 of file plotting.py.
def plotting.PlotGroup.__init__ | ( | self, | |
name, | |||
plots, | |||
kwargs | |||
) |
Constructor. Arguments: name -- String for name of the TCanvas, used also as the basename of the picture files plots -- List of Plot objects Keyword arguments: ncols -- Number of columns (default 2) legendDx -- Float for moving TLegend in x direction (default None) legendDy -- Float for moving TLegend in y direction (default None) legendDw -- Float for changing TLegend width (default None) legendDh -- Float for changing TLegend height (default None) legend -- Bool for disabling legend (default True for legend being enabled) overrideLegendLabels -- List of strings for legend labels, if given, these are used instead of the ones coming from Plotter (default None) onlyForPileup -- Plots this group only for pileup samples
Definition at line 2231 of file plotting.py.
|
private |
Definition at line 2459 of file plotting.py.
References GeometryComparisonPlotter._legend.
Referenced by plotting.PlotGroup._drawSeparate(), and plotting.PlotGroup.draw().
|
private |
Internal method to do the drawing to separate files per Plot instead of a file per PlotGroup
Definition at line 2393 of file plotting.py.
References plotting._createCanvas(), plotting.PlotGroup._createLegend(), plotting.PlotGroup._modifyPadForRatio(), ModulesProxy._ModuleProxy._name, FP420HitsObject._name, TrackerHitsObject._name, PGeometricDet::Item._name, TrackingRecHitAlgorithm._name, Logger._name, hcaldqm::DQModule._name, citk::IsolationConeDefinitionBase._name, condhdf5tohdf5.H5DataProduct._name, WValidation._name, DrellYanValidation._name, hcaldqm::flag::Flag._name, hcaldqm::quantity::Quantity._name, HistoParams< T >._name, condhdf5tohdf5.H5Tag._name, CutApplicatorBase._name, condhdf5tohdf5.H5GlobalTag._name, HistoParams< TH2F >._name, HistoParams< TProfile2D >._name, conddb2hdf5.DBGlobalTag._name, SequenceTypes.SequencePlaceholder._name, plotting.Subtract._name, plotting.Transform._name, plotting.FakeDuplicate._name, plotting.CutEfficiency._name, plotting.AggregateBins._name, plotting.AggregateHistos._name, plotting.ROC._name, SequenceTypes._TaskBasePlaceholder._name, plotting.Plot._name, plotting.PlotGroup._name, plotting.PlotGroup._plots, plotting.PlotGroup._ratioFactor, plotting.PlotGroup._save(), and createfilelist.int.
Referenced by plotting.PlotGroup.draw().
|
private |
Internal method to set divide a pad to two for ratio plots
Definition at line 2455 of file plotting.py.
References plotting.PlotGroup._ratioFactor.
Referenced by plotting.PlotGroup._drawSeparate(), and plotting.PlotGroup.draw().
|
private |
Definition at line 2475 of file plotting.py.
References ModulesProxy._ModuleProxy._name, FP420HitsObject._name, TrackerHitsObject._name, PGeometricDet::Item._name, TrackingRecHitAlgorithm._name, Logger._name, hcaldqm::DQModule._name, citk::IsolationConeDefinitionBase._name, condhdf5tohdf5.H5DataProduct._name, WValidation._name, DrellYanValidation._name, hcaldqm::flag::Flag._name, hcaldqm::quantity::Quantity._name, HistoParams< T >._name, condhdf5tohdf5.H5Tag._name, CutApplicatorBase._name, condhdf5tohdf5.H5GlobalTag._name, HistoParams< TH2F >._name, HistoParams< TProfile2D >._name, conddb2hdf5.DBGlobalTag._name, SequenceTypes.SequencePlaceholder._name, plotting.Subtract._name, plotting.Transform._name, plotting.FakeDuplicate._name, plotting.CutEfficiency._name, plotting.AggregateBins._name, plotting.AggregateHistos._name, plotting.ROC._name, SequenceTypes._TaskBasePlaceholder._name, plotting.Plot._name, and plotting.PlotGroup._name.
Referenced by plotting.PlotGroup._drawSeparate(), and plotting.PlotGroup.draw().
def plotting.PlotGroup.append | ( | self, | |
plot | |||
) |
Definition at line 2292 of file plotting.py.
References plotting.PlotGroup._plots.
Referenced by diclist.diclist.add().
def plotting.PlotGroup.clear | ( | self | ) |
def plotting.PlotGroup.create | ( | self, | |
tdirectoryNEvents, | |||
requireAllHistograms = False |
|||
) |
Create histograms from a list of TDirectories. Arguments: tdirectoryNEvents -- List of (TDirectory, nevents) pairs requireAllHistograms -- If True, a plot is produced if histograms from all files are present (default: False)
Definition at line 2305 of file plotting.py.
References plotting.PlotGroup._plots.
def plotting.PlotGroup.draw | ( | self, | |
legendLabels, | |||
prefix = None , |
|||
separate = False , |
|||
saveFormat = ".pdf" , |
|||
ratio = True , |
|||
directory = "" |
|||
) |
Draw the histograms using values for a given algorithm. Arguments: legendLabels -- List of strings for legend labels (corresponding to the tdirectories in create()) prefix -- Optional string for file name prefix (default None) separate -- Save the plots of a group to separate files instead of a file per group (default False) saveFormat -- String specifying the plot format (default '.pdf') ratio -- Add ratio to the plot (default True) directory -- Directory where to save the file (default "")
Definition at line 2315 of file plotting.py.
References plotting._createCanvas(), plotting.PlotGroup._createLegend(), plotting.PlotGroup._drawSeparate(), plotting.PlotGroup._modifyPadForRatio(), ModulesProxy._ModuleProxy._name, FP420HitsObject._name, TrackerHitsObject._name, PGeometricDet::Item._name, TrackingRecHitAlgorithm._name, Logger._name, hcaldqm::DQModule._name, citk::IsolationConeDefinitionBase._name, condhdf5tohdf5.H5DataProduct._name, WValidation._name, DrellYanValidation._name, hcaldqm::flag::Flag._name, hcaldqm::quantity::Quantity._name, HistoParams< T >._name, condhdf5tohdf5.H5Tag._name, CutApplicatorBase._name, condhdf5tohdf5.H5GlobalTag._name, HistoParams< TH2F >._name, HistoParams< TProfile2D >._name, conddb2hdf5.DBGlobalTag._name, SequenceTypes.SequencePlaceholder._name, plotting.Subtract._name, plotting.Transform._name, plotting.FakeDuplicate._name, plotting.CutEfficiency._name, plotting.AggregateBins._name, plotting.AggregateHistos._name, plotting.ROC._name, SequenceTypes._TaskBasePlaceholder._name, plotting.Plot._name, plotting.PlotGroup._name, plotting.PlotGroup._plots, plotting.PlotGroup._ratioFactor, plotting.PlotGroup._save(), createfilelist.int, and WZElectronSkims53X_cff.max.
def plotting.PlotGroup.getName | ( | self | ) |
Definition at line 2276 of file plotting.py.
References ModulesProxy._ModuleProxy._name, FP420HitsObject._name, TrackerHitsObject._name, PGeometricDet::Item._name, TrackingRecHitAlgorithm._name, Logger._name, hcaldqm::DQModule._name, citk::IsolationConeDefinitionBase._name, condhdf5tohdf5.H5DataProduct._name, WValidation._name, DrellYanValidation._name, hcaldqm::flag::Flag._name, hcaldqm::quantity::Quantity._name, HistoParams< T >._name, condhdf5tohdf5.H5Tag._name, CutApplicatorBase._name, condhdf5tohdf5.H5GlobalTag._name, HistoParams< TH2F >._name, HistoParams< TProfile2D >._name, conddb2hdf5.DBGlobalTag._name, SequenceTypes.SequencePlaceholder._name, plotting.Subtract._name, plotting.Transform._name, plotting.FakeDuplicate._name, plotting.CutEfficiency._name, plotting.AggregateBins._name, plotting.AggregateHistos._name, plotting.ROC._name, SequenceTypes._TaskBasePlaceholder._name, plotting.Plot._name, and plotting.PlotGroup._name.
def plotting.PlotGroup.getPlot | ( | self, | |
name | |||
) |
Definition at line 2295 of file plotting.py.
References plotting.PlotGroup._plots.
def plotting.PlotGroup.getPlots | ( | self | ) |
Definition at line 2279 of file plotting.py.
References plotting.PlotGroup._plots.
def plotting.PlotGroup.onlyForPileup | ( | self | ) |
Return True if the PlotGroup is intended only for pileup samples
Definition at line 2301 of file plotting.py.
References plotting.PlotFolder._onlyForPileup.
def plotting.PlotGroup.remove | ( | self, | |
name | |||
) |
Definition at line 2282 of file plotting.py.
References ModulesProxy._ModuleProxy._name, FP420HitsObject._name, TrackerHitsObject._name, PGeometricDet::Item._name, TrackingRecHitAlgorithm._name, Logger._name, hcaldqm::DQModule._name, citk::IsolationConeDefinitionBase._name, condhdf5tohdf5.H5DataProduct._name, WValidation._name, DrellYanValidation._name, hcaldqm::flag::Flag._name, hcaldqm::quantity::Quantity._name, HistoParams< T >._name, condhdf5tohdf5.H5Tag._name, CutApplicatorBase._name, condhdf5tohdf5.H5GlobalTag._name, HistoParams< TH2F >._name, HistoParams< TProfile2D >._name, conddb2hdf5.DBGlobalTag._name, SequenceTypes.SequencePlaceholder._name, plotting.Subtract._name, plotting.Transform._name, plotting.FakeDuplicate._name, plotting.CutEfficiency._name, plotting.AggregateBins._name, plotting.AggregateHistos._name, plotting.ROC._name, SequenceTypes._TaskBasePlaceholder._name, plotting.Plot._name, plotting.PlotGroup._name, and plotting.PlotGroup._plots.
def plotting.PlotGroup.setProperties | ( | self, | |
kwargs | |||
) |
Definition at line 2270 of file plotting.py.
|
private |
Definition at line 2250 of file plotting.py.
Referenced by trackingPlots.TimePerEventPlot.__str__(), trackingPlots.TimePerTrackPlot.__str__(), trackingPlots.TimePerEventPlot._create(), plotting.PlotGroup._drawSeparate(), plotting.PlotGroup._save(), trackingPlots.TimePerTrackPlot.create(), plotting.PlotGroup.draw(), plotting.PlotGroup.getName(), plotting.PlotterFolder.getName(), plotting.PlotterItem.getName(), plotting.PlotterFolder.getSelectionNameIterator(), validation.SimpleSample.name(), trackingPlots.Iteration.name(), plotting.PlotterItem.readDirs(), and plotting.PlotGroup.remove().
|
private |
Definition at line 2251 of file plotting.py.
Referenced by plotting.PlotGroup._drawSeparate(), plotting.PlotGroup.append(), plotting.Plotter.append(), plotting.Plotter.appendTable(), plotting.PlotGroup.clear(), plotting.Plotter.clear(), trackingPlots.TrackingSeedingLayerTable.create(), plotting.PlotGroup.create(), trackingPlots.TrackingSeedingLayerTable.draw(), plotting.PlotGroup.draw(), plotting.PlotGroup.getPlot(), plotting.Plotter.getPlotFolder(), plotting.Plotter.getPlotFolderNames(), plotting.Plotter.getPlotFolders(), plotting.PlotGroup.getPlots(), plotting.Plotter.readDirs(), and plotting.PlotGroup.remove().
|
private |
Definition at line 2268 of file plotting.py.
Referenced by plotting.PlotGroup._drawSeparate(), plotting.PlotGroup._modifyPadForRatio(), and plotting.PlotGroup.draw().