FP32 convolution framework
A framework to accelerate FP32 convolution in Synet Framework. More...
Functions | |
SIMD_API void * | SimdSynetConvolution32fInit (size_t batch, const SimdConvolutionParameters *conv) |
Initilizes FP32 convolution algorithm. More... | |
SIMD_API size_t | SimdSynetConvolution32fExternalBufferSize (const void *context) |
Gets size of external temporary buffer required for FP32 convolution algorithm. More... | |
SIMD_API size_t | SimdSynetConvolution32fInternalBufferSize (const void *context) |
Gets size of internal buffer used inside FP32 convolution algorithm. More... | |
SIMD_API const char * | SimdSynetConvolution32fInfo (const void *context) |
Gets description of internal implementation of FP32 convolution algorithm. More... | |
SIMD_API void | SimdSynetConvolution32fSetParams (void *context, const float *weight, SimdBool *internal, const float *bias, const float *params) |
Sets weights, biases and parameters of activation function required for FP32 convolution algorithm. More... | |
SIMD_API void | SimdSynetConvolution32fForward (void *context, const float *src, float *buf, float *dst) |
Performs forward propagation of FP32 convolution algorithm. More... | |
Detailed Description
A framework to accelerate FP32 convolution in Synet Framework.
Function Documentation
◆ SimdSynetConvolution32fInit()
void * SimdSynetConvolution32fInit | ( | size_t | batch, |
const SimdConvolutionParameters * | conv | ||
) |
Initilizes FP32 convolution algorithm.
- Parameters
-
[in] batch - a batch size. [in] conv - a pointer to convolution parameters.
- Returns
- a pointer to FP32 convolution context. On error it returns NULL. It must be released with using of function SimdRelease. This pointer is used in functions SimdSynetConvolution32fExternalBufferSize, SimdSynetConvolution32fInternalBufferSize, SimdSynetConvolution32fInfo, SimdSynetConvolution32fSetParams and SimdSynetConvolution32fForward.
◆ SimdSynetConvolution32fExternalBufferSize()
size_t SimdSynetConvolution32fExternalBufferSize | ( | const void * | context | ) |
Gets size of external temporary buffer required for FP32 convolution algorithm.
- Parameters
-
[in] context - a pointer to FP32 convolution context. It must be created by function SimdSynetConvolution32fInit and released by function SimdRelease.
- Returns
- size of external temporary buffer required for FP32 convolution algorithm.
◆ SimdSynetConvolution32fInternalBufferSize()
size_t SimdSynetConvolution32fInternalBufferSize | ( | const void * | context | ) |
Gets size of internal buffer used inside FP32 convolution algorithm.
- Parameters
-
[in] context - a pointer to FP32 convolution context. It must be created by function SimdSynetConvolution32fInit and released by function SimdRelease.
- Returns
- size of internal buffer used inside FP32 convolution algorithm.
◆ SimdSynetConvolution32fInfo()
const char * SimdSynetConvolution32fInfo | ( | const void * | context | ) |
Gets description of internal implementation of FP32 convolution algorithm.
- Parameters
-
[in] context - a pointer to FP32 convolution context. It must be created by function SimdSynetConvolution32fInit and released by function SimdRelease.
- Returns
- string with description of internal implementation of FP32 convolution algorithm.
◆ SimdSynetConvolution32fSetParams()
void SimdSynetConvolution32fSetParams | ( | void * | context, |
const float * | weight, | ||
SimdBool * | internal, | ||
const float * | bias, | ||
const float * | params | ||
) |
Sets weights, biases and parameters of activation function required for FP32 convolution algorithm.
- Parameters
-
[in,out] context - a pointer to FP32 convolution context. It must be created by function SimdSynetConvolution32fInit and released by function SimdRelease. [in] weight - a pointer to convolution weights. [out] internal - a flag signalized that weight is stored in the internal buffer. Can be NULL. [in] bias - a pointer to bias. Can be NULL. [in] params - a pointer to parameters of activation functions (see SimdConvolutionActivationType). Can be NULL.
◆ SimdSynetConvolution32fForward()
void SimdSynetConvolution32fForward | ( | void * | context, |
const float * | src, | ||
float * | buf, | ||
float * | dst | ||
) |
Performs forward propagation of FP32 convolution algorithm.
- Parameters
-
[in] context - a pointer to FP32 convolution context. It must be created by function SimdSynetConvolution32fInit and released by function SimdRelease. [in] src - a pointer to input tensor. [out] buf - a pointer to external temporary buffer. The size of the external temporary buffer is determined by function SimdSynetConvolution32fExternalBufferSize. Can be NULL (it causes usage of internal buffer). [out] dst - a pointer to output tensor.