std1.0.0-beta-7 SafeC docs

std :: ml::tensor

Type alias std::TensorBackwardFn

#include <std/ml/tensor.h> source

typedef fn void(&FloatTensor selfTensor) TensorBackwardFn

A node's backward function. Its argument is the node viewed as a float32 tensor: the graph fields (and the float32 gradient) have one layout for every element type, so one function serves a graph that mixes them, and each function reads only those fields of its node (and its parents).