What is Gradient Descent and how does it optimize neural networks?

Updated May 16, 2026

Short answer

Gradient Descent is an optimization algorithm that iteratively updates model parameters in the direction of the negative gradient of the loss function to minimize error.

Deep explanation

Gradient Descent is the fundamental optimization method used to train neural networks by minimizing a loss function.

Core idea:

  • Compute gradient of loss w.r.t. parameters.
  • Move parameters in opposite direction of gradient.

Mathematical form: θ = θ - η ∇L(θ)

Where:

  • θ = parameters
  • η = learning rate
  • ∇L = gradient of loss

Why it works:

  • Gradient points in direction of steepest increase.
  • Moving opposite reduces loss.

Types:

  1. Batch Gradient Descent:
  • Uses full dataset.
  • Stable but slow.
  1. Stochastic Gradient Descent (SGD):
  • Uses one sample at a time.
  • Fast but noisy.

3.…

Unlock with a Pro subscription to view this section.

View pricing

Real-world example

No real-world example available yet.

Unlock with a Pro subscription to view this section.

Upgrade to Pro

Common mistakes

No common mistakes listed yet.

Unlock with a Pro subscription to view this section.

Upgrade to Pro

Follow-up questions

No follow-up questions available yet.

Unlock with a Pro subscription to view this section.

Upgrade to Pro

More Deep Learning interview questions

View all →