This base class is used to implement the automatic generation of the .hpp file that restores the evaluation handles in the reading process.
More...
#include <primalBaseReaderWriter.hpp>
|
using | EvalHandle = typename Tape::EvalHandle |
| See TapeWriterInterface.
|
|
using | Identifier = typename Type::Identifier |
| See TapeWriterInterface.
|
|
using | Real = typename Type::Real |
| See TapeWriterInterface.
|
|
using | Tape = typename Type::Tape |
| See TapeWriterInterface.
|
|
using | Type = T_Type |
| See TapeWriterInterface.
|
|
using | Identifier = typename Type::Identifier |
| See TapeWriterInterface.
|
|
using | Tape = typename Type::Tape |
| See TapeWriterInterface.
|
|
using | Type = T_Type |
| See TapeWriterInterface.
|
|
using | EvalHandle = typename Tape::EvalHandle |
| Evaluation handle used for primal value tapes.
|
|
using | Identifier = typename Type::Identifier |
| Identifier for the internal management, e.g. int.
|
|
using | Real = typename Type::Real |
| Primal computation type, e.g. double.
|
|
using | Tape = typename Type::Tape |
| The tape type that is to be written out.
|
|
using | Type = T_Type |
| The evaluation type.
|
|
|
| PrimalBaseTapeWriter (std::string const &name, std::vector< Identifier > const &in, std::vector< Identifier > const &out) |
| Constructor.
|
|
| CommonBaseTapeWriter (std::string const &name, std::vector< Identifier > const &in, std::vector< Identifier > const &out) |
| Constructor.
|
|
virtual void | finish () |
| After all the statements have been written, the finish method finalizes the writing process.
|
|
virtual void | start (Tape &tape) |
| Destructor.
|
|
virtual void | writeLowLevelFunction (size_t &curLLFByteDataPos, char *dataPtr, size_t &curLLFInfoDataPos, Config::LowLevelFunctionToken *const tokenPtr, Config::LowLevelFunctionDataSize *const dataSizePtr) |
| Used for statements that contain a low level function.
|
|
virtual void | writeStatement (Identifier const &curLhsIdentifier, size_t &curJacobianPos, Real const *const rhsJacobians, Identifier const *const rhsIdentifiers, Config::ArgumentSize const &nJacobians) |
| Called for each statement. The method writes the current statement to the file. This overload is used for the Jacobian writers.
|
|
virtual void | writeStatement (WriteInfo const &info, Identifier const &curLhsIdentifier, Real const &primalValue, Config::ArgumentSize const &nPassiveValues, size_t const &curRhsIdentifiersPos, Identifier const *const rhsIdentifiers, size_t const &curPassiveValuePos, Real const *const passiveValues, size_t &curConstantPos, Real const *const constantValues, EvalHandle stmtEvalHandle) |
| Called for each statement. The method writes the current statement to the file. This overload is used for the primal value writers and contains additional arguments, such as the WriteInfo.
|
|
| CommonReaderWriterMethods () |
| Constructor.
|
|
| CommonReaderWriterMethods (std::string const &name) |
| Constructor.
|
|
std::string | modifyFileName (std::string const &suffix) |
| Remove the file extension and replace it with a new suffix.
|
|
void | openFile (FILE *&fileHandle, std::string const &name, std::string const &mode) |
|
|
size_t | evalHandleCount |
| Count the number of unique evalHandles.
|
|
std::vector< std::string > | evalHandleStatements |
| The unique evalHandleStatements.
|
|
std::map< EvalHandle, size_t > | existingEvalHandles |
| Contains the existing handles and the assigned index.
|
|
std::vector< Identifier > | inputVariables |
| The identifiers which have been registered as inputs.
|
|
std::vector< Identifier > | outputVariables |
| The identifiers which have been registered as outputs.
|
|
std::string | fileName |
| The base file name provided by the user.
|
|
|
void | generateHandleCreatorFile () |
| This method is used to generate an .hpp file which creates the necessary EvalHandles in the reading process.
|
|
size_t | getEvalHandleIndex (EvalHandle const evalHandle, std::string const &evalStatement) |
| Get the index for an evalHandle.
|
|
void | printIoBinary (Tape &tape) |
| Generate the IO file in a binary format.
|
|
void | printIoText (Tape &tape) |
| Generate the IO file in a text format.
|
|
template<typename T_Type>
struct codi::PrimalBaseTapeWriter< T_Type >
This base class is used to implement the automatic generation of the .hpp file that restores the evaluation handles in the reading process.
See codi::TapeWriterInterface for a description on how to use the primal tape writers with the generated header file.
- Template Parameters
-
T_Type | The CoDiPack type of the tape that is to be written out. |
The documentation for this struct was generated from the following file: