Interface Tensor<E>

    • Method Detail

      • shape

        Shape shape()
        Retrieves the shape of the tensor. As shape we understand simply the structure of a tensor: Its dimensions and the available positions.

        Implementations have to take care that the returned value here is never null.

        Returns:
        the shape of the tensor.
      • context

        Position context()
        Retrieves the context of the tensor, which is nothing else than a position. As context of the tensor we understand coordinates within a higher dimensional space than than the tensor has itself. This coordinates can e.g. transport information when e.g. a higher-dimensional tensor is split into smaller ones, so that it can potentially be reconstructed afterwards.

        Implementations have to guarantee that the returned value here is never null.

        Returns:
        the context of the tensor.