CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
SideBandSubtract Class Reference

#include <SideBandSubtraction.h>

Public Member Functions

void addSideBandRegion (Double_t min, Double_t max)
 
void addSignalRegion (Double_t min, Double_t max)
 
void doFastSubtraction (TH1F &Total, TH1F &Result, SbsRegion &leftRegion, SbsRegion &rightRegion)
 
int doGlobalFit ()
 
int doSubtraction (RooRealVar *variable, Double_t stsratio, Int_t index)
 
std::vector< TH1F * > getBaseHistos ()
 
RooFitResult * getFitResult ()
 
std::vector< TH1F > getRawHistos ()
 
std::vector< TH1F > getSBSHistos ()
 
Double_t getSTSRatio ()
 
void printResults (std::string prefix="")
 
void resetSBSProducts ()
 
void saveResults (std::string outname)
 
void setDataSet (RooDataSet *newData)
 
 SideBandSubtract ()
 
 SideBandSubtract (RooAbsPdf *model_shape, RooAbsPdf *bkg_shape, RooDataSet *data, RooRealVar *sep_var, const std::vector< TH1F * > &base, bool verb)
 
 ~SideBandSubtract ()
 

Private Member Functions

Double_t getYield (const std::vector< SbsRegion > &Regions, RooAbsPdf *PDF)
 
void print_plot (RooRealVar *printVar, std::string outname)
 

Private Attributes

RooAbsPdf * BackgroundPDF
 
TH1F * base_histo
 
std::vector< TH1F * > BaseHistos
 
RooDataSet * Data
 
RooFitResult * fit_result
 
RooAbsPdf * ModelPDF
 
std::vector< TH1F > RawHistos
 
std::vector< TH1F > SBSHistos
 
RooRealVar * SeparationVariable
 
std::vector< TH1F > SideBandHistos
 
std::vector< SbsRegionSideBandRegions
 
std::vector< SbsRegionSignalRegions
 
Double_t SignalSidebandRatio
 
bool verbose
 

Detailed Description

Definition at line 19 of file SideBandSubtraction.h.

Constructor & Destructor Documentation

◆ SideBandSubtract() [1/2]

SideBandSubtract::SideBandSubtract ( )

Definition at line 290 of file SideBandSubtraction.cc.

291  : BackgroundPDF(nullptr),
292  ModelPDF(nullptr),
293  Data(nullptr),
294  SeparationVariable(nullptr),
295  verbose(false),
296  SignalRegions(),
297  SideBandRegions(),
298  SideBandHistos(0),
299  RawHistos(0),
300  SBSHistos(0),
301  BaseHistos(0),
302  fit_result(nullptr),
304  // Default constructor so we can do fast subtraction
305 }

◆ SideBandSubtract() [2/2]

SideBandSubtract::SideBandSubtract ( RooAbsPdf *  model_shape,
RooAbsPdf *  bkg_shape,
RooDataSet *  data,
RooRealVar *  sep_var,
const std::vector< TH1F * > &  base,
bool  verb 
)

Definition at line 306 of file SideBandSubtraction.cc.

312  : BackgroundPDF(bkg_shape),
313  ModelPDF(model_shape),
314  Data(data),
315  SeparationVariable(sep_var),
316  verbose(verb),
317  SignalRegions(),
318  SideBandRegions(),
319  SideBandHistos(),
320  RawHistos(),
321  SBSHistos(),
322  BaseHistos(base),
323  base_histo(nullptr),
324  fit_result(nullptr),
325  SignalSidebandRatio(0) {}

◆ ~SideBandSubtract()

SideBandSubtract::~SideBandSubtract ( )

Definition at line 372 of file SideBandSubtraction.cc.

372  {
373  //**WARNING**
374 
375  // We don't delete objects that we don't own (duh) so, all of our
376  // pointers just hang out and get handled by other people :)
377 
378  // We DO own the BaseHistos IFF the user didn't provide us with
379  // them and we constructed them from the dataset... in this case
380  // base_histo will be non-null and we want to delete the vector
381  // of histograms...
383  /*
384  if(base_histo!=NULL)
385  {
386  BaseHistos.clear();
387  }
388  */
389 }

References resetSBSProducts().

Member Function Documentation

◆ addSideBandRegion()

void SideBandSubtract::addSideBandRegion ( Double_t  min,
Double_t  max 
)

Definition at line 400 of file SideBandSubtraction.cc.

400  {
401  SbsRegion sideband;
402  sideband.min = min;
403  sideband.max = max;
404  sideband.RegionName = "SideBand" + stringify(SideBandRegions.size());
405  if (SeparationVariable != nullptr)
406  SeparationVariable->setRange(sideband.RegionName.c_str(), sideband.min, sideband.max);
407  SideBandRegions.push_back(sideband);
408  return;
409 }

References SbsRegion::max, SiStripPI::max, SbsRegion::min, min(), SbsRegion::RegionName, SeparationVariable, SideBandRegions, and stringify().

◆ addSignalRegion()

void SideBandSubtract::addSignalRegion ( Double_t  min,
Double_t  max 
)

Definition at line 390 of file SideBandSubtraction.cc.

390  {
391  SbsRegion signal;
392  signal.min = min;
393  signal.max = max;
394  signal.RegionName = "Signal" + stringify(SignalRegions.size());
395  if (SeparationVariable != nullptr)
396  SeparationVariable->setRange(signal.RegionName.c_str(), signal.min, signal.max);
397  SignalRegions.push_back(signal);
398  return;
399 }

References SbsRegion::max, SiStripPI::max, SbsRegion::min, min(), SbsRegion::RegionName, SeparationVariable, SignalRegions, and stringify().

◆ doFastSubtraction()

void SideBandSubtract::doFastSubtraction ( TH1F &  Total,
TH1F &  Result,
SbsRegion leftRegion,
SbsRegion rightRegion 
)

Definition at line 451 of file SideBandSubtraction.cc.

451  {
452  Int_t binMin = Total.FindBin(leftRegion.max, 0.0, 0.0);
453  Int_t binMax = Total.FindBin(leftRegion.min, 0.0, 0.0);
454  double numLeft = Total.Integral(binMin, binMax);
455 
456  binMin = Total.FindBin(rightRegion.max, 0.0, 0.0);
457  binMax = Total.FindBin(rightRegion.min, 0.0, 0.0);
458  double numRight = Total.Integral(binMin, binMax);
459 
460  const unsigned int nbinsx = Total.GetNbinsX();
461  const double x1 = (leftRegion.max + leftRegion.min) / 2.0;
462  const double x2 = (rightRegion.max + rightRegion.min) / 2.0;
463 
464  const double y1 = numLeft / (leftRegion.max - leftRegion.min);
465  const double y2 = numRight / (rightRegion.max - rightRegion.min);
466 
467  const double Slope = (y2 - y1) / (x2 - x1);
468  const double Intercept = y1 - Slope * x1;
469  // Evantually we want to handle more complicated functions, but for
470  // now... just use a linear one
471  TF1 function("sbs_function_line", "[0]*x + [1]", Total.GetMinimum(), Total.GetMaximum());
472  for (unsigned int binx = 1; binx <= nbinsx; ++binx) {
473  double binWidth = Total.GetBinWidth(binx);
474  function.SetParameter(0, Slope * binWidth);
475  function.SetParameter(1, Intercept * binWidth);
476 
477  double xx = Total.GetBinCenter(binx);
478  double cu = Total.GetBinContent(binx) - function.Eval(xx);
479  // TODO: Propogate the error on the parameters in function.
480  double error1 = Total.GetBinError(binx);
481 
482  Result.SetBinContent(binx, cu);
483  Result.SetBinError(binx, error1);
484  }
485  Result.SetEntries(Result.Integral());
486 }

References spclusmultinvestigator_cfi::binMax, eeNoiseFilter_cfi::Intercept, SbsRegion::max, SbsRegion::min, eeNoiseFilter_cfi::Slope, tools::TF1, IntegrityTask_cfi::Total, testProducerWithPsetDescEmpty_cfi::x1, testProducerWithPsetDescEmpty_cfi::x2, geometryCSVtoXML::xx, testProducerWithPsetDescEmpty_cfi::y1, and testProducerWithPsetDescEmpty_cfi::y2.

◆ doGlobalFit()

int SideBandSubtract::doGlobalFit ( )

Definition at line 410 of file SideBandSubtraction.cc.

410  {
411  if (verbose)
412  cout << "Beginning SideBand Subtraction\n";
413 
414  if (ModelPDF != nullptr && Data != nullptr && SeparationVariable != nullptr) {
415  fit_result = ModelPDF->fitTo(*Data, "r");
416  } else {
417  cerr << "ERROR: doGobalFit, no ModelPDF, SeparationVariable or Data specified\n";
418  return -1;
419  }
420 
421  Double_t SideBandYield = getYield(SideBandRegions, BackgroundPDF);
422  Double_t BackgroundInSignal = getYield(SignalRegions, BackgroundPDF);
423 
424  SignalSidebandRatio = BackgroundInSignal / SideBandYield;
425  if (verbose) {
426  cout << "Finished fitting background!\n";
427  cout << "Attained a Signal to Sideband ratio of: " << SignalSidebandRatio << endl;
428  }
429  //I can't see a way around a double loop for each variable. Maybe I
430  //can get a C++/RooFit guru to save me the trouble here?
431 
432  //need to grab sbs objects after each global fit, because they get reset
434  TIterator* iter = (TIterator*)Data->get()->createIterator();
435  RooAbsArg* variable;
436  while ((variable = (RooAbsArg*)iter->Next())) {
437  for (unsigned int i = 0; i < BaseHistos.size(); i++) {
438  if ((string)variable->GetName() != (string)SeparationVariable->GetName() &&
439  (string)variable->GetName() == (string)BaseHistos[i]->GetName())
441  }
442  }
443 
444  // clean up our memory...
445  if (variable)
446  delete variable;
447  if (iter)
448  delete iter;
449  return 0;
450 }

References BackgroundPDF, BaseHistos, beam_dqm_sourceclient-live_cfg::cerr, gather_cfg::cout, Data, doSubtraction(), fit_result, getYield(), mps_fire::i, ModelPDF, resetSBSProducts(), SeparationVariable, SideBandRegions, SignalRegions, SignalSidebandRatio, AlCaHLTBitMon_QueryRunRegistry::string, taus_updatedMVAIds_cff::variable, and verbose.

◆ doSubtraction()

int SideBandSubtract::doSubtraction ( RooRealVar *  variable,
Double_t  stsratio,
Int_t  index 
)

Definition at line 77 of file SideBandSubtraction.cc.

80 {
81  if (Data == nullptr || SeparationVariable == nullptr) {
82  cerr << "ERROR: Data or SeparationVariable is NULL returning now!\n";
83  return -1;
84  }
85  TH1F* SideBandHist = (TH1F*)BaseHistos[index]->Clone();
86  setHistOptions(SideBandHist,
87  (string)variable->GetName() + "Sideband",
88  (string)SideBandHist->GetTitle() + " Sideband",
89  (string)variable->getUnit());
90 
91  TH1F* SignalHist = (TH1F*)BaseHistos[index]->Clone();
92  setHistOptions(SignalHist,
93  (string)variable->GetName() + "SignalHist",
94  (string)SignalHist->GetTitle() + " Raw Signal",
95  (string)variable->getUnit());
96 
97  //Begin a loop over the data to fill our histograms. I should figure
98  //out how to do this in one shot to avoid a loop
99  //O(N_vars*N_events)...
100 
101  TIterator* iter = (TIterator*)Data->get()->createIterator();
102  RooAbsArg* var = nullptr;
103  RooRealVar* sep_var = nullptr;
104  while ((var = (RooAbsArg*)iter->Next())) {
105  if ((string)var->GetName() == (string)SeparationVariable->GetName()) {
106  sep_var = (RooRealVar*)var;
107  break;
108  }
109  }
110  for (int i = 0; i < Data->numEntries(); i++) {
111  Data->get(i);
112  Double_t value = variable->getVal();
113  Double_t cutval = sep_var->getVal();
114 
115  for (unsigned int j = 0; j < SideBandRegions.size(); j++) //UGLY! Find better solution!
116  {
117  if (cutval > SideBandRegions[j].min && cutval < SideBandRegions[j].max)
118  SideBandHist->Fill(value);
119  }
120  for (unsigned int j = 0; j < SignalRegions.size(); j++) {
121  if (cutval > SignalRegions[j].min && cutval < SignalRegions[j].max)
122  SignalHist->Fill(value);
123  }
124  }
125  //Save pre-subtracted histo
126  SignalHist->Sumw2();
127  SideBandHist->Sumw2();
128  //SignalHist->SetDirectory(0); SideBandHist->SetDirectory(0);
129  RawHistos.push_back(*SignalHist);
130 
131  SignalHist->Add(SideBandHist, -stsratio);
132 
133  SignalHist->SetTitle(((string)BaseHistos[index]->GetTitle() + " SBS Signal").c_str());
134  //Save subtracted histo
135  SBSHistos.push_back(*SignalHist);
136  //Save Sideband histo
137  SideBandHistos.push_back(*SideBandHist);
138 
139  if (SideBandHist)
140  delete SideBandHist;
141  return 0;
142 }

References beam_dqm_sourceclient-live_cfg::cerr, mps_fire::i, dqmiolumiharvest::j, SiStripPI::max, min(), setHistOptions(), AlCaHLTBitMon_QueryRunRegistry::string, trigObjTnPSource_cfi::var, and taus_updatedMVAIds_cff::variable.

Referenced by doGlobalFit().

◆ getBaseHistos()

vector< TH1F * > SideBandSubtract::getBaseHistos ( )

Definition at line 488 of file SideBandSubtraction.cc.

488 { return BaseHistos; }

References BaseHistos.

◆ getFitResult()

RooFitResult * SideBandSubtract::getFitResult ( )

Definition at line 487 of file SideBandSubtraction.cc.

487 { return fit_result; }

References fit_result.

◆ getRawHistos()

vector< TH1F > SideBandSubtract::getRawHistos ( )

Definition at line 489 of file SideBandSubtraction.cc.

489 { return RawHistos; }

References RawHistos.

◆ getSBSHistos()

vector< TH1F > SideBandSubtract::getSBSHistos ( )

Definition at line 490 of file SideBandSubtraction.cc.

490 { return SBSHistos; }

References SBSHistos.

◆ getSTSRatio()

Double_t SideBandSubtract::getSTSRatio ( )

Definition at line 491 of file SideBandSubtraction.cc.

491 { return SignalSidebandRatio; }

References SignalSidebandRatio.

◆ getYield()

Double_t SideBandSubtract::getYield ( const std::vector< SbsRegion > &  Regions,
RooAbsPdf *  PDF 
)
private

Definition at line 51 of file SideBandSubtraction.cc.

51  {
52  if (PDF == nullptr || SeparationVariable == nullptr)
53  return 0.0;
54 
55  Double_t yield = 0;
56  RooAbsReal* intPDF;
57  for (unsigned int i = 0; i < Regions.size(); i++) {
58  if (verbose)
59  cout << "Integrating over Range: " << Regions[i].RegionName << " from " << Regions[i].min << " to "
60  << Regions[i].max << endl;
61  intPDF = PDF->createIntegral(*SeparationVariable, Range(Regions[i].RegionName.c_str()));
62  yield += intPDF->getVal();
63  if (verbose)
64  cout << "Current yield: " << yield << endl;
65  }
66  return yield;
67 }

References gather_cfg::cout, mps_fire::i, ExhumeParameters_cfi::PDF, SiPixelRawToDigiRegional_cfi::Regions, and verbose.

Referenced by doGlobalFit().

◆ print_plot()

void SideBandSubtract::print_plot ( RooRealVar *  printVar,
std::string  outname 
)
private

Definition at line 274 of file SideBandSubtraction.cc.

274  {
275  if (Data == nullptr || ModelPDF == nullptr) {
276  cerr << "ERROR: print_plot, Data or ModelPDF are NULL\n";
277  return;
278  }
279 
280  RooPlot* genericFrame = printVar->frame();
281  Data->plotOn(genericFrame);
282  ModelPDF->plotOn(genericFrame);
283  TCanvas genericCanvas;
284  genericFrame->Draw();
285  outname = outname + ".eps";
286  genericCanvas.SaveAs(outname.c_str());
287  outname.replace(outname.size() - 3, 3, "gif");
288  genericCanvas.SaveAs(outname.c_str());
289 }

References beam_dqm_sourceclient-live_cfg::cerr, and DeadROCCounter_Phase1::outname.

◆ printResults()

void SideBandSubtract::printResults ( std::string  prefix = "")

Definition at line 151 of file SideBandSubtraction.cc.

151  { //handles *all* printing
152  //spool over vectors of histograms and print them, then print
153  //separation variable plots and the results text file.
154  if (SeparationVariable == nullptr) {
155  cerr << "ERROR: printResults, SeparationVariable is NULL!\n";
156  return;
157  }
158  string filename; //output file name
159  for (unsigned int i = 0; i < RawHistos.size(); ++i) {
160  filename = prefix + "Raw_" + (string)RawHistos[i].GetName();
162  }
163  for (unsigned int i = 0; i < SBSHistos.size(); ++i) {
164  filename = prefix + "SBS_" + (string)RawHistos[i].GetName();
166  }
167  if (verbose) {
168  for (unsigned int i = 0; i < SideBandHistos.size(); ++i) {
169  filename = prefix + "SideBand_" + (string)RawHistos[i].GetName();
171  }
172  }
173 
174  string outname = prefix + (string)SeparationVariable->GetName() + "_fitted.eps";
175  if (Data != nullptr && ModelPDF != nullptr) {
176  RooPlot* SepVarFrame = SeparationVariable->frame();
177  Data->plotOn(SepVarFrame);
178  ModelPDF->plotOn(SepVarFrame);
179  TCanvas Canvas;
180  SepVarFrame->Draw();
181  Canvas.SaveAs(outname.c_str());
182  outname.replace(outname.size() - 3, 3, "gif");
183  Canvas.SaveAs(outname.c_str());
184  } else
185  cerr << "ERROR: printResults, Data or ModelPDF is NULL!\n";
186 
187  string result_outname = prefix + "_fit_results.txt";
188  std::ofstream output(result_outname.c_str(), std::ios::out);
189  if (!output) {
190  cout << "ERROR: Could not open file for writing!\n";
191  return;
192  }
193 
194  if (fit_result != nullptr) {
195 #if ROOT_VERSION_CODE <= ROOT_VERSION(5, 19, 0)
196  fit_result->printToStream(output, Verbose);
197 #else
198  fit_result->printMultiline(output, kTRUE);
199 #endif
200  }
201 }

References beam_dqm_sourceclient-live_cfg::cerr, gather_cfg::cout, corrVsCorr::filename, mps_fire::i, MillePedeFileConverter_cfg::out, DeadROCCounter_Phase1::outname, convertSQLitetoXML_cfg::output, ZMuMuAnalysisNtupler_cff::prefix, print_histo(), AlCaHLTBitMon_QueryRunRegistry::string, EcalTangentSkim_cfg::Verbose, and verbose.

◆ resetSBSProducts()

void SideBandSubtract::resetSBSProducts ( )

Definition at line 492 of file SideBandSubtraction.cc.

492  {
493  //cout <<"Starting to reset products \n";
494 
495  if (!SideBandHistos.empty())
496  SideBandHistos.clear();
497 
498  if (!RawHistos.empty())
499  RawHistos.clear();
500  if (!SBSHistos.empty())
501  SBSHistos.clear();
502 }

References RawHistos, SBSHistos, and SideBandHistos.

Referenced by doGlobalFit(), and ~SideBandSubtract().

◆ saveResults()

void SideBandSubtract::saveResults ( std::string  outname)

Definition at line 203 of file SideBandSubtraction.cc.

203  {
204  //saves the ephemeral stuff to a root file for future
205  //use/modification (ie everything printed by printResults())
206 
207  TFile output(outname.c_str(), "UPDATE"); //open the output file,
208  //create it if it doesn't
209  //exist
210  //Since keys are only available from files on disk, we need to write
211  //out a new file. If the file already existed, then we opened to
212  //update, and are writing nothing new.
213  output.Write();
214  TString dirname;
215  TIter nextkey(output.GetListOfKeys());
216  TKey* key;
217  TDirectory* curDir = nullptr;
218  while ((key = (TKey*)nextkey.Next())) {
219  if (key == nullptr)
220  break;
221  TObject* obj = key->ReadObj();
222  if (obj->IsA()->InheritsFrom("TDirectory"))
223  dirname = obj->GetName();
224  }
225 
226  if (dirname == "") {
227  //we didn't find any directories so, we'll make a new one
228  curDir = output.mkdir("run0", "Run 0");
229  output.cd("run0");
230  } else {
231  //manipulate last dir string, make a new one, and get ready to fill
232  dirname.Remove(0, 3);
233  Int_t run_num = dirname.Atoi();
234  run_num++;
235  dirname = "run" + stringify(run_num);
236  curDir = output.mkdir(dirname.Data(), ("Run " + stringify(run_num)).c_str());
237  output.cd(dirname.Data());
238  }
239  if (curDir == nullptr)
240  curDir = output.GetDirectory("", kTRUE, "");
241 
242  //these should all be the same size, but to be pedantic we'll loop
243  //over each one individually, also, we need to associate them with
244  //the directory because by default they "float" in memory to avoid
245  //conflicts with other root files the user has open. If they want to
246  //write to those files, they need to close their file, pass the name
247  //here, and then let us work.
248  for (unsigned int i = 0; i < SideBandHistos.size(); ++i) {
249  SideBandHistos[i].SetDirectory(curDir);
250  SideBandHistos[i].Write();
251  }
252  for (unsigned int i = 0; i < RawHistos.size(); ++i) {
253  RawHistos[i].SetDirectory(curDir);
254  RawHistos[i].Write();
255  }
256  for (unsigned int i = 0; i < SBSHistos.size(); ++i) {
257  SBSHistos[i].SetDirectory(curDir);
258  SBSHistos[i].Write();
259  }
260  if (Data != nullptr && ModelPDF != nullptr && BackgroundPDF != nullptr && SeparationVariable != nullptr) {
261  RooPlot* sep_varFrame = SeparationVariable->frame();
262  Data->plotOn(sep_varFrame);
263  ModelPDF->plotOn(sep_varFrame);
264  BackgroundPDF->plotOn(sep_varFrame);
265  sep_varFrame->Write();
266  } else
267  cerr << "ERROR: saveResults, did not save RooPlot of data and fit\n";
268  output.Write();
269 }

References beam_dqm_sourceclient-live_cfg::cerr, BTVHLTOfflineSource_cfi::dirname, mps_fire::i, crabWrapper::key, getGTfromDQMFile::obj, DeadROCCounter_Phase1::outname, convertSQLitetoXML_cfg::output, and stringify().

◆ setDataSet()

void SideBandSubtract::setDataSet ( RooDataSet *  newData)

Definition at line 270 of file SideBandSubtraction.cc.

270  {
271  if (newData != nullptr)
272  Data = newData;
273 }

Member Data Documentation

◆ BackgroundPDF

RooAbsPdf* SideBandSubtract::BackgroundPDF
private

Definition at line 23 of file SideBandSubtraction.h.

Referenced by doGlobalFit().

◆ base_histo

TH1F* SideBandSubtract::base_histo
private

Definition at line 34 of file SideBandSubtraction.h.

◆ BaseHistos

std::vector<TH1F*> SideBandSubtract::BaseHistos
private

Definition at line 33 of file SideBandSubtraction.h.

Referenced by doGlobalFit(), and getBaseHistos().

◆ Data

RooDataSet* SideBandSubtract::Data
private

Definition at line 25 of file SideBandSubtraction.h.

Referenced by doGlobalFit().

◆ fit_result

RooFitResult* SideBandSubtract::fit_result
private

Definition at line 35 of file SideBandSubtraction.h.

Referenced by doGlobalFit(), and getFitResult().

◆ ModelPDF

RooAbsPdf* SideBandSubtract::ModelPDF
private

Definition at line 24 of file SideBandSubtraction.h.

Referenced by doGlobalFit().

◆ RawHistos

std::vector<TH1F> SideBandSubtract::RawHistos
private

Definition at line 31 of file SideBandSubtraction.h.

Referenced by getRawHistos(), and resetSBSProducts().

◆ SBSHistos

std::vector<TH1F> SideBandSubtract::SBSHistos
private

Definition at line 32 of file SideBandSubtraction.h.

Referenced by getSBSHistos(), and resetSBSProducts().

◆ SeparationVariable

RooRealVar* SideBandSubtract::SeparationVariable
private

Definition at line 26 of file SideBandSubtraction.h.

Referenced by addSideBandRegion(), addSignalRegion(), and doGlobalFit().

◆ SideBandHistos

std::vector<TH1F> SideBandSubtract::SideBandHistos
private

Definition at line 30 of file SideBandSubtraction.h.

Referenced by resetSBSProducts().

◆ SideBandRegions

std::vector<SbsRegion> SideBandSubtract::SideBandRegions
private

Definition at line 29 of file SideBandSubtraction.h.

Referenced by addSideBandRegion(), and doGlobalFit().

◆ SignalRegions

std::vector<SbsRegion> SideBandSubtract::SignalRegions
private

Definition at line 28 of file SideBandSubtraction.h.

Referenced by addSignalRegion(), and doGlobalFit().

◆ SignalSidebandRatio

Double_t SideBandSubtract::SignalSidebandRatio
private

Definition at line 36 of file SideBandSubtraction.h.

Referenced by doGlobalFit(), and getSTSRatio().

◆ verbose

bool SideBandSubtract::verbose
private

Definition at line 27 of file SideBandSubtraction.h.

Referenced by doGlobalFit().

DeadROCCounter_Phase1.outname
outname
Definition: DeadROCCounter_Phase1.py:127
mps_fire.i
i
Definition: mps_fire.py:355
SideBandSubtract::SideBandRegions
std::vector< SbsRegion > SideBandRegions
Definition: SideBandSubtraction.h:29
SbsRegion::min
Double_t min
Definition: SideBandSubtraction.h:14
Range
PixelRecoRange< float > Range
Definition: PixelTripletHLTGenerator.cc:31
SideBandSubtract::Data
RooDataSet * Data
Definition: SideBandSubtraction.h:25
SideBandSubtract::ModelPDF
RooAbsPdf * ModelPDF
Definition: SideBandSubtraction.h:24
convertSQLitetoXML_cfg.output
output
Definition: convertSQLitetoXML_cfg.py:32
min
T min(T a, T b)
Definition: MathUtil.h:58
testProducerWithPsetDescEmpty_cfi.x2
x2
Definition: testProducerWithPsetDescEmpty_cfi.py:28
SbsRegion::max
Double_t max
Definition: SideBandSubtraction.h:15
gather_cfg.cout
cout
Definition: gather_cfg.py:144
ExhumeParameters_cfi.PDF
PDF
Definition: ExhumeParameters_cfi.py:8
tools.TF1
TF1
Definition: tools.py:23
print_histo
static void print_histo(TH1F *plot, string outname)
Definition: SideBandSubtraction.cc:143
SideBandSubtract::SignalRegions
std::vector< SbsRegion > SignalRegions
Definition: SideBandSubtraction.h:28
SideBandSubtract::BaseHistos
std::vector< TH1F * > BaseHistos
Definition: SideBandSubtraction.h:33
trigObjTnPSource_cfi.var
var
Definition: trigObjTnPSource_cfi.py:21
SideBandSubtract::resetSBSProducts
void resetSBSProducts()
Definition: SideBandSubtraction.cc:492
SideBandSubtract::verbose
bool verbose
Definition: SideBandSubtraction.h:27
BTVHLTOfflineSource_cfi.dirname
dirname
Definition: BTVHLTOfflineSource_cfi.py:7
EcalTangentSkim_cfg.Verbose
Verbose
Definition: EcalTangentSkim_cfg.py:24
testProducerWithPsetDescEmpty_cfi.x1
x1
Definition: testProducerWithPsetDescEmpty_cfi.py:33
testProducerWithPsetDescEmpty_cfi.y1
y1
Definition: testProducerWithPsetDescEmpty_cfi.py:29
IntegrityTask_cfi.Total
Total
Definition: IntegrityTask_cfi.py:44
SideBandSubtract::RawHistos
std::vector< TH1F > RawHistos
Definition: SideBandSubtraction.h:31
eeNoiseFilter_cfi.Intercept
Intercept
Definition: eeNoiseFilter_cfi.py:9
stringify
std::string stringify(const T &t)
Definition: SideBandSubtraction.cc:45
corrVsCorr.filename
filename
Definition: corrVsCorr.py:123
getGTfromDQMFile.obj
obj
Definition: getGTfromDQMFile.py:32
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
SbsRegion
Definition: SideBandSubtraction.h:13
testProducerWithPsetDescEmpty_cfi.y2
y2
Definition: testProducerWithPsetDescEmpty_cfi.py:30
SideBandSubtract::getYield
Double_t getYield(const std::vector< SbsRegion > &Regions, RooAbsPdf *PDF)
Definition: SideBandSubtraction.cc:51
SiStripPI::max
Definition: SiStripPayloadInspectorHelper.h:169
beam_dqm_sourceclient-live_cfg.cerr
cerr
Definition: beam_dqm_sourceclient-live_cfg.py:17
SideBandSubtract::base_histo
TH1F * base_histo
Definition: SideBandSubtraction.h:34
SideBandSubtract::BackgroundPDF
RooAbsPdf * BackgroundPDF
Definition: SideBandSubtraction.h:23
SbsRegion::RegionName
std::string RegionName
Definition: SideBandSubtraction.h:16
value
Definition: value.py:1
SideBandSubtract::SideBandHistos
std::vector< TH1F > SideBandHistos
Definition: SideBandSubtraction.h:30
eeNoiseFilter_cfi.Slope
Slope
Definition: eeNoiseFilter_cfi.py:8
SideBandSubtract::fit_result
RooFitResult * fit_result
Definition: SideBandSubtraction.h:35
SideBandSubtract::SignalSidebandRatio
Double_t SignalSidebandRatio
Definition: SideBandSubtraction.h:36
taus_updatedMVAIds_cff.variable
variable
Definition: taus_updatedMVAIds_cff.py:32
SideBandSubtract::SBSHistos
std::vector< TH1F > SBSHistos
Definition: SideBandSubtraction.h:32
setHistOptions
static void setHistOptions(TH1F *histo, string name, string title, string axis_label)
Definition: SideBandSubtraction.cc:68
SideBandSubtract::doSubtraction
int doSubtraction(RooRealVar *variable, Double_t stsratio, Int_t index)
Definition: SideBandSubtraction.cc:77
data
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:79
AlignmentPI::index
index
Definition: AlignmentPayloadInspectorHelper.h:46
MillePedeFileConverter_cfg.out
out
Definition: MillePedeFileConverter_cfg.py:31
dqmiolumiharvest.j
j
Definition: dqmiolumiharvest.py:66
spclusmultinvestigator_cfi.binMax
binMax
Definition: spclusmultinvestigator_cfi.py:11
crabWrapper.key
key
Definition: crabWrapper.py:19
newFWLiteAna.base
base
Definition: newFWLiteAna.py:92
geometryCSVtoXML.xx
xx
Definition: geometryCSVtoXML.py:19
SideBandSubtract::SeparationVariable
RooRealVar * SeparationVariable
Definition: SideBandSubtraction.h:26
SiPixelRawToDigiRegional_cfi.Regions
Regions
Definition: SiPixelRawToDigiRegional_cfi.py:7
ZMuMuAnalysisNtupler_cff.prefix
prefix
Definition: ZMuMuAnalysisNtupler_cff.py:14