1 #ifndef __GRID_MEDIAN_BACKGROUND_ESTIMATOR_HH__
2 #define __GRID_MEDIAN_BACKGROUND_ESTIMATOR_HH__
35 #include "fastjet/tools/BackgroundEstimatorBase.hh"
41 #define FASTJET_GMBGE_USEFJGRID
43 #ifdef FASTJET_GMBGE_USEFJGRID
44 #include "fastjet/RectangularGrid.hh"
49 FASTJET_BEGIN_NAMESPACE
78 #ifdef FASTJET_GMBGE_USEFJGRID
86 #ifdef FASTJET_GMBGE_USEFJGRID
94 _has_particles(false), _enable_rho_m(true) {}
100 _has_particles(false), _enable_rho_m(true) {
101 if (!RectangularGrid::is_initialised())
102 throw Error(
"attempt to construct GridMedianBackgroundEstimator with uninitialised RectangularGrid");
105 #else // alternative in old framework where we didn't have the rectangular grid
107 _ymin(-ymax), _ymax(ymax),
108 _requested_grid_spacing(requested_grid_spacing),
109 _has_particles(false), _enable_rho_m(true)
113 #endif // FASTJET_GMBGE_USEFJGRID
124 void set_particles(
const std::vector<PseudoJet> & particles);
142 double sigma()
const;
162 double rho_m()
const;
168 double sigma_m()
const;
217 std::string description()
const;
224 #ifndef FASTJET_GMBGE_USEFJGRID
230 int tile_index(
const PseudoJet & p)
const;
233 double _ymin, _ymax, _dy, _dphi, _requested_grid_spacing, _tile_area;
234 int _ny, _nphi, _ntotal;
236 int n_tiles()
const {
return _ntotal;}
237 int n_good_tiles()
const {
return n_tiles();}
238 int tile_is_good(
int )
const {
return true;}
240 double mean_tile_area()
const {
return _tile_area;}
241 #endif // FASTJET_GMBGE_USEFJGRID
245 void verify_particles_set()
const;
249 double _rho, _sigma, _rho_m, _sigma_m;
254 LimitedWarning _warning_rho_of_jet;
255 LimitedWarning _warning_rescaling;
258 FASTJET_END_NAMESPACE
260 #endif // __GRID_MEDIAN_BACKGROUND_ESTIMATOR_HH__
Class that holds a generic rectangular tiling.
base class corresponding to errors that can be thrown by FastJet
Abstract base class that provides the basic interface for classes that estimate levels of background ...
Class to contain pseudojets, including minimal information of use to jet-clustering routines...