PyTorch Optimizer Benchmark

Neural Canyon (Ai Generated)

Function Name: NeuralCanyon
Difficulty: Hard
Type: Continuous, Differentiable, Multi-Modal

Description

The Neural Canyon is a simulation of the loss landscapes frequently encountered in Deep Learning, specifically designed to mimic the “Narrow Valley” problem combined with saturated activations.

The function features a long, curving valley that follows a hyperbolic tangent ($\tanh$) path. This creates a specific challenge: as $x$ increases, the manifold flattens out, simulating the “vanishing gradient” problem found in saturated neural network layers. The landscape is further corrupted by “egg-crate” noise, simulating the stochastic variance of mini-batch training or architectural roughness.

Mathematical Composition

The function combines three terms:

  1. The Manifold (Tanh Valley): The valley follows the curve $y = \tanh(x)$. This creates a non-linear dependency. The walls are steep ($Wall \times (y - \text{path})^2$), forcing the optimizer to learn the relationship between parameters.
  2. Regularization: A weak global quadratic term ($Bias \times (x^2 + y^2)$) keeps the solution bounded, similar to L2 weight decay.
  3. Interference Noise: A noise term using $\cos(x)\cos(y)$ creates local minima. Crucially, this noise is essentially subtractive (digging holes) and is deepest near the center, making the final convergence step prone to getting stuck in sub-optimal “nearby” buckets.

Optimization Challenge