#include <Expression.h>
Public Member Functions | |
virtual void | dims (std::map< Key, int > &map) const |
Return dimensions for each argument, as a map. More... | |
virtual std::set< Key > | keys () const |
Return keys that play in this expression as a set. More... | |
virtual void | print (const std::string &indent="") const =0 |
Print. More... | |
virtual T | traceExecution (const Values &values, ExecutionTrace< T > &trace, char *traceStorage) const =0 |
Construct an execution trace for reverse AD. More... | |
size_t | traceSize () const |
virtual T | value (const Values &values) const =0 |
Return value. More... | |
virtual | ~ExpressionNode () |
Destructor. More... | |
Protected Member Functions | |
ExpressionNode (size_t traceSize=0) | |
Constructor, traceSize is size of the execution trace of expression rooted here. More... | |
Protected Attributes | |
size_t | traceSize_ |
Friends | |
GTSAM_EXPORT friend std::ostream & | operator<< (std::ostream &os, const ExpressionNode &node) |
Streaming. More... | |
Expression node. The superclass for objects that do the heavy lifting An Expression<T> has a pointer to an ExpressionNode<T> underneath allowing Expressions to have polymorphic behaviour even though they are passed by value. This is the same way std::function works. http://loki-lib.sourceforge.net/html/a00652.html
Definition at line 40 of file Expression.h.
|
inlineprotected |
Constructor, traceSize is size of the execution trace of expression rooted here.
Definition at line 72 of file ExpressionNode.h.
|
inlinevirtual |
Destructor.
Definition at line 79 of file ExpressionNode.h.
|
inlinevirtual |
Return dimensions for each argument, as a map.
Reimplemented in gtsam::internal::BinarySumNode< T >, gtsam::internal::ScalarMultiplyNode< T >, gtsam::internal::TernaryExpression< T, A1, A2, A3 >, gtsam::internal::BinaryExpression< T, A1, A2 >, gtsam::internal::UnaryExpression< T, A1 >, and gtsam::internal::LeafExpression< T >.
Definition at line 101 of file ExpressionNode.h.
|
inlinevirtual |
Return keys that play in this expression as a set.
Reimplemented in gtsam::internal::BinarySumNode< T >, gtsam::internal::ScalarMultiplyNode< T >, gtsam::internal::TernaryExpression< T, A1, A2, A3 >, gtsam::internal::BinaryExpression< T, A1, A2 >, gtsam::internal::UnaryExpression< T, A1 >, and gtsam::internal::LeafExpression< T >.
Definition at line 95 of file ExpressionNode.h.
|
pure virtual |
Print.
Implemented in gtsam::internal::BinarySumNode< T >, gtsam::internal::ScalarMultiplyNode< T >, gtsam::internal::TernaryExpression< T, A1, A2, A3 >, gtsam::internal::BinaryExpression< T, A1, A2 >, gtsam::internal::UnaryExpression< T, A1 >, gtsam::internal::LeafExpression< T >, and gtsam::internal::ConstantExpression< T >.
|
pure virtual |
Construct an execution trace for reverse AD.
Implemented in gtsam::internal::LeafExpression< T >, gtsam::internal::ConstantExpression< T >, gtsam::internal::BinarySumNode< T >, gtsam::internal::ScalarMultiplyNode< T >, gtsam::internal::TernaryExpression< T, A1, A2, A3 >, gtsam::internal::BinaryExpression< T, A1, A2 >, and gtsam::internal::UnaryExpression< T, A1 >.
|
inline |
Definition at line 105 of file ExpressionNode.h.
|
pure virtual |
Return value.
Implemented in gtsam::internal::BinarySumNode< T >, gtsam::internal::ScalarMultiplyNode< T >, gtsam::internal::TernaryExpression< T, A1, A2, A3 >, gtsam::internal::BinaryExpression< T, A1, A2 >, gtsam::internal::UnaryExpression< T, A1 >, gtsam::internal::LeafExpression< T >, and gtsam::internal::ConstantExpression< T >.
|
friend |
Streaming.
Definition at line 87 of file ExpressionNode.h.
|
protected |
Definition at line 69 of file ExpressionNode.h.