24.02
|
A ViewsDescriptor for the SplitterLayer. More...
#include <Descriptors.hpp>
Public Member Functions | |
ViewsDescriptor (uint32_t numViews, uint32_t numDimensions=4) | |
ViewsDescriptor (const ViewsDescriptor &other) | |
ViewsDescriptor () | |
ViewsDescriptor (ViewsDescriptor &&other) | |
~ViewsDescriptor () | |
ViewsDescriptor & | operator= (ViewsDescriptor rhs) |
bool | operator== (const ViewsDescriptor &rhs) const |
Status | SetViewOriginCoord (uint32_t view, uint32_t coord, uint32_t value) |
@Brief Set the view origin coordinates. More... | |
Status | SetViewSize (uint32_t view, uint32_t coord, uint32_t value) |
Set the size of the views. More... | |
uint32_t | GetNumViews () const |
Get the number of views. More... | |
uint32_t | GetNumDimensions () const |
Get the number of dimensions. More... | |
const uint32_t * | GetViewOrigin (uint32_t idx) const |
Get the view origin at the int value idx. More... | |
const uint32_t * | GetViewSizes (uint32_t idx) const |
Get the view sizes at the int value idx. More... | |
const OriginsDescriptor & | GetOrigins () const |
Get the View Origins. More... | |
void | SetAxis (int32_t axis) |
Set the axis value. More... | |
int32_t | GetAxis () const |
Get the axis value. More... | |
bool | HasAxis () const |
Returns true if an axis has been set. More... | |
Public Member Functions inherited from BaseDescriptor | |
virtual bool | IsNull () const |
virtual | ~BaseDescriptor ()=default |
Friends | |
void | swap (ViewsDescriptor &first, ViewsDescriptor &second) |
Swap the ViewsDescriptor value first and second. More... | |
A ViewsDescriptor for the SplitterLayer.
Descriptor to configure the splitting process. Number of Views must be equal to the number of outputs, and their order must match - e.g. first view corresponds to the first output, second view to the second output, etc.
Definition at line 244 of file Descriptors.hpp.
ViewsDescriptor | ( | uint32_t | numViews, |
uint32_t | numDimensions = 4 |
||
) |
Definition at line 223 of file Descriptors.cpp.
References ViewsDescriptor::GetNumDimensions(), and ViewsDescriptor::GetNumViews().
ViewsDescriptor | ( | const ViewsDescriptor & | other | ) |
Definition at line 239 of file Descriptors.cpp.
References ViewsDescriptor::GetNumDimensions(), and ViewsDescriptor::GetNumViews().
ViewsDescriptor | ( | ) |
Definition at line 216 of file Descriptors.cpp.
ViewsDescriptor | ( | ViewsDescriptor && | other | ) |
Definition at line 256 of file Descriptors.cpp.
References ViewsDescriptor::swap.
~ViewsDescriptor | ( | ) |
Definition at line 262 of file Descriptors.cpp.
References ViewsDescriptor::GetNumDimensions(), and ViewsDescriptor::GetNumViews().
int32_t GetAxis | ( | ) | const |
Get the axis value.
Definition at line 381 of file Descriptors.cpp.
Referenced by armnn::ComputeSplitAxis(), and StringifyLayerParameters< ViewsDescriptor >::Serialize().
uint32_t GetNumDimensions | ( | ) | const |
Get the number of dimensions.
Definition at line 306 of file Descriptors.cpp.
References OriginsDescriptor::GetNumDimensions().
Referenced by ClSplitterWorkload::ClSplitterWorkload(), armnn::ComputeSplitAxis(), SplitterLayer::CreateWorkload(), SplitterLayer::InferOutputShapes(), ClLayerSupport::IsSplitterSupported(), NeonLayerSupport::IsSplitterSupported(), NeonSplitterWorkload::NeonSplitterWorkload(), ViewsDescriptor::operator==(), StringifyLayerParameters< ViewsDescriptor >::Serialize(), ViewsDescriptor::SetViewSize(), SplitterLayer::ValidateTensorShapesFromInputs(), ViewsDescriptor::ViewsDescriptor(), and ViewsDescriptor::~ViewsDescriptor().
uint32_t GetNumViews | ( | ) | const |
Get the number of views.
Definition at line 301 of file Descriptors.cpp.
References OriginsDescriptor::GetNumViews().
Referenced by armnn::ComputeSplitAxis(), SplitterLayer::CreateWorkload(), SplitterLayer::InferOutputShapes(), ViewsDescriptor::operator==(), StringifyLayerParameters< ViewsDescriptor >::Serialize(), ViewsDescriptor::SetViewSize(), SplitterLayer::ValidateTensorShapesFromInputs(), ViewsDescriptor::ViewsDescriptor(), and ViewsDescriptor::~ViewsDescriptor().
const OriginsDescriptor & GetOrigins | ( | ) | const |
Get the View Origins.
Definition at line 351 of file Descriptors.cpp.
Referenced by StringifyLayerParameters< ViewsDescriptor >::Serialize().
const uint32_t * GetViewOrigin | ( | uint32_t | idx | ) | const |
Get the view origin at the int value idx.
Definition at line 311 of file Descriptors.cpp.
References OriginsDescriptor::GetViewOrigin().
Referenced by SplitterLayer::CreateWorkload(), and ViewsDescriptor::operator==().
const uint32_t * GetViewSizes | ( | uint32_t | idx | ) | const |
Get the view sizes at the int value idx.
Definition at line 346 of file Descriptors.cpp.
Referenced by armnn::ComputeSplitAxis(), SplitterLayer::InferOutputShapes(), ViewsDescriptor::operator==(), StringifyLayerParameters< ViewsDescriptor >::Serialize(), and SplitterLayer::ValidateTensorShapesFromInputs().
bool HasAxis | ( | ) | const |
Returns true if an axis has been set.
Definition at line 387 of file Descriptors.cpp.
Referenced by armnn::ComputeSplitAxis(), and StringifyLayerParameters< ViewsDescriptor >::Serialize().
ViewsDescriptor & operator= | ( | ViewsDescriptor | rhs | ) |
Definition at line 274 of file Descriptors.cpp.
References ViewsDescriptor::swap.
bool operator== | ( | const ViewsDescriptor & | rhs | ) | const |
Definition at line 280 of file Descriptors.cpp.
References ViewsDescriptor::GetNumDimensions(), ViewsDescriptor::GetNumViews(), ViewsDescriptor::GetViewOrigin(), and ViewsDescriptor::GetViewSizes().
void SetAxis | ( | int32_t | axis | ) |
Set the axis value.
Definition at line 374 of file Descriptors.cpp.
Status SetViewOriginCoord | ( | uint32_t | view, |
uint32_t | coord, | ||
uint32_t | value | ||
) |
@Brief Set the view origin coordinates.
The arguments are: view, dimension, value. If the view is greater than or equal to GetNumViews(), then the view argument is out of range. If the coord is greater than or equal to GetNumDimensions(), then the coord argument is out of range.
Definition at line 316 of file Descriptors.cpp.
References OriginsDescriptor::SetViewOriginCoord().
Status SetViewSize | ( | uint32_t | view, |
uint32_t | coord, | ||
uint32_t | value | ||
) |
Set the size of the views.
The arguments are: view, dimension, value. If the view is greater than or equal to GetNumViews(), then the view argument is out of range. If the coord is greater than or equal to GetNumDimensions(), then the coord argument is out of range.
Definition at line 321 of file Descriptors.cpp.
References ARMNN_LOG, armnn::error, armnn::Failure, ViewsDescriptor::GetNumDimensions(), ViewsDescriptor::GetNumViews(), and armnn::Success.
|
friend |
Swap the ViewsDescriptor value first and second.
Definition at line 365 of file Descriptors.cpp.
Referenced by ViewsDescriptor::operator=(), and ViewsDescriptor::ViewsDescriptor().