nki.isa.reciprocal#
- nki.isa.reciprocal(dst, data, name=None)[source]#
Compute element-wise reciprocal (1.0/x) of the input
datatile using Vector Engine.Memory types.
Both the input
dataand outputdsttiles can be in SBUF or PSUM.Data types.
The input
datatile can be any valid NKI data type (see Supported Data Types for more information). The Vector Engine automatically casts the input data type to float32 and performs the reciprocal computation in float32 math. The float32 results are cast to the data type ofdst.Layout.
The partition dimension of the input
datais considered the parallel compute dimension.Tile size.
The partition dimension size of input
dataand outputdsttiles must be the same and must not exceed 128. The number of elements per partition ofdstmust match that ofdataand must not exceed the physical size of each SBUF partition.- Parameters:
dst – the output tile
data – the input tile