 |
Belle II Software
release-05-02-19
|
12 #ifndef INCLUDE_GUARD_BELLE2_MVA_SPLOT_HEADER
13 #define INCLUDE_GUARD_BELLE2_MVA_SPLOT_HEADER
15 #include <mva/interface/Dataset.h>
16 #include <mva/utility/Binning.h>
17 #include <mva/interface/Expert.h>
75 for (
unsigned int iEvent = 0; iEvent < weights.size(); ++iEvent) {
95 virtual void loadEvent(
unsigned int event)
override;
149 virtual void loadEvent(
unsigned int event)
override;
194 virtual void loadEvent(
unsigned int event)
override;
212 std::vector<float> getSPlotWeights(
Dataset& dataset,
Binning& binning);
219 std::vector<float> getBoostWeights(
Dataset& dataset,
Binning& binning);
227 std::vector<float> getAPlotWeights(
Dataset& dataset,
Binning& binning,
const std::vector<float>& boost_prediction);
SPlotDataset(const GeneralOptions &general_options, Dataset &dataset, const std::vector< float > &weights, float signalFraction)
Constructs a new SPlotDataset.
virtual void loadEvent(unsigned int event) override
Load the event number iEvent.
virtual unsigned int getNumberOfFeatures() const override
Returns the number of features in this dataset.
virtual std::vector< float > getWeights() override
Returns all weights.
Abstract base class of all Datasets given to the MVA interface The current event can always be access...
virtual unsigned int getNumberOfSpectators() const override
Returns the number of features in this dataset.
virtual unsigned int getNumberOfFeatures() const =0
Returns the number of features in this dataset.
virtual unsigned int getNumberOfFeatures() const override
Returns the number of features in this dataset.
virtual std::vector< float > getFeature(unsigned int iFeature)
Returns all values of one feature in a std::vector<float>
virtual unsigned int getNumberOfEvents() const override
Returns the number of events in this dataset.
virtual std::vector< float > getSpectator(unsigned int iSpectator) override
Returns all values of one spectator in a std::vector<float>
virtual std::vector< float > getSpectator(unsigned int iSpectator)
Returns all values of one spectator in a std::vector<float>
Dataset for sPlot Wraps a dataset and provides each data-point twice, once as signal and once as back...
std::vector< float > m_weights
sPlot weights
virtual std::vector< float > getWeights()
Returns all weights.
int m_spectator_index
spectator containing the sideband variable
Dataset & m_dataset
Wrapped dataset.
virtual unsigned int getNumberOfFeatures() const override
Returns the number of features in this dataset.
virtual unsigned int getNumberOfSpectators() const =0
Returns the number of spectators in this dataset.
virtual void loadEvent(unsigned int event) override
Load the event number iEvent.
virtual void loadEvent(unsigned int event) override
Load the event number iEvent.
virtual std::vector< bool > getSignals()
Returns all is Signals.
Dataset & m_dataset
Wrapped dataset.
SidebandDataset(const GeneralOptions &general_options, Dataset &dataset, Dataset &mc_dataset, const std::string &sideband_variable)
Constructs a new SidebandDataset.
virtual float getSignalFraction() override
Returns the signal fraction of the whole sample.
virtual unsigned int getNumberOfEvents() const override
Returns the number of events in this dataset.
Dataset for Sideband Substraction Wraps a dataset and provides each data-point with a new weight.
Abstract base class for different kinds of events.
virtual unsigned int getNumberOfSpectators() const override
Returns the number of features in this dataset.
double m_background_weight
the weight for background events
virtual std::vector< float > getFeature(unsigned int iFeature) override
Returns all values of one feature in a std::vector<float>
ReweightingDataset(const GeneralOptions &general_options, Dataset &dataset, const std::vector< float > &weights)
Constructs a new ReweightingDataset.
Dataset for Reweighting Wraps a dataset and provides each data-point with a new weight.
General options which are shared by all MVA trainings.
double m_negative_signal_weight
the weight for negative signal events
virtual std::vector< bool > getSignals() override
Returns all is Signals.
virtual std::vector< float > getSpectator(unsigned int iSpectator) override
Returns all values of one spectator in a std::vector<float>
std::vector< float > m_weights
sPlot weights
virtual std::vector< float > getFeature(unsigned int iFeature) override
Returns all values of one feature in a std::vector<float>
virtual unsigned int getNumberOfEvents() const override
Returns the number of events in this dataset.
virtual std::vector< float > getTargets()
Returns all targets.
Binning of a data distribution Provides PDF and CDF values of the distribution per bin.
virtual unsigned int getNumberOfSpectators() const override
Returns the number of features in this dataset.
virtual unsigned int getNumberOfEvents() const =0
Returns the number of events in this dataset.
float m_signalFraction
Signal fraction.
virtual std::vector< float > getTargets() override
Returns all targets.
double m_signal_weight
the weight for signal events
Dataset & m_dataset
Wrapped dataset.