Skip to main content

ClikaRT::ops::numel

function

numel()

Tensor numel(Tensor x)

The tensor's total element count 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 3050