Tensor tensorflow::Tensor::Slice(int64 dim0_start, int64 dim0_limit) const
Slice this tensor along the 1st dimension.
I.e., the returned tensor satisfies returned[i, ...] == this[dim0_start + i, ...]. The returned tensor shares the underlying tensor buffer with this tensor.
NOTE: The returned tensor may not satisfies the same alignment requirement as this tensor depending on the shape. The caller must check the returned tensor's alignment before calling certain methods that have alignment requirement (e.g., flat()
, tensor()
).
REQUIRES: dims()
>= 1 REQUIRES: 0 <= dim0_start <= dim0_limit <= dim_size(0)
Please login to continue.