31#include <unordered_map>
59 }
else if (
auto binning =
rlv->getBinningPtr(
rangeName)) {
63 return {-std::numeric_limits<double>::infinity(), +std::numeric_limits<double>::infinity()};
72 std::vector<std::pair<double, double>> limits;
76 for (
auto const &obs : observables) {
82 throw std::logic_error(
83 "Classes that represent observables are expected to inherit from RooAbsRealLValue or RooAbsCategory!");
89 auto nObs = limits.size() /
nRanges;
103 (
r1.second >
r2.first &&
r1.first <
r2.second) || (
r2.second >
r1.first &&
r2.first <
r1.second);
105 if (overlaps == nObs)
122 for (
auto const &arg :
tmp) {
140 if (
auto arg = argSet.
find(
name.c_str()))
165 return {
const_cast<RooAbsPdf *
>(&pdf),
true};
172 if (
component->getAttribute(
"MAIN_MEASUREMENT")) {
179 return {
nullptr,
false};
202using ToCloneMap = std::unordered_map<TNamed const *, RooAbsArg const *>;
220 for (
const auto server : var.servers()) {
301 if (std::isdigit(in[0])) {
305 std::transform(out.begin(), out.end(), out.begin(), [](
char c) { return std::isalnum(c) ? c :
'_'; });
312 for (std::string::size_type pos{};
inOut.npos != (pos =
inOut.find(
what.data(), pos,
what.length()));
313 pos +=
with.length()) {
332 cutString << cat->GetName() <<
"==" << cat->getCurrentIndex();
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void input
const_iterator end() const
Common abstract base class for objects that represent a value and a "shape" in RooFit.
const TNamed * namePtr() const
De-duplicated pointer to this object's name.
bool addOwnedComponents(const RooAbsCollection &comps)
Take ownership of the contents of 'comps'.
bool redirectServers(const RooAbsCollection &newServerList, bool mustReplaceAll=false, bool nameChange=false, bool isRecursionStep=false)
Replace all direct servers of this object with the new servers in newServerList.
bool getAttribute(const Text_t *name) const
Check if a named attribute is set. By default, all attributes are unset.
TObject * Clone(const char *newname=nullptr) const override
Make a clone of an object using the Streamer facility.
virtual bool isFundamental() const
Is this object a fundamental type that can be added to a dataset? Fundamental-type subclasses overrid...
void treeNodeServerList(RooAbsCollection *list, const RooAbsArg *arg=nullptr, bool doBranch=true, bool doLeaf=true, bool valueOnly=false, bool recurseNonDerived=false) const
Fill supplied list with nodes of the arg tree, following all server links, starting with ourself as t...
Abstract base class for RooRealVar binning definitions.
virtual bool isParameterized() const
Interface function.
virtual double highBound() const =0
virtual double lowBound() const =0
virtual RooAbsReal * highBoundFunc() const
Return pointer to RooAbsReal parameterized upper bound, if any.
virtual RooAbsReal * lowBoundFunc() const
Return pointer to RooAbsReal parameterized lower bound, if any.
Abstract base class for objects that represent a discrete value that can be set from the outside,...
A space to attach TBranches.
Abstract container object that can hold multiple RooAbsArg objects.
void sortTopologically()
Sort collection topologically: the servers of any RooAbsArg will be before that RooAbsArg in the coll...
virtual bool add(const RooAbsArg &var, bool silent=false)
Add the specified argument to list.
Storage_t::size_type size() const
RooAbsArg * find(const char *name) const
Find object with given name in list.
Abstract interface for all probability density functions.
TClass * IsA() const override
Abstract base class for objects that represent a real value that may appear on the left hand side of ...
RooArgList is a container object that can hold multiple RooAbsArg objects.
RooArgSet is a container object that can hold multiple RooAbsArg objects.
Efficient implementation of a product of PDFs of the form.
Bool_t InheritsFrom(const char *cl) const override
Return kTRUE if this class inherits from a class with name "classname".
const char * GetName() const override
Returns name of object.
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...
std::vector< std::string > Split(std::string_view str, std::string_view delims, bool skipEmpty=false)
Splits a string at each character in delims.
std::string makeValidVarName(std::string const &in)
void replaceAll(std::string &inOut, std::string_view what, std::string_view with)
std::string makeSliceCutString(RooArgSet const &sliceDataSet)
The namespace RooFit contains mostly switches that change the behaviour of functions of PDFs (or othe...
RooAbsArg * cloneTreeWithSameParametersImpl(RooAbsArg const &arg, RooArgSet const *observables)
bool snapshotImpl(RooAbsCollection const &input, RooAbsCollection &output, bool deepCopy, RooArgSet const *observables)
RooArgSet selectFromArgSet(RooArgSet const &, std::string const &names)
bool checkIfRangesOverlap(RooArgSet const &observables, std::vector< std::string > const &rangeNames)
std::string getRangeNameForSimComponent(std::string const &rangeName, bool splitRange, std::string const &catName)
void getSortedComputationGraph(RooAbsArg const &func, RooArgSet &out)
BinnedLOutput getBinnedL(RooAbsPdf const &pdf)
std::string getColonSeparatedNameString(RooArgSet const &argSet, char delim=':')
std::pair< double, double > getRangeOrBinningInterval(RooAbsArg const *arg, const char *rangeName)