Compute Library
18.05
|
Basic function to perform a L2 normalization on a given axis. More...
#include <NEL2NormalizeLayer.h>
Public Member Functions | |
NEL2NormalizeLayer (std::shared_ptr< IMemoryManager > memory_manager=nullptr) | |
Constructor. More... | |
void | configure (ITensor *input, ITensor *output, unsigned int axis, float epsilon=1e-12) |
Set the input and output tensors. More... | |
void | run () override |
Run the kernels contained in the function. More... | |
Public Member Functions inherited from IFunction | |
virtual | ~IFunction ()=default |
Destructor. More... | |
virtual void | prepare () |
Prepare the function for executing. More... | |
Static Public Member Functions | |
static Status | validate (const ITensorInfo *input, const ITensorInfo *output, unsigned int axis, float epsilon=1e-12) |
Static function to check if given info will lead to a valid configuration of NEL2NormalizeLayer. More... | |
Basic function to perform a L2 normalization on a given axis.
This function runs the following kernels:
Definition at line 46 of file NEL2NormalizeLayer.h.
NEL2NormalizeLayer | ( | std::shared_ptr< IMemoryManager > | memory_manager = nullptr | ) |
Constructor.
Set the input and output tensors.
[in,out] | input | Source tensor. Data types supported: F32. Data layouts supported: NCHW. (Written to only for border_size != 0) |
[out] | output | Destination tensor. Data types and data layouts supported: same as input . |
[in] | axis | Dimension along which to reduce. Supported reduction axis : 0 |
[in] | epsilon | (Optional) Lower bound value for the normalization. |
|
overridevirtual |
Run the kernels contained in the function.
For NEON kernels:
For OpenCL kernels:
Implements IFunction.
|
static |
Static function to check if given info will lead to a valid configuration of NEL2NormalizeLayer.
[in] | input | Source tensor info. Data types supported: F32. Data layouts supported: NCHW. (Written to only for border_size != 0) |
[in] | output | Destination tensor info. Data types and data layouts supported: same as input . |
[in] | axis | Dimension along which to reduce. Supported reduction axis : 0 |
[in] | epsilon | (Optional) Lower bound value for the normalization. |