std1.0.0-beta-7 SafeC docs

std :: ml::module

Function std::module_loss

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

generic<M: Module> &FloatTensor module_loss(
    &M m,
    int loss,
    const &FloatTensor x,
    const &FloatTensor y,
)

A built-in loss (TRAIN_LOSS_*) of m's output against y.