std1.0.0-beta-7 SafeC docs

std :: ml::gpu_rocm

Function std::rocm_half_bias

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

int rocm_half_bias(
    struct RocmHalfBuf y,
    struct RocmHalfBuf bias,
    unsigned long rows,
    unsigned long channels,
    unsigned long plane,
    int relu,
)

y[r][c][p] += bias[c] (rows x channels x plane, row-major), then ReLU when relu: a linear layer's bias (plane 1) or an NCHW convolution's.