IsExpandIndex

Description

Determines whether the specified indexth axis is a dimension-expanded axis based on the shape after dimension expansion.

Prototype

bool IsExpandIndex(const AxisIndex index) const

Parameters

Parameter

Input/Output

Description

index

Input

Index of a specified axis.

Returns

  • true indicates that the specified axis is a dimension-expanded axis.
  • false indicates that the specified axis is an original axis.

Restrictions

None

Example

ExpandDimsType type1("1001");
bool is_expand_index0 = type1.IsExpandIndex(0); // true
bool is_expand_index1 = type1.IsExpandIndex(1); // false