oa::FnMatrix::gruCellPointwiseBwd

gruCellPointwiseBwd: fused GRU pointwise backward. Returns gradients w.r.t. gatesI, gatesH and the previous hidden state.

Function Documentation

GruCellPointwiseBwdResult oa::FnMatrix::gruCellPointwiseBwd( const Matrix & inGatesI, const Matrix & inGatesH, const Matrix & inHidden, const Matrix & inGradOutput, oa::I32 inHiddenSize, oa::U32 inTimeOffset = 0, oa::U32 inBatchStride = 1 )
gruCellPointwiseBwd: fused GRU pointwise backward. Returns gradients w.r.t. gatesI, gatesH and the previous hidden state.

Parameters

inGatesI
const Matrix &

inGatesH
const Matrix &

inHidden
const Matrix &

inGradOutput
const Matrix &

inHiddenSize
oa::I32

inTimeOffset
oa::U32

row offset into inGatesI / dGatesI (in rows of 3H), default 0

inBatchStride
oa::U32

row stride between batches in inGatesI (T for batch-major, 1 for contiguous), default 1

Returns

GruCellPointwiseBwdResult

The declared return value.