Python wrappers
Public Python APIs implemented by this engine symbol.Autograd node for element-wise tangent .
Saves the input x so the backward pass can build in the
denominator. Defined for all real except the singular points
where ; behaviour at those
points is undefined.
Math
\frac{\partial y}{\partial x} = \sec^2(x) = \frac{1}{\cos^2(x)}, \qquad \frac{\partial \mathcal{L}}{\partial x} = \frac{1}{\cos^2(x)}\,\frac{\partial \mathcal{L}}{\partial y}.$$Attributes
schema_v1OpSchemaRegistered as
"tan" with AmpPolicy::Promote.Notes
Dispatch: Accelerate vvtanf/vvtan (CPU) / MLX tan (GPU).