scaleAndShift

fun <I, T : DType, V> Transform<I, Tensor<T, V>>.scaleAndShift(ctx: ExecutionContext, scale: Float, offset: Float = 0.0f): Transform<I, Tensor<T, V>>(source)

Chains a ScaleAndShift transform: output = input * scale + offset

Parameters

ctx

The execution context

scale

The multiplier

offset

The value to add