#include <qle/math/computeenvironment.hpp>
Definition at line 64 of file computeenvironment.hpp.
◆ ~ComputeContext()
◆ init()
◆ initiateCalculation()
virtual std::pair< std::size_t, bool > initiateCalculation |
( |
const std::size_t |
n, |
|
|
const std::size_t |
id = 0 , |
|
|
const std::size_t |
version = 0 , |
|
|
const Settings |
settings = {} |
|
) |
| |
|
pure virtual |
◆ disposeCalculation()
virtual void disposeCalculation |
( |
const std::size_t |
id | ) |
|
|
pure virtual |
◆ createInputVariable() [1/2]
virtual std::size_t createInputVariable |
( |
double |
v | ) |
|
|
pure virtual |
◆ createInputVariable() [2/2]
virtual std::size_t createInputVariable |
( |
double * |
v | ) |
|
|
pure virtual |
◆ createInputVariates()
virtual std::vector< std::vector< std::size_t > > createInputVariates |
( |
const std::size_t |
dim, |
|
|
const std::size_t |
steps |
|
) |
| |
|
pure virtual |
◆ applyOperation()
virtual std::size_t applyOperation |
( |
const std::size_t |
randomVariableOpCode, |
|
|
const std::vector< std::size_t > & |
args |
|
) |
| |
|
pure virtual |
◆ freeVariable()
virtual void freeVariable |
( |
const std::size_t |
id | ) |
|
|
pure virtual |
◆ declareOutputVariable()
virtual void declareOutputVariable |
( |
const std::size_t |
id | ) |
|
|
pure virtual |
◆ finalizeCalculation() [1/2]
virtual void finalizeCalculation |
( |
std::vector< double * > & |
output | ) |
|
|
pure virtual |
◆ deviceInfo()
virtual std::vector< std::pair< std::string, std::string > > deviceInfo |
( |
| ) |
const |
|
virtual |
◆ supportsDoublePrecision()
virtual bool supportsDoublePrecision |
( |
| ) |
const |
|
virtual |
◆ debugInfo()
virtual const DebugInfo & debugInfo |
( |
| ) |
const |
|
pure virtual |
◆ finalizeCalculation() [2/2]
void finalizeCalculation |
( |
std::vector< std::vector< double > > & |
output | ) |
|
Definition at line 73 of file computeenvironment.cpp.
73 {
74 std::vector<double*> outputPtr(output.size());
75 std::transform(output.begin(), output.end(), outputPtr.begin(),
76 [](std::vector<double>& v) -> double* { return &v[0]; });
78}
virtual void finalizeCalculation(std::vector< double * > &output)=0