#include <Shape.h>
|
| Shape (size_t rank) noexcept |
|
| Shape (std::initializer_list< size_t > list) noexcept |
|
size_t | dim (int i) const noexcept |
|
size_t & | dim (int i) noexcept |
|
size_t | element_count () const noexcept |
|
size_t | rank () const noexcept |
|
Definition at line 29 of file Shape.h.
◆ Shape() [1/2]
ndarray::Shape::Shape |
( |
size_t |
rank | ) |
|
|
inlineexplicitnoexcept |
Definition at line 34 of file Shape.h.
34 : _dims{}, _rank(
rank)
35 {
36 std::fill(_dims.begin(), _dims.end(), 0);
37 }
size_t rank() const noexcept
◆ Shape() [2/2]
ndarray::Shape::Shape |
( |
std::initializer_list< size_t > |
list | ) |
|
|
inlinenoexcept |
Definition at line 39 of file Shape.h.
39 : _dims{}, _rank(list.size())
40 {
41 std::copy(list.begin(), list.end(), _dims.begin());
42 }
◆ dim() [1/2]
size_t ndarray::Shape::dim |
( |
int |
i | ) |
const |
|
inlinenoexcept |
◆ dim() [2/2]
size_t & ndarray::Shape::dim |
( |
int |
i | ) |
|
|
inlinenoexcept |
Definition at line 46 of file Shape.h.
46{ return _dims.at(i); }
◆ element_count()
size_t ndarray::Shape::element_count |
( |
| ) |
const |
|
inlinenoexcept |
◆ rank()
size_t ndarray::Shape::rank |
( |
| ) |
const |
|
inlinenoexcept |
The documentation for this class was generated from the following file:
- runtime/libs/ndarray/include/ndarray/Shape.h