BlackCat_Tensors
A GPU-supported autograd and linear algebra library, designed for neural network construction
Public Member Functions | Public Attributes | Static Public Attributes | Friends | List of all members
bc::Strided_Vector_Shape Struct Reference

#include <shape.h>

Collaboration diagram for bc::Strided_Vector_Shape:
Collaboration graph
[legend]

Public Member Functions

BCINLINE Strided_Vector_Shape (size_t length, size_t leading_dim)
 
BCINLINE bool operator== (const Strided_Vector_Shape &other) const
 
BCINLINE size_t operator[] (size_t idx) const
 
BCINLINE size_t size () const
 
BCINLINE size_t rows () const
 
BCINLINE size_t cols () const
 
BCINLINE size_t dim (int i) const
 
BCINLINE size_t outer_dim () const
 
BCINLINE size_t leading_dim (int i=0) const
 
BCINLINE const auto & inner_shape () const
 
template<class... Integers>
BCINLINE size_t dims_to_index (size_t i, Integers... ints) const
 
template<class... Integers>
BCINLINE size_t dims_to_index (size_t index) const
 
BCINLINE size_t coefficientwise_dims_to_index (size_t index) const
 

Public Attributes

bc::Dim< 1 > m_inner_shape = {0}
 
bc::Dim< 1 > m_block_shape = {1}
 

Static Public Attributes

static constexpr int tensor_dim = 1
 

Friends

BCINLINE friend bool operator== (const Strided_Vector_Shape &shape, const Shape< 1 > &other)
 

Constructor & Destructor Documentation

◆ Strided_Vector_Shape()

BCINLINE bc::Strided_Vector_Shape::Strided_Vector_Shape ( size_t  length,
size_t  leading_dim 
)
inline

Member Function Documentation

◆ coefficientwise_dims_to_index()

BCINLINE size_t bc::Strided_Vector_Shape::coefficientwise_dims_to_index ( size_t  index) const
inline

◆ cols()

BCINLINE size_t bc::Strided_Vector_Shape::cols ( ) const
inline

◆ dim()

BCINLINE size_t bc::Strided_Vector_Shape::dim ( int  i) const
inline

◆ dims_to_index() [1/2]

template<class... Integers>
BCINLINE size_t bc::Strided_Vector_Shape::dims_to_index ( size_t  i,
Integers...  ints 
) const
inline

◆ dims_to_index() [2/2]

template<class... Integers>
BCINLINE size_t bc::Strided_Vector_Shape::dims_to_index ( size_t  index) const
inline

◆ inner_shape()

BCINLINE const auto& bc::Strided_Vector_Shape::inner_shape ( ) const
inline

◆ leading_dim()

BCINLINE size_t bc::Strided_Vector_Shape::leading_dim ( int  i = 0) const
inline

◆ operator==()

BCINLINE bool bc::Strided_Vector_Shape::operator== ( const Strided_Vector_Shape other) const
inline

◆ operator[]()

BCINLINE size_t bc::Strided_Vector_Shape::operator[] ( size_t  idx) const
inline

◆ outer_dim()

BCINLINE size_t bc::Strided_Vector_Shape::outer_dim ( ) const
inline

◆ rows()

BCINLINE size_t bc::Strided_Vector_Shape::rows ( ) const
inline

◆ size()

BCINLINE size_t bc::Strided_Vector_Shape::size ( ) const
inline

Friends And Related Function Documentation

◆ operator==

BCINLINE friend bool operator== ( const Strided_Vector_Shape shape,
const Shape< 1 > &  other 
)
friend

Member Data Documentation

◆ m_block_shape

bc::Dim<1> bc::Strided_Vector_Shape::m_block_shape = {1}

◆ m_inner_shape

bc::Dim<1> bc::Strided_Vector_Shape::m_inner_shape = {0}

◆ tensor_dim

constexpr int bc::Strided_Vector_Shape::tensor_dim = 1
static

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