Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
RooBatchCompute::RooBatchComputeInterface Class Referenceabstract

The interface which should be implemented to provide optimised computation functions for implementations of RooAbsReal::computeBatch().

The class RooBatchComputeInterface provides the mechanism for external modules (like RooFit) to call functions from the library. The power lies in the virtual functions that can resolve to different implementations for the functionality; for example, calling a function through dispatchCuda will resolve to efficient CUDA implementations.

This interface contains the signatures of the compute functions of every PDF that has an optimised implementation available. These are the functions that perform the actual computations in batches.

Several implementations of this interface may be provided, e.g. SSE, AVX, AVX2 etc. At run time, the fastest implementation of this interface is selected, and using a virtual call, the computation is dispatched to the best backend.

See also
RooBatchCompute::dispatch, RooBatchComputeClass, RF_ARCH

Definition at line 140 of file RooBatchCompute.h.

Public Member Functions

virtual ~RooBatchComputeInterface ()=default
 
virtual Architecture architecture () const =0
 
virtual std::string architectureName () const =0
 
void compute (Config const &cfg, Computer comp, RestrictArr output, size_t size, const VarVector &vars)
 
virtual void compute (Config const &cfg, Computer, RestrictArr, size_t, const VarVector &, ArgVector &)=0
 
virtual ReduceNLLOutput reduceNLL (Config const &cfg, std::span< const double > probas, std::span< const double > weights, std::span< const double > offsetProbas)=0
 
virtual double reduceSum (Config const &cfg, InputArr input, size_t n)=0
 

#include </home/sftnight/build/workspace/root-makedoc-v630/rootspi/rdoc/src/v6-30-00-patches/roofit/batchcompute/res/RooBatchCompute.h>

Inheritance diagram for RooBatchCompute::RooBatchComputeInterface:
[legend]

Constructor & Destructor Documentation

◆ ~RooBatchComputeInterface()

virtual RooBatchCompute::RooBatchComputeInterface::~RooBatchComputeInterface ( )
virtualdefault

Member Function Documentation

◆ architecture()

virtual Architecture RooBatchCompute::RooBatchComputeInterface::architecture ( ) const
pure virtual

◆ architectureName()

virtual std::string RooBatchCompute::RooBatchComputeInterface::architectureName ( ) const
pure virtual

◆ compute() [1/2]

void RooBatchCompute::RooBatchComputeInterface::compute ( Config const &  cfg,
Computer  comp,
RestrictArr  output,
size_t  size,
const VarVector vars 
)
inline

Definition at line 144 of file RooBatchCompute.h.

◆ compute() [2/2]

virtual void RooBatchCompute::RooBatchComputeInterface::compute ( Config const &  cfg,
Computer  ,
RestrictArr  ,
size_t  ,
const VarVector ,
ArgVector  
)
pure virtual

◆ reduceNLL()

virtual ReduceNLLOutput RooBatchCompute::RooBatchComputeInterface::reduceNLL ( Config const &  cfg,
std::span< const double probas,
std::span< const double weights,
std::span< const double offsetProbas 
)
pure virtual

◆ reduceSum()

virtual double RooBatchCompute::RooBatchComputeInterface::reduceSum ( Config const &  cfg,
InputArr  input,
size_t  n 
)
pure virtual

The documentation for this class was generated from the following file: