Module swim.math
Package swim.math

Class TensorDims

  • All Implemented Interfaces:
    Debug

    public final class TensorDims
    extends Object
    implements Debug
    • Field Detail

      • size

        public final int size
      • stride

        public final int stride
    • Method Detail

      • isDefined

        public boolean isDefined()
      • rank

        public int rank()
      • size

        public int size()
      • stride

        public int stride()
      • isPacked

        public boolean isPacked()
      • isFullyPacked

        public boolean isFullyPacked()
      • by

        public TensorDims by​(int size,
                             int stride)
      • toSizeArray

        public int[] toSizeArray​(int[] sizes)
      • toSizeArray

        public int[] toSizeArray()
      • toStrideArray

        public int[] toStrideArray​(int[] strides)
      • toStrideArray

        public int[] toStrideArray()
      • toValue

        public Value toValue()
      • conforms

        public boolean conforms​(TensorDims that)
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • debug

        public <T> Output<T> debug​(Output<T> output)
        Description copied from interface: Debug
        Writes a developer readable, debug-formatted string representation of this object to output.
        Specified by:
        debug in interface Debug
        Returns:
        the continuation of the output.
      • undefined

        public static TensorDims undefined()
      • of

        public static TensorDims of​(int size,
                                    int stride)