ROOT
6.07/01
Reference Guide
|
Template class RooCacheManager manages the storage of any type of data indexed on the choice of normalization and optionally the set of integrated observables.
The purpose of this class is to faciliate storage of intermediate results in operator p.d.f.s whose value and inner working are often highly dependent on the user provided choice of normalization in getVal().
For efficiency reasons these normalization set pointer are derefenced as little as possible. This class contains a lookup table for RooArgSet pointer pairs -> normalization lists. Distinct pointer pairs that represent the same normalization/projection are recognized and will all point to the same normalization list. Lists for up to 'maxSize' different normalization/ projection configurations can be cached.
Definition at line 35 of file RooCacheManager.h.
Public Member Functions | |
RooCacheManager (Int_t maxSize=2) | |
RooCacheManager (RooAbsArg *owner, Int_t maxSize=2) | |
RooCacheManager (const RooCacheManager &other, RooAbsArg *owner=0) | |
virtual | ~RooCacheManager () |
T * | getObj (const RooArgSet *nset, Int_t *sterileIndex=0, const TNamed *isetRangeName=0) |
Int_t | setObj (const RooArgSet *nset, T *obj, const TNamed *isetRangeName=0) |
T * | getObj (const RooArgSet *nset, const RooArgSet *iset, Int_t *sterileIdx, const char *isetRangeName) |
T * | getObj (const RooArgSet *nset, const RooArgSet *iset, Int_t *sterileIndex=0, const TNamed *isetRangeName=0) |
Int_t | setObj (const RooArgSet *nset, const RooArgSet *iset, T *obj, const TNamed *isetRangeName=0) |
void | reset () |
virtual void | sterilize () |
Int_t | lastIndex () const |
Int_t | cacheSize () const |
virtual Bool_t | redirectServersHook (const RooAbsCollection &, Bool_t, Bool_t, Bool_t) |
Interface for server redirect calls. More... | |
virtual void | operModeHook () |
Interface for operation mode changes. More... | |
virtual void | printCompactTreeHook (std::ostream &, const char *) |
Interface for printing of cache guts in tree mode printing. More... | |
T * | getObjByIndex (Int_t index) const |
const RooNameSet * | nameSet1ByIndex (Int_t index) const |
const RooNameSet * | nameSet2ByIndex (Int_t index) const |
virtual void | insertObjectHook (T &) |
void | wireCache () |
Public Member Functions inherited from RooAbsCache | |
RooAbsCache (RooAbsArg *owner=0) | |
Constructor. Takes owner as argument and register cache with owner. More... | |
RooAbsCache (const RooAbsCache &, RooAbsArg *owner=0) | |
Copy constructor. Takes owner as argument and registers cache with owne. More... | |
virtual void | optimizeCacheMode (const RooArgSet &, RooArgSet &, RooLinkedList &) |
Interface for processing of cache mode optimization calls. More... | |
virtual void | findConstantNodes (const RooArgSet &, RooArgSet &, RooLinkedList &) |
Interface for constant term node finding calls. More... | |
virtual | ~RooAbsCache () |
Destructor. Unregisters cache with owner. More... | |
Protected Attributes | |
Int_t | _maxSize |
Int_t | _size |
Maximum size. More... | |
Int_t | _lastIndex |
Actual use. More... | |
std::vector< RooNormSetCache > | _nsetCache |
Last slot accessed. More... | |
std::vector< T * > | _object |
Normalization/Integration set manager. More... | |
Bool_t | _wired |
Payload. More... | |
Protected Attributes inherited from RooAbsCache | |
RooAbsArg * | _owner |
#include <RooCacheManager.h>
RooCacheManager< T >::RooCacheManager | ( | Int_t | maxSize = 2 | ) |
Definition at line 120 of file RooCacheManager.h.
RooCacheManager< T >::RooCacheManager | ( | RooAbsArg * | owner, |
Int_t | maxSize = 2 |
||
) |
Definition at line 134 of file RooCacheManager.h.
RooCacheManager< T >::RooCacheManager | ( | const RooCacheManager< T > & | other, |
RooAbsArg * | owner = 0 |
||
) |
Definition at line 158 of file RooCacheManager.h.
|
virtual |
Definition at line 185 of file RooCacheManager.h.
|
inline |
Definition at line 69 of file RooCacheManager.h.
Referenced by RooAbsCachedReal::setInterpolationOrder(), and RooAbsCachedPdf::setInterpolationOrder().
|
inline |
Definition at line 44 of file RooCacheManager.h.
Referenced by RooProdPdf::analyticalIntegralWN(), RooDataHist::calculatePartialBinVolume(), RooProdPdf::evaluate(), RooAddition::getAnalyticalIntegral(), RooEffProd::getAnalyticalIntegralWN(), RooRealSumPdf::getAnalyticalIntegralWN(), PiecewiseInterpolation::getAnalyticalIntegralWN(), ParamHistFunc::getAnalyticalIntegralWN(), RooSimultaneous::getAnalyticalIntegralWN(), RooMomentMorph::getCache(), RooAbsCachedReal::getCache(), RooAbsCachedPdf::getCache(), RooAbsAnaConvPdf::getCoefNorm(), RooAddModel::getCompIntList(), RooAbsPdf::getNormObj(), RooCacheManager< std::vector< Double_t > >::getObj(), RooProduct::getPartIntList(), RooProdPdf::getPartIntList(), RooAddModel::getProjCache(), RooAddPdf::getProjCache(), RooProjectedPdf::getProjection(), and RooAbsPdf::syncNormalization().
|
inline |
Definition at line 54 of file RooCacheManager.h.
T * RooCacheManager< T >::getObj | ( | const RooArgSet * | nset, |
const RooArgSet * | iset, | ||
Int_t * | sterileIndex = 0 , |
||
const TNamed * | isetRangeName = 0 |
||
) |
Definition at line 289 of file RooCacheManager.h.
T * RooCacheManager< T >::getObjByIndex | ( | Int_t | index | ) | const |
Definition at line 324 of file RooCacheManager.h.
Referenced by RooProduct::analyticalIntegral(), RooAddition::analyticalIntegral(), RooProjectedPdf::analyticalIntegralWN(), RooEffProd::analyticalIntegralWN(), RooRealSumPdf::analyticalIntegralWN(), RooAddModel::analyticalIntegralWN(), PiecewiseInterpolation::analyticalIntegralWN(), RooSimultaneous::analyticalIntegralWN(), RooProdPdf::analyticalIntegralWN(), RooAbsCachedReal::setInterpolationOrder(), and RooAbsCachedPdf::setInterpolationOrder().
|
inlinevirtual |
Reimplemented in RooObjCacheManager.
Definition at line 90 of file RooCacheManager.h.
|
inline |
Definition at line 65 of file RooCacheManager.h.
Referenced by RooAddition::getAnalyticalIntegral(), RooEffProd::getAnalyticalIntegralWN(), RooRealSumPdf::getAnalyticalIntegralWN(), PiecewiseInterpolation::getAnalyticalIntegralWN(), ParamHistFunc::getAnalyticalIntegralWN(), RooSimultaneous::getAnalyticalIntegralWN(), RooAddModel::getCompIntList(), RooProduct::getPartIntList(), RooProdPdf::getPartIntList(), and RooProjectedPdf::getProjection().
const RooNameSet * RooCacheManager< T >::nameSet1ByIndex | ( | Int_t | index | ) | const |
Definition at line 337 of file RooCacheManager.h.
Referenced by RooProjectedPdf::analyticalIntegralWN(), RooRealSumPdf::analyticalIntegralWN(), RooAddModel::analyticalIntegralWN(), and RooProdPdf::analyticalIntegralWN().
const RooNameSet * RooCacheManager< T >::nameSet2ByIndex | ( | Int_t | index | ) | const |
Definition at line 350 of file RooCacheManager.h.
Referenced by RooProduct::analyticalIntegral(), RooAddition::analyticalIntegral(), RooProjectedPdf::analyticalIntegralWN(), RooRealSumPdf::analyticalIntegralWN(), RooAddModel::analyticalIntegralWN(), and RooProdPdf::analyticalIntegralWN().
|
inlinevirtual |
Interface for operation mode changes.
Reimplemented from RooAbsCache.
Reimplemented in RooObjCacheManager.
Definition at line 79 of file RooCacheManager.h.
|
inlinevirtual |
Interface for printing of cache guts in tree mode printing.
Reimplemented from RooAbsCache.
Reimplemented in RooObjCacheManager.
Definition at line 82 of file RooCacheManager.h.
|
inlinevirtual |
Interface for server redirect calls.
Reimplemented from RooAbsCache.
Reimplemented in RooObjCacheManager.
Definition at line 74 of file RooCacheManager.h.
void RooCacheManager< T >::reset | ( | ) |
Definition at line 199 of file RooCacheManager.h.
Referenced by RooAddPdf::fixCoefNormalization(), RooAddModel::fixCoefNormalization(), and RooProdPdf::redirectServersHook().
|
inline |
Definition at line 49 of file RooCacheManager.h.
Referenced by RooDataHist::calculatePartialBinVolume(), RooAddition::getAnalyticalIntegral(), RooEffProd::getAnalyticalIntegralWN(), RooRealSumPdf::getAnalyticalIntegralWN(), PiecewiseInterpolation::getAnalyticalIntegralWN(), ParamHistFunc::getAnalyticalIntegralWN(), RooSimultaneous::getAnalyticalIntegralWN(), RooMomentMorph::getCache(), RooAbsCachedReal::getCache(), RooAbsCachedPdf::getCache(), RooAbsAnaConvPdf::getCoefNorm(), RooAddModel::getCompIntList(), RooAbsPdf::getNormObj(), RooProduct::getPartIntList(), RooProdPdf::getPartIntList(), RooAddModel::getProjCache(), RooAddPdf::getProjCache(), RooProjectedPdf::getProjection(), RooCacheManager< std::vector< Double_t > >::setObj(), and RooAbsPdf::syncNormalization().
Int_t RooCacheManager< T >::setObj | ( | const RooArgSet * | nset, |
const RooArgSet * | iset, | ||
T * | obj, | ||
const TNamed * | isetRangeName = 0 |
||
) |
Definition at line 231 of file RooCacheManager.h.
|
virtual |
Reimplemented in RooObjCacheManager.
Definition at line 216 of file RooCacheManager.h.
Referenced by RooObjCacheManager::sterilize().
|
inlinevirtual |
Reimplemented from RooAbsCache.
Definition at line 94 of file RooCacheManager.h.
|
protected |
Actual use.
Definition at line 109 of file RooCacheManager.h.
Referenced by RooCacheManager< std::vector< Double_t > >::lastIndex(), and RooCacheManager< T >::RooCacheManager().
|
protected |
Definition at line 107 of file RooCacheManager.h.
Referenced by RooCacheManager< T >::RooCacheManager().
|
protected |
Last slot accessed.
Definition at line 111 of file RooCacheManager.h.
Referenced by RooCacheManager< T >::RooCacheManager().
|
protected |
Normalization/Integration set manager.
Definition at line 112 of file RooCacheManager.h.
Referenced by RooCacheManager< std::vector< Double_t > >::getObj(), and RooCacheManager< T >::RooCacheManager().
|
protected |
Maximum size.
Definition at line 108 of file RooCacheManager.h.
Referenced by RooCacheManager< std::vector< Double_t > >::cacheSize(), RooCacheManager< T >::RooCacheManager(), and RooCacheManager< std::vector< Double_t > >::wireCache().
|
protected |
Payload.
Definition at line 113 of file RooCacheManager.h.
Referenced by RooCacheManager< std::vector< Double_t > >::getObj(), RooCacheManager< T >::RooCacheManager(), and RooCacheManager< std::vector< Double_t > >::wireCache().