|
| template<concepts::View ViewType> |
| KOKKOS_FUNCTION constexpr auto | extents (const ViewType &view) |
| | Get all extents of view.
|
| |
template<size_t Rank, typename ViewType, typename... Indices>
requires concepts::ViewOfRank<std::remove_reference_t<ViewType>, Rank> |
| KOKKOS_FUNCTION constexpr auto | slice (ViewType &&view, Indices &&... indices) |
| | Get a subview, given the first indices. The rest is filled with Kokkos::ALL.
|
| |
template<typename ViewType, typename... Indices>
requires concepts::ViewOfRank<std::remove_reference_t<ViewType>, sizeof...(Indices)> |
| KOKKOS_FUNCTION constexpr auto | slice (ViewType &&view, Indices &&... indices) |
| | This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
|
| |
template<size_t Rank, typename ViewType, typename... Indices>
requires concepts::ViewOfRank<std::remove_reference_t<ViewType>, Rank>
| KOKKOS_FUNCTION constexpr auto Kokkos::utils::view::slice |
( |
ViewType && | view, |
|
|
Indices &&... | indices ) |
|
constexpr |
Get a subview, given the first indices. The rest is filled with Kokkos::ALL.
- Note
- Though similar to
std::submdspan, we think it it OK not to provide the remaining slice specifiers if they are all Kokkos::ALL iif the user specifies what is the expected rank of the input view. This ensures that the user will not face unexpected behaviors. Therefore, we allow the following: auto sliced =
slice<4>(view_of_rank_4, 1, 2);
KOKKOS_FUNCTION constexpr auto slice(ViewType &&view, Indices &&... indices)
Get a subview, given the first indices. The rest is filled with Kokkos::ALL.
which is strictly equivalent to: auto sliced = subview(view_of_rank_4, 1, 2, Kokkos::ALL, Kokkos::ALL);
Definition at line 54 of file slice.hpp.
template<typename ViewType, typename... Indices>
requires concepts::ViewOfRank<std::remove_reference_t<ViewType>, sizeof...(Indices)>
| KOKKOS_FUNCTION constexpr auto Kokkos::utils::view::slice |
( |
ViewType && | view, |
|
|
Indices &&... | indices ) |
|
constexpr |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Definition at line 68 of file slice.hpp.