std :: ml::trainer
Struct std::TrainLossSum
struct TrainLossSum {
double host;
unsigned long dev;
int device;
unsigned long steps;
}Internal: an epoch's running loss sum, kept where the losses are -- a scalar on the device for a device's losses, read once when the epoch ends -- so a step on a GPU doesn't wait for its loss to reach the host.
Fields
losses computed on the CPU
the device scalar (fp32), 0 until a device loss