82 return clone(newname && newname[0] !=
'\0' ? newname :
nullptr);
342 virtual void printName(std::ostream& os)
const ;
343 virtual void printTitle(std::ostream& os)
const ;
346 virtual void printArgs(std::ostream& os)
const ;
534 void graphVizTree(
const char* fileName,
const char* delimiter=
"\n",
bool useTitle=
false,
bool useLatex=
false) ;
535 void graphVizTree(std::ostream& os,
const char* delimiter=
"\n",
bool useTitle=
false,
bool useLatex=
false) ;
558 template<
typename... Args_t>
761 static std::map<RooAbsArg*,std::unique_ptr<TRefArray>> _ioEvoList;
763 static std::stack<RooAbsArg*> _ioReadStack ;
#define R__SUGGEST_ALTERNATIVE(ALTERNATIVE)
std::istream & operator>>(std::istream &is, RooAbsArg &arg)
Istream operator.
#define ClassDef(name, id)
TBuffer & operator<<(TBuffer &buf, const Tmpl *obj)
static void indent(ostringstream &buf, int indent_level)
RooAbsArg is the common abstract base class for objects that represent a value and a "shape" in RooFi...
RooExpensiveObjectCache & expensiveObjectCache() const
virtual Bool_t IsSortable() const
virtual Bool_t checkObservables(const RooArgSet *nset) const
Overloadable function in which derived classes can implement consistency checks of the variables.
virtual RooAbsArg * cloneTree(const char *newname=0) const
Clone tree expression of objects.
RooArgSet * getObservables(const RooArgSet &set, Bool_t valueOnly=kTRUE) const
Given a set of possible observables, return the observables that this PDF depends on.
virtual bool isIdentical(const RooAbsArg &other, Bool_t assumeSameType=kFALSE) const =0
void clearValueAndShapeDirty() const
virtual Bool_t readFromStream(std::istream &is, Bool_t compact, Bool_t verbose=kFALSE)=0
virtual Bool_t isValid() const
WVE (08/21/01) Probably obsolete now.
virtual Bool_t importWorkspaceHook(RooWorkspace &ws)
static void verboseDirty(Bool_t flag)
Activate verbose messaging related to dirty flag propagation.
void attachToStore(RooAbsDataStore &store)
Attach this argument to the data store such that it reads data from there.
virtual Int_t defaultPrintContents(Option_t *opt) const
Define default contents to print.
const TNamed * namePtr() const
De-duplicated pointer to this object's name.
const char * aggregateCacheUniqueSuffix() const
Bool_t redirectServers(const RooAbsCollection &newServerList, Bool_t mustReplaceAll=kFALSE, Bool_t nameChange=kFALSE, Bool_t isRecursionStep=kFALSE)
Replace all direct servers of this object with the new servers in newServerList.
virtual Bool_t isLValue() const
Is this argument an l-value, i.e., can it appear on the left-hand side of an assignment expression?...
void changeServer(RooAbsArg &server, Bool_t valueProp, Bool_t shapeProp)
Change dirty flag propagation mask for specified server.
Bool_t isValueServer(const RooAbsArg &arg) const
Check if this is serving values to arg.
virtual void getObservablesHook(const RooArgSet *, RooArgSet *) const
ProxyListCache _proxyListCache
RooWorkspace * _myws
Prevent 'AlwaysDirty' mode for this node.
void printCompactTree(const char *indent="", const char *fileName=0, const char *namePat=0, RooAbsArg *client=0)
Print tree structure of expression tree on stdout, or to file if filename is specified.
void attachDataStore(const RooAbsDataStore &set)
Replace server nodes with names matching the dataset variable names with those data set variables,...
bool addOwnedComponents(std::unique_ptr< Args_t >... comps)
virtual bool operator==(const RooAbsArg &other) const =0
virtual void printClassName(std::ostream &os) const
Print object class name.
RooArgSet * _ownedComponents
void setShapeDirty()
Notify that a shape-like property (e.g. binning) has changed.
virtual bool isCategory() const
Bool_t dependsOn(const RooAbsCollection &serverList, const RooAbsArg *ignoreArg=0, Bool_t valueOnly=kFALSE) const
Test whether we depend on (ie, are served by) any object in the specified collection.
virtual void setCachedValue(double, bool=true)
Overwrite the current value stored in this object, making it look like this object computed that valu...
void setDataToken(std::size_t index)
Sets the token for retrieving results in the BatchMode. For internal use only.
void registerProxy(RooArgProxy &proxy)
Register an RooArgProxy in the proxy list.
Bool_t checkDependents(const RooArgSet *nset) const
friend std::ostream & operator<<(std::ostream &os, const RooAbsArg &arg)
Ostream operator.
RooFIter valueClientMIterator() const
void attachArgs(const RooAbsCollection &set)
Bind this node to objects in set.
Bool_t isShapeServer(const RooAbsArg &arg) const
Check if this is serving shape to arg.
RooArgSet * getDependents(const RooArgSet &set) const
void setStringAttribute(const Text_t *key, const Text_t *value)
Associate string 'value' to this object under key 'key'.
friend class RooObjectFactory
static void ioStreamerPass2Finalize()
Method called by workspace container to finalize schema evolution issues that cannot be handled in a ...
RooArgSet * getDependents(const RooAbsData *set) const
virtual CacheMode canNodeBeCached() const
void leafNodeServerList(RooAbsCollection *list, const RooAbsArg *arg=0, Bool_t recurseNonDerived=kFALSE) const
Fill supplied list with all leaf nodes of the arg tree, starting with ourself as top node.
virtual void setTreeBranchStatus(TTree &t, Bool_t active)=0
void setProhibitServerRedirect(Bool_t flag)
void setWorkspace(RooWorkspace &ws)
virtual void printMultiline(std::ostream &os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const
Implement multi-line detailed printing.
friend class RooAddPdfOrig
virtual TObject * Clone(const char *newname=0) const
Make a clone of an object using the Streamer facility.
void addParameters(RooAbsCollection ¶ms, const RooArgSet *nset=nullptr, bool stripDisconnected=true) const
Add all parameters of the function and its daughters to params.
const RooArgSet * ownedComponents() const
Bool_t isCloneOf(const RooAbsArg &other) const
Check if this object was created as a clone of 'other'.
Bool_t isShapeDirty() const
virtual void copyCache(const RooAbsArg *source, Bool_t valueOnly=kFALSE, Bool_t setValDirty=kTRUE)=0
static void setDirtyInhibit(Bool_t flag)
Control global dirty inhibit mode.
Bool_t findConstantNodes(const RooArgSet &observables, RooArgSet &cacheList)
Find branch nodes with all-constant parameters, and add them to the list of nodes that can be cached ...
void graphVizAddConnections(std::set< std::pair< RooAbsArg *, RooAbsArg * > > &)
Utility function that inserts all point-to-point client-server connections between any two RooAbsArgs...
void unRegisterProxy(RooArgProxy &proxy)
Remove proxy from proxy list.
virtual bool canComputeBatchWithCuda() const
void printComponentTree(const char *indent="", const char *namePat=0, Int_t nLevel=999)
Print tree structure of expression tree on given ostream, only branch nodes are printed.
const RefCountList_t & shapeClients() const
List of all shape clients of this object.
Bool_t inhibitDirty() const
Delete watch flag.
RooSTLRefCountList< RooAbsArg > RefCountList_t
const RefCountList_t & valueClients() const
List of all value clients of this object. Value clients receive value updates.
friend std::istream & operator>>(std::istream &is, RooAbsArg &arg)
Istream operator.
RooArgSet * getObservables(const RooAbsData &data) const
Return the observables of this pdf given the observables defined by data.
virtual void setExpensiveObjectCache(RooExpensiveObjectCache &cache)
std::set< std::string > _boolAttrib
void addServer(RooAbsArg &server, Bool_t valueProp=kTRUE, Bool_t shapeProp=kFALSE, std::size_t refCount=1)
Register another RooAbsArg as a server to us, ie, declare that we depend on it.
virtual void printTree(std::ostream &os, TString indent="") const
Print object tree structure.
void unRegisterCache(RooAbsCache &cache)
Unregister a RooAbsCache. Called from the RooAbsCache destructor.
virtual Bool_t isFundamental() const
Is this object a fundamental type that can be added to a dataset? Fundamental-type subclasses overrid...
virtual void printTitle(std::ostream &os) const
Print object title.
Bool_t isValueOrShapeDirtyAndClear() const
RefCountList_t _clientListValue
bool addOwnedComponents(const RooAbsCollection &comps)
Take ownership of the contents of 'comps'.
void printAttribList(std::ostream &os) const
Transient boolean attributes (not copied in ctor)
Bool_t dependentOverlaps(const RooAbsData *dset, const RooAbsArg &testArg) const
virtual void Print(Option_t *options=0) const
Print the object to the defaultPrintStream().
friend void RooRefArray::Streamer(TBuffer &)
const Text_t * getStringAttribute(const Text_t *key) const
Get string attribute mapped under key 'key'.
void treeNodeServerList(RooAbsCollection *list, const RooAbsArg *arg=0, Bool_t doBranch=kTRUE, Bool_t doLeaf=kTRUE, Bool_t valueOnly=kFALSE, Bool_t recurseNonDerived=kFALSE) const
Fill supplied list with nodes of the arg tree, following all server links, starting with ourself as t...
void setAttribute(const Text_t *name, Bool_t value=kTRUE)
Set (default) or clear a named boolean attribute of this object.
virtual void writeToStream(std::ostream &os, Bool_t compact) const =0
RooArgSet * getParameters(const RooArgSet &observables, bool stripDisconnected=true) const
Return the parameters of the p.d.f given the provided set of observables.
Bool_t hasClients() const
virtual void printAddress(std::ostream &os) const
Print class name of object.
RooArgSet * getParameters(const RooAbsData &data, bool stripDisconnected=true) const
Return the parameters of this p.d.f when used in conjuction with dataset 'data'.
RooFIter serverMIterator() const
void setTransientAttribute(const Text_t *name, Bool_t value=kTRUE)
Set (default) or clear a named boolean attribute of this object.
virtual void serverNameChangeHook(const RooAbsArg *, const RooAbsArg *)
virtual void printCompactTreeHook(std::ostream &os, const char *ind="")
Hook function interface for object to insert additional information when printed in the context of a ...
virtual void setCacheAndTrackHints(RooArgSet &)
const std::set< std::string > & attributes() const
Bool_t _isConstant
De-duplicated name pointer. This will be equal for all objects with the same name.
Bool_t isValueDirty() const
Bool_t overlaps(const RooAbsArg &testArg, Bool_t valueOnly=kFALSE) const
Test if any of the nodes of tree are shared with that of the given tree.
Int_t Compare(const TObject *other) const
Utility function used by TCollection::Sort to compare contained TObjects We implement comparison by n...
RooArgSet * getVariables(Bool_t stripDisconnected=kTRUE) const
Return RooArgSet with all variables (tree leaf nodes of expresssion tree)
void clearValueDirty() const
virtual void ioStreamerPass2()
Method called by workspace container to finalize schema evolution issues that cannot be handled in a ...
virtual ~RooAbsArg()
Destructor.
virtual Bool_t isDerived() const
Does value or shape of this arg depend on any other arg?
static Bool_t _inhibitDirty
virtual const char * cacheUniqueSuffix() const
RefCountListLegacyIterator_t * makeLegacyIterator(const RefCountList_t &list) const
const RefCountList_t & servers() const
List of all servers of this object.
std::size_t _dataToken
In which workspace do I live, if any.
TIterator * valueClientIterator() const
Bool_t _localNoInhibitDirty
Cached isConstant status.
virtual void constOptimizeTestStatistic(ConstOpCode opcode, Bool_t doAlsoTrackingOpt=kTRUE)
Interface function signaling a request to perform constant term optimization.
void setOperMode(OperMode mode, Bool_t recurseADirty=kTRUE)
Set the operation mode of this node.
virtual void attachToTree(TTree &t, Int_t bufSize=32000)=0
Overloadable function for derived classes to implement attachment as branch to a TTree.
virtual bool isReducerNode() const
RooLinkedList getCloningAncestors() const
Return ancestors in cloning chain of this RooAbsArg.
void setValueDirty()
Mark the element dirty. This forces a re-evaluation when a value is requested.
RooAbsArg * findServer(const RooAbsArg &arg) const
Return server of this that has the same name as arg. Returns nullptr if not found.
Bool_t recursiveCheckObservables(const RooArgSet *nset) const
Recursively call checkObservables on all nodes in the expression tree.
const std::map< std::string, std::string > & stringAttributes() const
RooAbsCache * getCache(Int_t index) const
Return registered cache object by index.
virtual void syncCache(const RooArgSet *nset=0)=0
void printDirty(Bool_t depth=kTRUE) const
Print information about current value dirty state information.
static Bool_t _verboseDirty
cache of the list of proxies. Avoids type casting.
void registerCache(RooAbsCache &cache)
Register RooAbsCache with this object.
virtual void optimizeCacheMode(const RooArgSet &observables)
Activate cache mode optimization with given definition of observables.
RefCountList_t _clientListShape
virtual void attachToVStore(RooVectorDataStore &vstore)=0
TString cleanBranchName() const
Construct a mangled name from the actual name that is free of any math symbols that might be interpre...
void SetNameTitle(const char *name, const char *title)
Set all the TNamed parameters (name and title).
Bool_t recursiveCheckDependents(const RooArgSet *nset) const
Bool_t _prohibitServerRedirect
Set of owned component.
RooAbsArg * findServer(Int_t index) const
Return i-th server from server list.
void removeServer(RooAbsArg &server, Bool_t force=kFALSE)
Unregister another RooAbsArg as a server to us, ie, declare that we no longer depend on its value and...
Int_t numProxies() const
Return the number of registered proxies.
Bool_t getAttribute(const Text_t *name) const
Check if a named attribute is set. By default, all attributes are unset.
virtual void printName(std::ostream &os) const
Print object name.
void replaceServer(RooAbsArg &oldServer, RooAbsArg &newServer, Bool_t valueProp, Bool_t shapeProp)
Replace 'oldServer' with 'newServer'.
const std::set< std::string > & transientAttributes() const
const RefCountList_t & clients() const
List of all clients of this object.
RooArgSet * getDependents(const RooArgSet *depList) const
virtual void getParametersHook(const RooArgSet *, RooArgSet *, Bool_t) const
virtual void printMetaArgs(std::ostream &) const
Bool_t isShapeServer(const char *name) const
Check if this is serving shape to an object with name name.
void addServerList(RooAbsCollection &serverList, Bool_t valueProp=kTRUE, Bool_t shapeProp=kFALSE)
Register a list of RooAbsArg as servers to us by calling addServer() for each arg in the list.
virtual void applyWeightSquared(bool flag)
Disables or enables the usage of squared weights.
Bool_t dependsOnValue(const RooAbsCollection &serverList, const RooAbsArg *ignoreArg=0) const
Check whether this object depends on values from an element in the serverList.
TIterator * shapeClientIterator() const
void setProxyNormSet(const RooArgSet *nset)
Forward a change in the cached normalization argset to all the registered proxies.
std::size_t dataToken() const
Returns the token for retrieving results in the BatchMode. For internal use only.
RefCountList_t _clientList
Bool_t dependsOnValue(const RooAbsArg &server, const RooAbsArg *ignoreArg=0) const
Check whether this object depends on values served from the object passed as server.
RooAbsProxy * getProxy(Int_t index) const
Return the nth proxy from the proxy list.
RooFIter shapeClientMIterator() const
RooAbsArg & operator=(const RooAbsArg &other)
Assign all boolean and string properties of the original object.
virtual bool redirectServersHook(const RooAbsCollection &, bool, bool, bool)
Function that is called at the end of redirectServers().
Bool_t isValueDirtyAndClear() const
Bool_t dependentOverlaps(const RooArgSet *depList, const RooAbsArg &testArg) const
RefCountList_t _serverList
void clearShapeDirty() const
virtual RooAbsArg * createFundamental(const char *newname=0) const =0
Create a fundamental-type object that stores our type of value.
RooExpensiveObjectCache * _eocache
Prohibit server redirects – Debugging tool.
RooArgSet * getComponents() const
Create a RooArgSet with all components (branch nodes) of the expression tree headed by this object.
std::set< std::string > _boolAttribTransient
void setLocalNoDirtyInhibit(Bool_t flag) const
RooArgSet * getParameters(const RooAbsData *data, bool stripDisconnected=true) const
Create a list of leaf nodes in the arg tree starting with ourself as top node that don't match any of...
RooAbsArg * findNewServer(const RooAbsCollection &newSet, Bool_t nameChange) const
Find the new server in the specified set that matches the old server.
Bool_t isConstant() const
Check if the "Constant" attribute is set.
virtual void fillTreeBranch(TTree &t)=0
void branchNodeServerList(RooAbsCollection *list, const RooAbsArg *arg=0, Bool_t recurseNonDerived=kFALSE) const
Fill supplied list with all branch nodes of the arg tree starting with ourself as top node.
std::size_t getParametersSizeEstimate(const RooArgSet *nset=nullptr) const
Obtain an estimate of the number of parameters of the function and its daughters.
void graphVizTree(const char *fileName, const char *delimiter="\n", bool useTitle=false, bool useLatex=false)
Create a GraphViz .dot file visualizing the expression tree headed by this RooAbsArg object.
virtual void operModeHook()
TIterator * clientIterator() const
Retrieve a client iterator.
virtual void optimizeDirtyHook(const RooArgSet *)
Bool_t getTransientAttribute(const Text_t *name) const
Check if a named attribute is set.
TIterator * serverIterator() const
std::map< std::string, std::string > _stringAttrib
virtual Bool_t inRange(const char *) const
Int_t numCaches() const
Return number of registered caches.
RooAbsArg()
Default constructor.
virtual std::unique_ptr< RooArgSet > fillNormSetForServer(RooArgSet const &normSet, RooAbsArg const &server) const
Fills a RooArgSet to be used as the normalization set for a server, given a normalization set for thi...
Bool_t recursiveRedirectServers(const RooAbsCollection &newServerList, Bool_t mustReplaceAll=kFALSE, Bool_t nameChange=kFALSE, Bool_t recurseInNewSet=kTRUE)
Recursively replace all servers with the new servers in newSet.
Bool_t isValueServer(const char *name) const
Check if this is serving values to an object with name name.
void attachDataSet(const RooAbsData &set)
Replace server nodes with names matching the dataset variable names with those data set variables,...
virtual Bool_t hasRange(const char *) const
virtual TObject * clone(const char *newname=0) const =0
virtual void printArgs(std::ostream &os) const
Print object arguments, ie its proxies.
TIteratorToSTLInterface< RefCountList_t::Container_t > RefCountListLegacyIterator_t
RooAbsArg * findServer(const char *name) const
Return server of this with name name. Returns nullptr if not found.
void SetName(const char *name)
Set the name of the TNamed.
Bool_t localNoDirtyInhibit() const
std::vector< RooAbsCache * > _cacheList
OperMode operMode() const
Query the operation mode of this node.
Bool_t observableOverlaps(const RooAbsData *dset, const RooAbsArg &testArg) const
Test if any of the dependents of the arg tree (as determined by getObservables) overlaps with those o...
RooAbsCache is the abstract base class for data members of RooAbsArgs that cache other (composite) Ro...
RooAbsCollection is an abstract container object that can hold multiple RooAbsArg objects.
RooAbsDataStore is the abstract base class for data collection that use a TTree as internal storage m...
RooAbsData is the common abstract base class for binned and unbinned datasets.
RooAbsProxy is the abstact interface for proxy classes.
RooAbsReal is the common abstract base class for objects that represent a real value and implements f...
RooAddModel is an efficient implementation of a sum of PDFs of the form.
RooAddPdf is an efficient implementation of a sum of PDFs of the form.
RooArgList is a container object that can hold multiple RooAbsArg objects.
RooArgProxy is the abstract interface for RooAbsArg proxy classes.
RooArgSet is a container object that can hold multiple RooAbsArg objects.
RooCompositeDataStore combines several disjunct datasets into one.
RooCustomizer is a factory class to produce clones of a prototype composite PDF object with the same ...
RooDataSet is a container class to hold unbinned data.
RooExpensiveObjectCache is a singleton class that serves as repository for objects that are expensive...
RooExtendPdf is a wrapper around an existing PDF that adds a parameteric extended likelihood term to ...
A one-time forward iterator working on RooLinkedList or RooAbsCollection.
RooFitResult is a container class to hold the input and output of a PDF fit to a dataset.
RooHistFunc implements a real-valued function sampled from a multidimensional histogram.
RooHistPdf implements a probablity density function sampled from a multidimensional histogram.
RooLinkedList is an collection class for internal use, storing a collection of RooAbsArg pointers in ...
RooListProxy is the concrete proxy for RooArgList objects.
RooPlotable is a 'mix-in' base class that define the standard RooFit plotting and printing methods.
virtual StyleOption defaultPrintStyle(Option_t *opt) const
static std::ostream & defaultPrintStream(std::ostream *os=0)
Return a reference to the current default stream to use in Print().
virtual void printStream(std::ostream &os, Int_t contents, StyleOption style, TString indent="") const
Print description of object on ostream, printing contents set by contents integer,...
RooProdPdf is an efficient implementation of a product of PDFs of the form.
Class RooProjectedPdf is a RooAbsPdf implementation that represent a projection of a given input p....
RooRealIntegral performs hybrid numerical/analytical integrals of RooAbsReal objects.
RooRealMPFE is the multi-processor front-end for parallel calculation of RooAbsReal objects.
RooRefArray & operator=(const RooRefArray &other)=default
RooRefArray(const RooRefArray &other)
bool containsSameName(const char *name) const
Check if list contains an item using findByName().
T * findByNamePointer(const T *item) const
Find an item by comparing RooAbsArg::namePtr() adresses.
const Container_t & containedObjects() const
Direct reference to container of objects held by this list.
Container_t::const_iterator end() const
End of contained objects.
bool empty() const
Check if empty.
Container_t::const_iterator findByName(const char *name) const
Find an item by comparing strings returned by RooAbsArg::GetName()
bool containsByNamePtr(const T *obj) const
Check if list contains an item using findByNamePointer().
RooSetProxy is the concrete proxy for RooArgSet objects.
RooTreeDataStore is a TTree-backed data storage.
RooVectorDataStore uses std::vectors to store data columns.
The RooWorkspace is a persistable container for RooFit projects.
Buffer base class used for serializing objects.
TIterator and GenericRooFIter front end with STL back end.
Iterator abstract base class.
The TNamed class is the base class for all named ROOT classes.
Mother of all ROOT objects.
A TTree represents a columnar dataset.
std::vector< RooAbsProxy * > cache