Struct TupleViewNodeOp

Inheritance Relationships

Base Type

Struct Documentation

struct TupleViewNodeOp : public marian::UnaryNodeOp

Public Functions

TupleViewNodeOp(Expr origin, Shape shape, Type type)
~TupleViewNodeOp()
void allocate()
void free()
void forward()
void backward()
void init_dependent()

Initialization for backward step of top node in computation graph.

Allocates memory and sets gradient to 1 (df/df == 1).

void set_zero_adjoint()

Initialization for backward step of any non-top node in computation graph.

Allocates memory and sets gradient to 0 for further accumulation of gradients from all parents.

Tensor &val()
Tensor &grad()
const std::string type()
const std::string color()