|
| | SparseArray (const std::string label, array_layout layout) |
| | (Host) Constructor
|
| |
|
aosoa_type & | aosoa () |
| | Get AoSoA reference.
|
| |
| std::string | label () const |
| | Get array label (description)
|
| |
|
array_layout & | layout () |
| | Get reference to the array layout (device accessible)
|
| |
|
const array_layout & | layout () const |
| | Get const reference to the array layout (device accessible)
|
| |
| void | resize (const size_type n) |
| | Resize the AoSoA array according to the input.
|
| |
|
void | resize () |
| | Reserve the AoSoA array according to the sparse map info in layout.
|
| |
| void | reserve (const size_type n) |
| | Reserve the AoSoA array according to the input.
|
| |
| void | reserveFromMap (const double factor=1.2) |
| | Reserve the AoSoA array according to the sparse map info in layout.
|
| |
|
void | shrinkToFit () |
| | Shrink allocation to fit the valid size.
|
| |
| void | clear () |
| |
|
KOKKOS_FUNCTION size_type | capacity () |
| | Get AoSoA capacity.
|
| |
|
KOKKOS_FUNCTION size_type | size () const |
| | Get AoSoA size (valid number of elements)
|
| |
|
KOKKOS_FUNCTION bool | empty () const |
| | Test if the AoSoA array is empty.
|
| |
|
KOKKOS_FORCEINLINE_FUNCTION size_type | numSoA () const |
| | Get the number of SoA inside an AoSoA structure.
|
| |
|
KOKKOS_FORCEINLINE_FUNCTION size_type | arraySize (const size_type s) const |
| | Get data array size at a given struct member index.
|
| |
| template<class PositionSliceType> |
| void | registerSparseGrid (PositionSliceType &positions, int particle_num, const int p2g_radius=1) |
| | Register valid grids in sparse map according to input particle positions.
|
| |
| KOKKOS_FORCEINLINE_FUNCTION soa_type & | accessTile (const int tile_i, const int tile_j, const int tile_k) const |
| | (Device) Access tile SoA from tile-related information
|
| |
| template<typename Value> |
| KOKKOS_FORCEINLINE_FUNCTION soa_type & | accessTile (const Value tile_id) const |
| | (Device) Access tile SoA from tile-related information
|
| |
| KOKKOS_FORCEINLINE_FUNCTION soa_type & | accessTileFromCell (const int cell_i, const int cell_j, const int cell_k) const |
| | (Device) Access tile SoA from cell-related information
|
| |
| template<typename Key> |
| KOKKOS_FORCEINLINE_FUNCTION tuple_type | getTuple (const Key tile_key, const int cell_local_id) const |
| | Access AoSoA tuple from tile key and local cell id.
|
| |
| template<std::size_t M, typename... Indices> |
| KOKKOS_FORCEINLINE_FUNCTION soa_type::template member_reference_type< M > | get (const Kokkos::Array< int, 3 > cell_ijk, Indices &&... ids) const |
| | Access element from cell IJK, access corresponding element's channels with extra indices.
|
| |
| template<std::size_t M> |
| KOKKOS_FORCEINLINE_FUNCTION soa_type::template member_reference_type< M > | get (const Kokkos::Array< int, 3 > cell_ijk) const |
| | Access element from cell IJK.
|
| |
| template<std::size_t M, typename... Indices> |
| KOKKOS_FORCEINLINE_FUNCTION soa_type::template member_reference_type< M > | get (const Kokkos::Array< int, 3 > tile_ijk, const Kokkos::Array< int, 3 > local_cell_ijk, Indices &&... ids) const |
| | Access element in a hierarchical manner, from tile IJK and then local cell IJK, access corresponding element's channels with extra indices.
|
| |
| template<std::size_t M> |
| KOKKOS_FORCEINLINE_FUNCTION soa_type::template member_reference_type< M > | get (const Kokkos::Array< int, 3 > tile_ijk, const Kokkos::Array< int, 3 > local_cell_ijk) const |
| | Access element in a hierarchical manner, from tile IJK and then local cell IJK.
|
| |
| template<std::size_t M, typename... Indices> |
| KOKKOS_FORCEINLINE_FUNCTION soa_type::template member_reference_type< M > | get (const int tile_id, const Kokkos::Array< int, 3 > local_cell_ijk, Indices &&... ids) const |
| | Access element in a hierarchical manner, from 1D tile ID and then local cell IJK, access corresponding element's channels with extra indices.
|
| |
| template<std::size_t M> |
| KOKKOS_FORCEINLINE_FUNCTION soa_type::template member_reference_type< M > | get (const int tile_id, const Kokkos::Array< int, 3 > local_cell_ijk) const |
| | Access element in a hierarchical manner, from 1D tile ID and then local cell IJK.
|
| |
| template<std::size_t M, typename... Indices> |
| KOKKOS_FORCEINLINE_FUNCTION soa_type::template member_reference_type< M > | get (const int tile_id, const int cell_id, Indices &&... ids) const |
| | Access element in a hierarchical manner, from 1D tile ID and then 1D local cell ID, access corresponding element's channels with extra indices.
|
| |
| template<std::size_t M> |
| KOKKOS_FORCEINLINE_FUNCTION soa_type::template member_reference_type< M > | get (const int tile_id, const int cell_id) const |
| | Access element in a hierarchical manner, from 1D tile ID and then 1D local cell ID.
|
| |
template<class DataTypes, class MemorySpace, class EntityType, class MeshType, class SparseMapType>
class Cabana::Grid::Experimental::SparseArray< DataTypes, MemorySpace, EntityType, MeshType, SparseMapType >
Sparse array of field data on the local sparse mesh; Array data is stored in AoSoA manner, with each tile being the SoA element.
- Template Parameters
-
| DataTypes | Data types (Cabana::MemberTypes). |
| MemorySpace | Kokkos memory space. |
| EntityType | Array entity type (node, cell, face, edge). |
| MeshType | Mesh type (sparse mesh). |
| SparseMapType | Sparse map type. |