std1.0.0-beta-7 SafeC docs

std :: ml::gpu_mps

Function std::mps_scale_f32_chained

#include <std/ml/gpu_mps.h> source ยท definition

int mps_scale_f32_chained(struct MpsBuf buf, float k, &float out, unsigned long n)

out[i] = buf[i] * k -- chained version of mps_scale_f32, input already a still-pending GPU buffer. Used by tensor_sub_gpu's backward for dTarget = -1 * (incoming gradient), when that incoming gradient is itself still GPU-pending.