Home Knowledge Base Cauchy loss

Cauchy loss (also called Lorentzian loss) is a highly robust loss function based on the Cauchy probability distribution — providing extreme resistance to outliers and anomalies through bounded influence of any error magnitude, making it ideal for datasets with heavy-tailed noise, extreme value pollution, or unknown outlier distributions.

What Is Cauchy Loss?

Cauchy loss is derived from the negative log-likelihood of the Cauchy probability distribution, a theoretically-grounded choice for systems where even very large errors should have bounded influence on parameter updates. Unlike MSE where large errors dominate (quadratic), and unlike Huber where large errors still grow linearly, Cauchy loss grows logarithmically — any error, no matter how large, contributes a bounded amount to the gradient.

Mathematical Definition

Cauchy loss formula:

L(x) = (c²/2) * log(1 + (x/c)²)

Where:
- x = error (y - ŷ)
- c = scale parameter controlling sensitivity

Key properties:

Why Cauchy Loss Matters

Cauchy vs Huber vs MSE: Outlier Sensitivity

Error MagnitudeMSEHuber (δ=1)Cauchy (c=1)
0.50.1250.1250.110
1.01.01.00.347
2.04.01.50.693
5.025.04.51.435
10.0100.09.52.137
100.010000.099.54.615

Cauchy remains bounded while Huber and MSE grow unboundedly.

Tuning the Scale Parameter c

Implementation

PyTorch:

def cauchy_loss(predictions, targets, c=1.0):
    errors = predictions - targets
    loss = (c**2 / 2) * torch.log(1 + (errors / c) ** 2)
    return loss.mean()

JAX:

import jax.numpy as jnp

def cauchy_loss(pred, target, c=1.0):
    error = pred - target
    return jnp.mean((c**2 / 2) * jnp.log(1 + (error / c)**2))

When to Use Cauchy Loss

Comparison to Alternatives

LossRobustnessConvexityInterpretabilitySpeed
MSENoneConvexSimpleFast
HuberModerateConvexClear cutoffFast
CauchyExtremeConvexTheory-basedFast
TukeyVery HighNon-convexHard rejectionSlower

Practical Applications

3D Computer Vision: Structure-from-motion where occasional faulty matches cause nonsensical depth estimates; Cauchy loss permits robust triangulation even with erroneous correspondence matches.

Depth Estimation: Monocular depth prediction where rare images contain strong artifacts (transparency, extreme lighting); Cauchy prevents outlier frames from corrupting learned depth relationships.

LiDAR Processing: Autonomous vehicles ignoring occasional reflector artifacts or multi-bounce returns that spoil density-based matching.

Audio Processing: Noise robustness in speech enhancement where occasional impulse noise spikes shouldn't destroy learned acoustic models.

Cauchy loss is the ultimate outlier-robust loss — providing theoretical grounding and practical robustness for datasets where extreme deviations must be tolerated, enabling principled learning from contaminated, heavy-tailed, or adversarially-perturbed data.

cauchy lossrobust lossoutlier resistant

Explore 500+ Semiconductor & AI Topics

From EUV lithography to CUDA optimization — search the full knowledge base or chat with our AI assistant.