TensorPlay
latest (dev)
Copy
View Markdown

Latest development documentation · Updated 2026-10-15

tensorplay.nn.functional.huber_loss

tensorplay.nn.functional.huber_loss(input: Tensor, target: Tensor, reduction: str = 'mean', delta: float = 1.0, weight: Tensor | None = None) → Tensor[source]

Compute the Huber loss, with optional weighting.

Function uses a squared term if the absolute error falls below delta and a delta-scaled L1 term otherwise. See HuberLoss for details.

On this page

Ask DeepWiki