Python wrappers
Public Python APIs implemented by this engine symbol.Autograd node for the element-wise square root .
Saves the output because the backward formula is cheaper and numerically identical to recomputing . Defined for ; negative inputs produce NaN.
Math
\frac{\partial y}{\partial x} = \frac{1}{2\sqrt{x}} = \frac{1}{2y}, \qquad \frac{\partial \mathcal{L}}{\partial x} = \frac{1}{2y}\,\frac{\partial \mathcal{L}}{\partial y}, \quad x \geq 0.$$Attributes
schema_v1OpSchemaRegistered as
"sqrt" with AmpPolicy::Promote.kSavesInputboolfalse.kSavesOutputbooltrue — saved tensor is .Notes
Dispatch: Accelerate vvsqrtf/vvsqrt (CPU) / MLX sqrt (GPU).
Gradient is unbounded as .