Function arm_nn_mat_mult_nt_t_1x1_out_s8

Function Documentation

arm_cmsis_nn_status arm_nn_mat_mult_nt_t_1x1_out_s8(const int32_t *weight_sum_buf, const int8_t *lhs, const int8_t *rhs, const int32_t *bias, int8_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 lhs_offset, const int32_t dst_offset, const int32_t activation_min, const int32_t activation_max, const int32_t row_address_offset, const int32_t lhs_cols_offset)

General Matrix-multiplication function with per-channel requantization. Output is calculated with multiple channels in parallel, rather than multiple output indices in a single channel This function assumes:

  • LHS input matrix NOT transposed (nt)

  • RHS input matrix transposed (t)

Note

This operation also performs the broadcast bias addition before the requantization

Parameters:
  • weight_sum_buf[in] Pointer to the weight sum multiplied by lhs_offset and summed bias buffer

  • lhs[in] Pointer to the LHS input matrix

  • rhs[in] Pointer to the RHS input matrix

  • bias[in] Pointer to the bias vector. The length of this vector is equal to the number of output columns (or RHS input rows)

  • 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

  • lhs_offset[in] Offset to be applied to the LHS input value

  • dst_offset[in] Offset to be applied the output result

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

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

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

  • lhs_cols_offset[in] Column offset between subsequent lhs_rows

Returns:

The function returns ARM_CMSIS_NN_SUCCESS