Function arm_prelu_s16

Function Documentation

arm_cmsis_nn_status arm_prelu_s16(const cmsis_nn_dims *input_dims, const int16_t *input, const cmsis_nn_dims *alpha_dims, const int16_t *alpha, const int32_t input_offset, const int32_t alpha_offset, const int32_t output_offset, const int32_t output_multiplier_identity, const int32_t output_shift_identity, const int32_t output_multiplier_alpha, const int32_t output_shift_alpha, const cmsis_nn_dims *output_dims, int16_t *output)

S16 PReLU activation function.

Parameters:
  • input_dims[in] Input (activation) tensor dimensions. Format: [N, H, W, C_IN]

  • input[in] Pointer to the input buffer

  • alpha_dims[in] Alpha tensor dimensions. Format: [N, H, W, C]

  • alpha[in] Pointer to the alpha buffer

  • input_offset[in] Input tensor zero offset

  • alpha_offset[in] Alpha tensor zero offset

  • output_offset[in] Output tensor zero offset

  • output_multiplier_identity[in] Output multiplier when input >= 0

  • output_shift_identity[in] Output shift when input >= 0

  • output_multiplier_alpha[in] Output multiplier when input < 0

  • output_shift_alpha[in] Output shift when input < 0

  • output_dims[in] Output tensor dimensions. Format: [N, H, W, C_OUT]

  • output[out] Pointer to the output buffer

Returns:

ARM_CMSIS_NN_SUCCESS on success, or ARM_CMSIS_NN_ARG_ERROR if the output dimensions do not match the input dimensions