Definition at line 40 of file Evaluator.h.
#include <RooFit/Evaluator.h>
◆ Evaluator()
Evaluator::Evaluator |
( |
const RooAbsReal & |
absReal, |
|
|
bool |
useGPU = false |
|
) |
| |
Construct a new Evaluator.
The constructor analyzes and saves metadata about the graph, useful for the evaluation of it that will be done later. In case the CUDA mode is selected, there's also some CUDA-related initialization.
- Parameters
-
[in] | absReal | The RooAbsReal object that sits on top of the computation graph that we want to evaluate. |
[in] | useGPU | Whether the evaluation should be preferably done on the GPU. |
Definition at line 153 of file Evaluator.cxx.
◆ ~Evaluator()
Evaluator::~Evaluator |
( |
| ) |
|
◆ assignToGPU()
void Evaluator::assignToGPU |
( |
NodeInfo & |
info | ) |
|
|
private |
Assign a node to be computed in the GPU.
Scan it's clients and also assign them in case they only depend on GPU nodes.
Definition at line 540 of file Evaluator.cxx.
◆ computeCPUNode()
◆ getParameters()
Gets all the parameters of the RooAbsReal.
This is in principle not necessary, because we can always ask the RooAbsReal itself, but the Evaluator has the cached information to get the answer quicker. Therefore, this is not meant to be used in general, just where it matters.
- Warning
- If we find another solution to get the parameters efficiently, this function might be removed without notice.
Definition at line 665 of file Evaluator.cxx.
◆ getValHeterogeneous()
std::span< const double > Evaluator::getValHeterogeneous |
( |
| ) |
|
|
private |
Returns the value of the top node in the computation graph.
Definition at line 459 of file Evaluator.cxx.
◆ markGPUNodes()
void Evaluator::markGPUNodes |
( |
| ) |
|
|
private |
Decides which nodes are assigned to the GPU in a CUDA fit.
Definition at line 576 of file Evaluator.cxx.
◆ print()
void Evaluator::print |
( |
std::ostream & |
os | ) |
const |
◆ processVariable()
void Evaluator::processVariable |
( |
NodeInfo & |
nodeInfo | ) |
|
|
private |
Process a variable in the computation graph.
This is a separate non-inlined function such that we can see in performance profiles how long this takes.
Definition at line 403 of file Evaluator.cxx.
◆ run()
std::span< const double > Evaluator::run |
( |
| ) |
|
Returns the value of the top node in the computation graph.
Definition at line 427 of file Evaluator.cxx.
◆ setClientsDirty()
void Evaluator::setClientsDirty |
( |
NodeInfo & |
nodeInfo | ) |
|
|
private |
Flags all the clients of a given node dirty.
This is a separate non-inlined function such that we can see in performance profiles how long this takes.
Definition at line 419 of file Evaluator.cxx.
◆ setInput()
void Evaluator::setInput |
( |
std::string const & |
name, |
|
|
std::span< const double > |
inputArray, |
|
|
bool |
isOnDevice |
|
) |
| |
◆ setOperMode()
◆ syncDataTokens()
void Evaluator::syncDataTokens |
( |
| ) |
|
|
private |
If there are servers with the same name that got de-duplicated in the _nodes
list, we need to set their data tokens too.
We find such nodes by visiting the servers of every known node.
Definition at line 230 of file Evaluator.cxx.
◆ updateOutputSizes()
void Evaluator::updateOutputSizes |
( |
| ) |
|
|
private |
◆ _bufferManager
◆ _changeOperModeRAIIs
◆ _dataMapCPU
◆ _dataMapCUDA
◆ _needToUpdateOutputSizes
bool RooFit::Evaluator::_needToUpdateOutputSizes = false |
|
private |
◆ _nEvaluations
int RooFit::Evaluator::_nEvaluations = 0 |
|
private |
◆ _nodes
std::vector<NodeInfo> RooFit::Evaluator::_nodes |
|
private |
◆ _topNode
◆ _useGPU
const bool RooFit::Evaluator::_useGPU = false |
|
private |
The documentation for this class was generated from the following files: