Description: If
[object Object]= 0, performs the Softmax operation on the output of[object Object]before obtaining the topK value. If renorm = 1, performs the Softmax operation on the output of[object Object]after obtaining the topK value.[object Object]is the topK result of softmax.[object Object]is the index result of the topK value, that is, the corresponding expert sequence number. If the corresponding row finished is[object Object], the expert sequence number is directly filled with the value of[object Object](that is, the size of the last axis of[object Object]).Formula:
renorm = 0,
renorm = 1
Each operator has calls. First, [object Object] is called to obtain the workspace size required for computation and the executor that contains the operator computation process. Then, [object Object] is called to perform computation.
Parameters:
[object Object]Returns:
[object Object]: status code. For details, see .The first-phase API performs input parameter validation. The following errors may be returned:
[object Object]
- Deterministic computation:
[object Object]defaults to a deterministic implementation.
The following example is for reference only. For details, see .