Skip to content
fn

hypot_op

→TensorImplPtr
int hypot_op(const int & a, const int & b)

Python wrappers

Public Python APIs implemented by this engine symbol.

Pythagorean length: y=a2+b2y = \sqrt{a^2 + b^2}.

Composite over square_op + add_op + sqrt_op. Naive formulation — does not perform IEEE-754 overflow-safe scaling (i.e. no max⁡(∣a∣,∣b∣)⋅1+(min⁡/max⁡)2\max(|a|, |b|) \cdot \sqrt{1 + (\min / \max)^2} trick), matching the engine's square_op precision.

Math

y=a2+b2 y = \sqrt{a^2 + b^2}

Parameters

a, bTensorImplPtr
Broadcastable operands.

Returns

TensorImplPtr

Tensor on the broadcast shape; values ≥0\ge 0.

Notes

Inputs near the float dtype's overflow threshold may lose precision — prefer a dedicated hypot kernel for safety-critical paths.