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
 
 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 62 of file create_public_pileup_plots.py.

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

Variable Documentation

create_public_pileup_plots.action

Definition at line 110 of file create_public_pileup_plots.py.

create_public_pileup_plots.arg_parser

Definition at line 109 of file create_public_pileup_plots.py.

create_public_pileup_plots.args

Definition at line 114 of file create_public_pileup_plots.py.

create_public_pileup_plots.ax

Definition at line 229 of file create_public_pileup_plots.py.

create_public_pileup_plots.bin_edges

Definition at line 198 of file create_public_pileup_plots.py.

create_public_pileup_plots.bins

Definition at line 231 of file create_public_pileup_plots.py.

Referenced by egHLT::MonElemFuncs.addTightLooseTrigHist(), JetResolutionDemo.analyze(), PhysicsPerformanceDBWriterTFormula_fromfile_WPandPL.beginJob(), MuonTrackValidatorBase.BinLogX(), FSQ::HandlerTemplate< TInputCandidateType, TOutputCandidateType, filter >.book(), FastTimerService::PlotsPerPath.book(), SiPixelActionExecutor.bookEfficiency(), ME0DigisValidation.bookHistograms(), TopDiLeptonDQM.bookHistograms(), TauTagValidation.bookHistograms(), PrimaryVertexAnalyzer4PUSlimmed.bookHistograms(), ConvertToHist(), HcalDDDRecConstants.dddConstants(), divide(), METTesterPostProcessor.dqmEndJob(), egHLT::EleHLTFilterMon.EleHLTFilterMon(), SimHitsValidationHcal::etaRange.etaRange(), HistogramManager.executeExtend(), CalibrationSummaryFactory.extract(), DaqScopeModeSummaryFactory.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(), DiDispStaMuonMonitor.fillDescriptions(), NoBPTXMonitor.fillDescriptions(), DiJetMonitor.fillDescriptions(), METplusTrackMonitor.fillDescriptions(), PhotonMonitor.fillDescriptions(), TopMonitor.fillDescriptions(), MuonMonitor.fillDescriptions(), JetMonitor.fillDescriptions(), METMonitor.fillDescriptions(), HTMonitor.fillDescriptions(), RPCNoisyStripTest.fillGlobalME(), HTDQM.fillHtDescription(), JetDQM.fillJetDescription(), METDQM.fillMetDescription(), FastTimerServiceClient.fillPathSummaryPlots(), HcalQLPlotHistoMgr.GetAHistogramImpl(), HcalDDDRecConstants.getEtaBins(), egHLT::MonElemFuncs.getIB(), SimHitsValidationHcal.getLimits(), SiPixelQualityProbabilities.getPileUpBins(), JME::JetResolutionObject.getRecord(), HcalDDDRecConstants.getThickActive(), HFShowerLibraryEventInfo.HFShowerLibraryEventInfo(), CSCValidation.histoEfficiency(), identity(), 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(), egHLT::PhoHLTFilterMon.PhoHLTFilterMon(), MuonResiduals6DOFFitter.plot(), ThroughputService.preGlobalBeginRun(), 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 133 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 170 of file create_public_pileup_plots.py.

create_public_pileup_plots.cms_energy_str

Definition at line 149 of file create_public_pileup_plots.py.

create_public_pileup_plots.color_fill_pileup

Definition at line 214 of file create_public_pileup_plots.py.

create_public_pileup_plots.color_line_pileup

Definition at line 213 of file create_public_pileup_plots.py.

create_public_pileup_plots.color_scheme

Definition at line 212 of file create_public_pileup_plots.py.

create_public_pileup_plots.color_scheme_names

Definition at line 137 of file create_public_pileup_plots.py.

create_public_pileup_plots.color_scheme_names_tmp

Definition at line 136 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 107 of file create_public_pileup_plots.py.

create_public_pileup_plots.description

Definition at line 109 of file create_public_pileup_plots.py.

create_public_pileup_plots.edgecolor

Definition at line 233 of file create_public_pileup_plots.py.

create_public_pileup_plots.exp

Definition at line 225 of file create_public_pileup_plots.py.

create_public_pileup_plots.facecolor

Definition at line 234 of file create_public_pileup_plots.py.

create_public_pileup_plots.fig

Definition at line 218 of file create_public_pileup_plots.py.

create_public_pileup_plots.file

Definition at line 32 of file create_public_pileup_plots.py.

create_public_pileup_plots.file_suffix

Definition at line 216 of file create_public_pileup_plots.py.

create_public_pileup_plots.fontproperties

Definition at line 240 of file create_public_pileup_plots.py.

create_public_pileup_plots.help

Definition at line 111 of file create_public_pileup_plots.py.

create_public_pileup_plots.hist

Definition at line 34 of file create_public_pileup_plots.py.

create_public_pileup_plots.histtype

Definition at line 232 of file create_public_pileup_plots.py.

create_public_pileup_plots.horizontalalignment

Definition at line 252 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 40 of file create_public_pileup_plots.py.

create_public_pileup_plots.in_file

Definition at line 183 of file create_public_pileup_plots.py.

create_public_pileup_plots.input_json

Definition at line 143 of file create_public_pileup_plots.py.

create_public_pileup_plots.input_lumi_json

Definition at line 144 of file create_public_pileup_plots.py.

create_public_pileup_plots.is_log

Definition at line 221 of file create_public_pileup_plots.py.

create_public_pileup_plots.log

Definition at line 231 of file create_public_pileup_plots.py.

create_public_pileup_plots.log_setting

Definition at line 222 of file create_public_pileup_plots.py.

create_public_pileup_plots.log_suffix

Definition at line 259 of file create_public_pileup_plots.py.

create_public_pileup_plots.logo_name

Definition at line 215 of file create_public_pileup_plots.py.

create_public_pileup_plots.min_val

Definition at line 224 of file create_public_pileup_plots.py.

create_public_pileup_plots.options

Definition at line 114 of file create_public_pileup_plots.py.

create_public_pileup_plots.output

Definition at line 176 of file create_public_pileup_plots.py.

create_public_pileup_plots.particle_type_str

Definition at line 147 of file create_public_pileup_plots.py.

create_public_pileup_plots.pileup_hist

Definition at line 187 of file create_public_pileup_plots.py.

create_public_pileup_plots.pileupcalc_flags_from_cfg

Definition at line 142 of file create_public_pileup_plots.py.

create_public_pileup_plots.status

Definition at line 176 of file create_public_pileup_plots.py.

create_public_pileup_plots.tmp_file_name

Definition at line 168 of file create_public_pileup_plots.py.

create_public_pileup_plots.transform

Definition at line 251 of file create_public_pileup_plots.py.

create_public_pileup_plots.vals

Definition at line 200 of file create_public_pileup_plots.py.

Referenced by fwlite::ObjectCountSelector< Collection >.accept(), L1TMuonBarrelParamsHelper.configFromDB(), fwlite::Scanner< Collection >.count(), DDConstant.createConstantsFromEvaluator(), HcalDbASCIIIO.createObject< HcalElectronicsMap >(), DDStrVector.DDStrVector(), DDVector.DDVector(), CharmTagger.discriminator(), PhysicsTools::TrainProcessor.doTrainData(), fwlite::Scanner< Collection >.draw(), fwlite::Scanner< Collection >.draw2D(), fwlite::Scanner< Collection >.drawGraph(), fwlite::Scanner< Collection >.drawProf(), btagbtvdeep.dump_vector(), Vx3DHLTAnalyzer.endLuminosityBlock(), SimpleFlatTableProducerBase< T, TProd >::FuncVariable< StringFunctor, ValType >.fill(), SimpleFlatTableProducer< T >::ValueMapVariable< TIn, ValType >.fill(), fwlite::Scanner< Collection >.fillDataSet(), ReducedEGProducer.produce(), BetaStarVarProducer< T >.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(), edm::MultiAssociation< C >::LazyFiller.setValues(), and PhysicsTools::Spline.Spline().

create_public_pileup_plots.verbose

Definition at line 139 of file create_public_pileup_plots.py.

create_public_pileup_plots.weights

Definition at line 202 of file create_public_pileup_plots.py.

create_public_pileup_plots.year

Definition at line 148 of file create_public_pileup_plots.py.