nki.language.ndarray — AWS Neuron Documentation (original) (raw)

This document is relevant for: Inf2, Trn1, Trn2

nki.language.ndarray#

nki.language.ndarray(shape, dtype, *, buffer=None, name='', **kwargs)[source]#

Create a new tensor of given shape and dtype on the specified buffer.

((Similar to numpy.ndarray))

Parameters:

Returns:

a new tensor allocated on the buffer.

This document is relevant for: Inf2, Trn1, Trn2