length property

  1. @override
int get length
override

Returns the number of elements in the last dimension.

Implementation

@override
int get length {
  int length = 0;

  List<NdArray> lastDimension = extractDimension(numDimensions);

  for (NdArray ndArray in lastDimension) {
    length += ndArray.data.length;
  }

  return length;
}