Compadre 1.5.5
Loading...
Searching...
No Matches
Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> > Struct Template Reference

Creates 1D subviews of data from a 1D view, generally constructed with CreateNDSliceOnDeviceView. More...

Detailed Description

template<typename T, typename T2>
struct Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >

Creates 1D subviews of data from a 1D view, generally constructed with CreateNDSliceOnDeviceView.

Definition at line 59 of file Compadre_Evaluator.hpp.

#include <Compadre_Evaluator.hpp>

Public Member Functions

 SubviewND (T data_in, T2 data_original_view, bool scalar_as_vector_if_needed)
 
auto get1DView (const int column_num) -> decltype(Kokkos::subview(_data_in, Kokkos::ALL))
 
auto get2DView (const int column_num, const int block_size) -> decltype(Kokkos::subview(_data_in, Kokkos::ALL))
 
T2 copyToAndReturnOriginalView ()
 
 SubviewND (T data_in, T2 data_original_view, bool scalar_as_vector_if_needed)
 
auto get1DView (const int column_num) -> decltype(Kokkos::subview(_data_in, Kokkos::ALL, column_num))
 
auto get2DView (const int column_num, const int block_size) -> decltype(Kokkos::subview(_data_in, Kokkos::ALL, Kokkos::make_pair(column_num *block_size,(column_num+1) *block_size)))
 
T2 copyToAndReturnOriginalView ()
 

Public Attributes

_data_in
 
T2 _data_original_view
 
bool _scalar_as_vector_if_needed
 
_data_in
 
T2 _data_original_view
 
bool _scalar_as_vector_if_needed
 

Constructor & Destructor Documentation

◆ SubviewND() [1/2]

template<typename T, typename T2>
Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::SubviewND ( T data_in,
T2 data_original_view,
bool scalar_as_vector_if_needed )
inline

Definition at line 66 of file Compadre_Evaluator.hpp.

◆ SubviewND() [2/2]

Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::SubviewND ( T data_in,
T2 data_original_view,
bool scalar_as_vector_if_needed )
inline

Definition at line 18 of file Compadre_Evaluator.hpp.

Member Function Documentation

◆ copyToAndReturnOriginalView() [1/2]

T2 Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::copyToAndReturnOriginalView ( )
inline

Definition at line 49 of file Compadre_Evaluator.hpp.

◆ copyToAndReturnOriginalView() [2/2]

template<typename T, typename T2>
T2 Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::copyToAndReturnOriginalView ( )
inline

Definition at line 87 of file Compadre_Evaluator.hpp.

◆ get1DView() [1/2]

template<typename T, typename T2>
auto Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::get1DView ( const int column_num) -> decltype(Kokkos::subview(_data_in, Kokkos::ALL))
inline

Definition at line 72 of file Compadre_Evaluator.hpp.

◆ get1DView() [2/2]

auto Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::get1DView ( const int column_num) -> decltype(Kokkos::subview(_data_in, Kokkos::ALL, column_num))
inline

Definition at line 24 of file Compadre_Evaluator.hpp.

◆ get2DView() [1/2]

template<typename T, typename T2>
auto Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::get2DView ( const int column_num,
const int block_size ) -> decltype(Kokkos::subview(_data_in, Kokkos::ALL))
inline

Definition at line 82 of file Compadre_Evaluator.hpp.

◆ get2DView() [2/2]

auto Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::get2DView ( const int column_num,
const int block_size )-> decltype(Kokkos::subview(_data_in, Kokkos::ALL, Kokkos::make_pair(column_num*block_size, (column_num+1)*block_size)))
inline

Definition at line 35 of file Compadre_Evaluator.hpp.

Member Data Documentation

◆ _data_in [1/2]

T Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::_data_in

Definition at line 14 of file Compadre_Evaluator.hpp.

◆ _data_in [2/2]

template<typename T, typename T2>
T Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::_data_in

Definition at line 62 of file Compadre_Evaluator.hpp.

◆ _data_original_view [1/2]

T2 Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::_data_original_view

Definition at line 15 of file Compadre_Evaluator.hpp.

◆ _data_original_view [2/2]

template<typename T, typename T2>
T2 Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::_data_original_view

Definition at line 63 of file Compadre_Evaluator.hpp.

◆ _scalar_as_vector_if_needed [1/2]

bool Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::_scalar_as_vector_if_needed

Definition at line 16 of file Compadre_Evaluator.hpp.

◆ _scalar_as_vector_if_needed [2/2]

template<typename T, typename T2>
bool Compadre::SubviewND< T, T2, enable_if_t<(T::rank< 2)> >::_scalar_as_vector_if_needed

Definition at line 64 of file Compadre_Evaluator.hpp.


The documentation for this struct was generated from the following file: