CMS 3D CMS Logo

Functions | Variables
create_public_pileup_plots Namespace Reference

Functions

def TweakPlot (fig, ax, add_extra_head_room=False)
 

Variables

 action
 
 arg_parser
 
 args
 
 ax
 
 bin_edges
 
 bins
 
 cache_file_dir
 
 cfg_defaults
 
 cfg_parser
 
 cmd
 
 cms_energy_str
 
 color_fill_pileup
 
 color_line_pileup
 
 color_scheme
 
 color_scheme_names
 
 color_scheme_names_tmp
 
 config_file_name
 
 desc_str
 
 description
 
 edgecolor
 
 exp
 
 facecolor
 
 fig
 
 file_suffix
 
 fontproperties
 
 help
 
 hist
 
 histtype
 
 horizontalalignment
 
 ignore_cache
 
 IgnoreCommandLineOptions
 
 in_file
 
 input_json
 
 input_lumi_json
 
 is_log
 
 log
 
 log_setting
 
 log_suffix
 
 logo_name
 
 min_val
 
 options
 
 output
 
 particle_type_str
 
 pileup_hist
 
 pileupcalc_flags_from_cfg
 
 status
 
 tmp_file_name
 
 transform
 
 vals
 
 verbose
 
 weights
 
 year
 

Function Documentation

def create_public_pileup_plots.TweakPlot (   fig,
  ax,
  add_extra_head_room = False 
)

Definition at line 61 of file create_public_pileup_plots.py.

61 def TweakPlot(fig, ax, add_extra_head_room=False):
62 
63  # Fiddle with axes ranges etc.
64  ax.relim()
65  ax.autoscale_view(False, True, True)
66  for label in ax.get_xticklabels():
67  label.set_ha("right")
68  label.set_rotation(30.)
69 
70  # Bit of magic here: increase vertical scale by one tick to make
71  # room for the legend.
72  if add_extra_head_room:
73  y_ticks = ax.get_yticks()
74  (y_min, y_max) = ax.get_ylim()
75  is_log = (ax.get_yscale() == "log")
76  y_max_new = y_max
77  if is_log:
78  tmp = y_ticks[-1] / y_ticks[-2]
79  y_max_new = y_max * math.pow(tmp, add_extra_head_room)
80  else:
81  tmp = y_ticks[-1] - y_ticks[-2]
82  y_max_new = y_max + add_extra_head_room * tmp
83  ax.set_ylim(y_min, y_max_new)
84 
85  # Add a second vertical axis on the right-hand side.
86  ax_sec = ax.twinx()
87  ax_sec.set_ylim(ax.get_ylim())
88  ax_sec.set_yscale(ax.get_yscale())
89 
90  for ax_tmp in fig.axes:
91  for sub_ax in [ax_tmp.xaxis, ax_tmp.yaxis]:
92  for label in sub_ax.get_ticklabels():
93  label.set_font_properties(FONT_PROPS_TICK_LABEL)
94 
95  if is_log:
96  fig.subplots_adjust(top=.89, bottom=.125, left=.11, right=.925)
97  else:
98  fig.subplots_adjust(top=.89, bottom=.125, left=.1, right=.925)
99 
100  # End of TweakPlot().
101 
def TweakPlot(fig, ax, add_extra_head_room=False)

Variable Documentation

create_public_pileup_plots.action

Definition at line 109 of file create_public_pileup_plots.py.

create_public_pileup_plots.arg_parser

Definition at line 108 of file create_public_pileup_plots.py.

create_public_pileup_plots.args

Definition at line 113 of file create_public_pileup_plots.py.

create_public_pileup_plots.ax

Definition at line 232 of file create_public_pileup_plots.py.

create_public_pileup_plots.bin_edges

Definition at line 201 of file create_public_pileup_plots.py.

create_public_pileup_plots.bins

Definition at line 234 of file create_public_pileup_plots.py.

Referenced by egHLT::MonElemFuncs.addTightLooseTrigHist(), JetResolutionDemo.analyze(), SiStripBaselineAnalyzer.analyze(), PhysicsPerformanceDBWriterTFormula_fromfile_WPandPL.beginJob(), MuonTrackValidatorBase.BinLogX(), NewMuonTrackValidatorBase.BinLogX(), FSQ::HandlerTemplate< TInputCandidateType, TOutputCandidateType, filter >.book(), FastTimerService::PlotsPerElement.book(), FastTimerService::PlotsPerPath.book(), SiPixelActionExecutor.bookEfficiency(), ME0DigisValidation.bookHistograms(), TopDiLeptonDQM.bookHistograms(), TauTagValidation.bookHistograms(), PrimaryVertexAnalyzer4PUSlimmed.bookHistograms(), HcalDDDRecConstants.dddConstants(), METTesterPostProcessor.dqmEndJob(), SimHitsValidationHcal::etaRange.etaRange(), HistogramManager.executeExtend(), CalibrationSummaryFactory.extract(), NoiseSummaryFactory.extract(), PedestalsSummaryFactory.extract(), PedsFullNoiseSummaryFactory.extract(), PedsOnlySummaryFactory.extract(), DaqScopeModeTask.fill(), CSCValHists.fill1DHist(), CSCValHists.fill1DHistByChamber(), CSCValHists.fill1DHistByCrate(), CSCValHists.fill1DHistByLayer(), CSCValHists.fill1DHistByStation(), CSCValHists.fill1DHistByType(), CSCValHists.fillCalibHist(), METMonitor.fillDescriptions(), RPCNoisyStripTest.fillGlobalME(), FastTimerServiceClient.fillPathSummaryPlots(), HcalQLPlotHistoMgr.GetAHistogramImpl(), HcalDDDRecConstants.getEtaBins(), egHLT::MonElemFuncs.getIB(), SimHitsValidationHcal.getLimits(), JME::JetResolutionObject.getRecord(), HcalDDDRecConstants.getThickActive(), HFShowerLibraryEventInfo.HFShowerLibraryEventInfo(), CSCValidation.histoEfficiency(), egHLT::MonElemFuncs.initTightLooseTrigHists(), egHLT::MonElemFuncs.initTrigTagProbeHist(), egHLT::MonElemFuncs.initTrigTagProbeHist_2Leg(), egHLT::MonElemFuncs.initTrigTagProbeHists(), npstat.interpolateHistoND(), CastorLedAnalysis.LedTrendings(), HcalLedAnalysis.LedTrendings(), LA_Filler_Fitter.make_and_fit_symmchi2(), reco::tau::RecoTauDiscriminationBinnedIsolation.operator()(), egHLT::PhoHLTFilterMon.operator=(), egHLT::EleHLTFilterMon.operator=(), CastorPedestalAnalysis.per2CapsHists(), HcalPedestalAnalysis.per2CapsHists(), MuonResiduals6DOFFitter.plot(), ThroughputService.preStreamBeginRun(), reco::tau::RecoTauDiscriminationBinnedIsolation.RecoTauDiscriminationBinnedIsolation(), LA_Filler_Fitter.rms_profile(), ecaldqm::MESetProjection.setBinContent(), ecaldqm::MESetProjection.setBinEntries(), ecaldqm::MESetProjection.setBinError(), TagProbeFitter.setBinnedFit(), TagProbeFitter.setBinsForMassPlots(), ESTrendTask.shift2Left(), ESTrendTask.shift2Right(), LA_Filler_Fitter.subset_probability(), CastorPedestalAnalysis.Trendings(), HcalPedestalAnalysis.Trendings(), Folder.update(), CSCEfficiency.~CSCEfficiency(), and ESTrendTask.~ESTrendTask().

create_public_pileup_plots.cache_file_dir

Definition at line 134 of file create_public_pileup_plots.py.

create_public_pileup_plots.cfg_defaults

Definition at line 121 of file create_public_pileup_plots.py.

create_public_pileup_plots.cfg_parser

Definition at line 126 of file create_public_pileup_plots.py.

create_public_pileup_plots.cmd

Definition at line 171 of file create_public_pileup_plots.py.

create_public_pileup_plots.cms_energy_str

Definition at line 150 of file create_public_pileup_plots.py.

create_public_pileup_plots.color_fill_pileup

Definition at line 217 of file create_public_pileup_plots.py.

create_public_pileup_plots.color_line_pileup

Definition at line 216 of file create_public_pileup_plots.py.

create_public_pileup_plots.color_scheme

Definition at line 215 of file create_public_pileup_plots.py.

create_public_pileup_plots.color_scheme_names

Definition at line 138 of file create_public_pileup_plots.py.

create_public_pileup_plots.color_scheme_names_tmp

Definition at line 137 of file create_public_pileup_plots.py.

create_public_pileup_plots.config_file_name

Definition at line 118 of file create_public_pileup_plots.py.

create_public_pileup_plots.desc_str

Definition at line 106 of file create_public_pileup_plots.py.

create_public_pileup_plots.description

Definition at line 108 of file create_public_pileup_plots.py.

create_public_pileup_plots.edgecolor

Definition at line 236 of file create_public_pileup_plots.py.

create_public_pileup_plots.exp

Definition at line 228 of file create_public_pileup_plots.py.

create_public_pileup_plots.facecolor

Definition at line 237 of file create_public_pileup_plots.py.

create_public_pileup_plots.fig

Definition at line 221 of file create_public_pileup_plots.py.

create_public_pileup_plots.file_suffix

Definition at line 219 of file create_public_pileup_plots.py.

create_public_pileup_plots.fontproperties

Definition at line 243 of file create_public_pileup_plots.py.

create_public_pileup_plots.help

Definition at line 110 of file create_public_pileup_plots.py.

create_public_pileup_plots.hist

Definition at line 33 of file create_public_pileup_plots.py.

create_public_pileup_plots.histtype

Definition at line 235 of file create_public_pileup_plots.py.

create_public_pileup_plots.horizontalalignment

Definition at line 255 of file create_public_pileup_plots.py.

create_public_pileup_plots.ignore_cache

Definition at line 119 of file create_public_pileup_plots.py.

create_public_pileup_plots.IgnoreCommandLineOptions

Definition at line 39 of file create_public_pileup_plots.py.

create_public_pileup_plots.in_file

Definition at line 185 of file create_public_pileup_plots.py.

create_public_pileup_plots.input_json

Definition at line 144 of file create_public_pileup_plots.py.

create_public_pileup_plots.input_lumi_json

Definition at line 145 of file create_public_pileup_plots.py.

create_public_pileup_plots.is_log

Definition at line 224 of file create_public_pileup_plots.py.

create_public_pileup_plots.log

Definition at line 234 of file create_public_pileup_plots.py.

create_public_pileup_plots.log_setting

Definition at line 225 of file create_public_pileup_plots.py.

create_public_pileup_plots.log_suffix

Definition at line 262 of file create_public_pileup_plots.py.

create_public_pileup_plots.logo_name

Definition at line 218 of file create_public_pileup_plots.py.

create_public_pileup_plots.min_val

Definition at line 227 of file create_public_pileup_plots.py.

create_public_pileup_plots.options

Definition at line 113 of file create_public_pileup_plots.py.

create_public_pileup_plots.output

Definition at line 177 of file create_public_pileup_plots.py.

create_public_pileup_plots.particle_type_str

Definition at line 148 of file create_public_pileup_plots.py.

create_public_pileup_plots.pileup_hist

Definition at line 190 of file create_public_pileup_plots.py.

create_public_pileup_plots.pileupcalc_flags_from_cfg

Definition at line 143 of file create_public_pileup_plots.py.

create_public_pileup_plots.status

Definition at line 177 of file create_public_pileup_plots.py.

create_public_pileup_plots.tmp_file_name

Definition at line 169 of file create_public_pileup_plots.py.

create_public_pileup_plots.transform

Definition at line 254 of file create_public_pileup_plots.py.

create_public_pileup_plots.vals

Definition at line 203 of file create_public_pileup_plots.py.

Referenced by fwlite::ObjectCountSelector< Collection >.accept(), l1t::Setting.addTableRow(), L1TMuonBarrelParamsHelper.configFromDB(), fwlite::Scanner< Collection >.count(), DDConstant.createConstantsFromEvaluator(), CharmTagger.discriminator(), PhysicsTools::TrainProcessor.doTrainData(), fwlite::Scanner< Collection >.draw(), fwlite::Scanner< Collection >.draw2D(), fwlite::Scanner< Collection >.drawGraph(), fwlite::Scanner< Collection >.drawProf(), dumpHcalMatrixObject(), Vx3DHLTAnalyzer.endLuminosityBlock(), fwlite::Scanner< Collection >.fillDataSet(), l1t::Setting.getVector(), DeepFlavourJetTagsProducer.produce(), ElectronEnergyRegressionEvaluate.regressionUncertaintyNoTrkVar(), ElectronEnergyRegressionEvaluate.regressionUncertaintyNoTrkVarV1(), ElectronEnergyRegressionEvaluate.regressionUncertaintyWithSubClusters(), ElectronEnergyRegressionEvaluate.regressionUncertaintyWithTrkVar(), ElectronEnergyRegressionEvaluate.regressionUncertaintyWithTrkVarV1(), ElectronEnergyRegressionEvaluate.regressionUncertaintyWithTrkVarV2(), ElectronEnergyRegressionEvaluate.regressionValueNoTrkVar(), ElectronEnergyRegressionEvaluate.regressionValueNoTrkVarV1(), ElectronEnergyRegressionEvaluate.regressionValueWithSubClusters(), ElectronEnergyRegressionEvaluate.regressionValueWithTrkVar(), ElectronEnergyRegressionEvaluate.regressionValueWithTrkVarV1(), ElectronEnergyRegressionEvaluate.regressionValueWithTrkVarV2(), fwlite::Scanner< Collection >.scan(), l1t::Setting.setValue(), edm::MultiAssociation< C >::LazyFiller.setValues(), PhysicsTools::Spline.Spline(), and DDStreamer.vars_write().

create_public_pileup_plots.verbose

Definition at line 140 of file create_public_pileup_plots.py.

create_public_pileup_plots.weights

Definition at line 205 of file create_public_pileup_plots.py.

create_public_pileup_plots.year

Definition at line 149 of file create_public_pileup_plots.py.