[object Object]

[object Object][object Object]undefined
[object Object]
  • Description: Implements grouped matrix multiplication, supporting non-uniform matrix dimension sizes across multiple groups. The basic function is matrix multiplication, for example, yi[mi,ni]=xi[mi,ki]×weighti[ki,ni]+yi[mi,ni],i=1...gy_i[m_i,n_i]=x_i[m_i,k_i] \times weight_i[k_i,n_i]+y_i[m_i,n_i], i=1...g, where gg indicates the number of groups and mim_i, kik_i, and nin_i define the shapes for each group. The input and output data types are both aclTensor, with K-axis grouping.

    • K-axis grouping: kik_i can vary, while mim_i and nin_i remain the same for each group.
    • Compared with the API, the following functions are added:
      • The value in groupList can be the size of each group on the group axis.
  • Formulas:

    yRefi=xi×weighti+yiyRef_i=x_i\times weight_i + y_i
[object Object]

Each operator has calls. First, [object Object] is called to obtain the input parameters and compute the required workspace size based on the process. Then, [object Object] is called to perform computation.

[object Object]
[object Object]
[object Object]
  • Parameters:

    [object Object]
  • Returns

    [object Object]: status code. For details, see .

    The first-phase API implements input parameter validation. The following error codes may be returned.

    [object Object]
[object Object]
  • Parameters:

    [object Object]
  • Returns

    [object Object]: status code. For details, see .

[object Object]
  • Deterministic description: The default deterministic implementation of aclnnGroupedMatmulAddV2 is used.
  • The size of each dimension for every tensor in [object Object] and [object Object], after 32-byte alignment, should be less than the maximum value of INT32 (2147483647).
  • The supported input type combinations are as follows:
    • [object Object]: FLOAT16; [object Object]: FLOAT16; [object Object]: FLOAT32
    • [object Object]: BFLOAT16; [object Object]: BFLOAT16; [object Object]: FLOAT32
[object Object]

The following example is for reference only. For details, see .

[object Object]