- Description: Performs root mean square layer normalization (RMSNorm), a normalization method widely used in large language models. Unlike LayerNorm, RMSNorm omits mean subtraction. The AddRmsNorm operator fuses the preceding Add operator with RMSNorm to reduce data movement operations.
- Formula:
Each operator has calls. First, aclnnInplaceAddRmsNormGetWorkspaceSize is called to obtain the input parameters and compute the required workspace size based on the process. Then, aclnnInplaceAddRmsNorm is called to perform computation.
[object Object]
[object Object]
Parameters
[object Object]- [object Object]Atlas inference products[object Object]
- The data types of x1Ref, x2Ref, and gamma cannot be BFLOAT16.
- The parameter
[object Object]is invalid in current product usage scenarios.
- [object Object]Atlas inference products[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]
- Boundary value scenarios:
- When the input is
[object Object], the output is[object Object]. - When the input is
[object Object], the output is[object Object].
- When the input is
- Deterministic computation:
- aclnnInplaceAddRmsNorm defaults to a deterministic implementation.
The following example is for reference only. For details, see .
[object Object]