Skip to main content

ClikaRT::ops::ndim

function

ndim()

Tensor ndim(Tensor x)

The tensor's rank as a 0-D Int64 tensor.

The value is produced ON DEVICE and is traceable; under tracing it carries the symbolic value. For a plain host integer use the *_host sibling instead.

Throws

  • ClikaRT::Error: when the input's dtype/shape is not served for this operation (the machine-readable reason rides code_name()).

Returns: 0-D Int64.

Declared in ClikaRT/compute/ops.h, line 3043