Function arm_nn_mat_mult_nt_t_s16

Function Documentation

arm_cmsis_nn_status arm_nn_mat_mult_nt_t_s16(const int16_t *lhs, const int8_t *rhs, const cmsis_nn_bias_data *bias_data, int16_t *dst, const int32_t *dst_multipliers, const int32_t *dst_shifts, const int32_t lhs_rows, const int32_t rhs_rows, const int32_t rhs_cols, const int32_t activation_min, const int32_t activation_max, const int32_t row_address_offset)

General Matrix-multiplication function with per-channel requantization and int16 input (LHS) and output. This function assumes:

  • LHS input matrix NOT transposed (nt)

  • RHS input matrix transposed (t)

MVE implementation only.

Note

This operation also performs the broadcast bias addition before the requantization

Parameters:
  • lhs[in] Pointer to the LHS input matrix

  • rhs[in] Pointer to the RHS input matrix

  • bias_data[in] Pointer to struct with bias vector. The length of this vector is equal to the number of output columns (or RHS input rows). The vector can be int32 or int64 indicated by a flag in the struct.

  • dst[out] Pointer to the output matrix with “m” rows and “n” columns

  • dst_multipliers[in] Pointer to the multipliers vector needed for the per-channel requantization. The length of this vector is equal to the number of output columns (or RHS input rows)

  • dst_shifts[in] Pointer to the shifts vector needed for the per-channel requantization. The length of this vector is equal to the number of output columns (or RHS input rows)

  • lhs_rows[in] Number of LHS input rows

  • rhs_rows[in] Number of RHS input rows

  • rhs_cols[in] Number of LHS/RHS input columns

  • activation_min[in] Minimum value to clamp down the output. Range : int16

  • activation_max[in] Maximum value to clamp up the output. Range : int16

  • row_address_offset[in] Address offset between rows in output. NOTE: Only used for MVEI extension.

Returns:

The function returns ARM_CMSIS_NN_SUCCESS or ARM_CMSIS_NN_NO_IMPL_ERROR if not for MVE |——row_address_offset——| |____rhs_rows__________________|

| | | lhs_rows

_______________

______________