15#ifndef RooFit_RooEvaluatorWrapper_h
16#define RooFit_RooEvaluatorWrapper_h
35class RooEvaluatorWrapper final :
public RooAbsReal {
37 RooEvaluatorWrapper(
RooAbsReal &topNode, std::unique_ptr<RooFit::Evaluator> evaluator, std::string
const &rangeName,
40 RooEvaluatorWrapper(
const RooEvaluatorWrapper &other,
const char *
name =
nullptr);
42 TObject *
clone(
const char *newname)
const override {
return new RooEvaluatorWrapper(*
this, newname); }
44 double defaultErrorLevel()
const override {
return _topNode->defaultErrorLevel(); }
46 bool getParameters(
const RooArgSet *observables,
RooArgSet &outputSet,
bool stripDisconnected)
const override;
52 void applyWeightSquared(
bool flag)
override { _topNode->applyWeightSquared(flag); }
54 void printMultiline(std::ostream &os,
Int_t ,
bool =
false,
57 _evaluator->print(os);
61 void constOptimizeTestStatistic(ConstOpCode ,
bool )
override {}
64 double evaluate()
const override {
return _evaluator ? _evaluator->run()[0] : 0.0; }
67 std::shared_ptr<RooFit::Evaluator> _evaluator;
71 std::string _rangeName;
73 const bool _takeGlobalObservablesFromData;
74 std::stack<std::vector<double>> _vectorBuffers;
TObject * clone(const char *newname) const override
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void data
Common abstract base class for objects that represent a value and a "shape" in RooFit.
A space to attach TBranches.
Abstract base class for binned and unbinned datasets.
Abstract base class for objects that represent a real value and implements functionality common to al...
RooArgSet is a container object that can hold multiple RooAbsArg objects.
Facilitates simultaneous fitting of multiple PDFs to subsets of a given dataset.
Mother of all ROOT objects.
void evaluate(typename Architecture_t::Tensor_t &A, EActivationFunction f)
Apply the given activation function to each value in the given tensor A.