What is the parameter update rule for gradient descent?
Gradient descent is an optimization algorithm used to minimize a cost function by iteratively updating the model parameters in the opposite direction of the gradient of the cost function with respect to those parameters.
Conditions
- The cost function J must be differentiable with respect to the parameters .
- The learning rate must be chosen appropriately to ensure convergence.
Reasoning, step by step
- Identify the current parameter value .
- Calculate the partial derivative of the cost function with respect to : .
- Multiply the gradient by the learning rate .
- Subtract this product from the current parameter value.
- The update rule is .
Example
The video displays the general update rule on-screen as "" and later shows the specific rules for two parameters in linear regression.
Common misconceptions
- Assuming the update adds the gradient rather than subtracting it; gradient descent moves in the opposite direction of the gradient to minimize the cost function.
- Forgetting the learning rate , which controls the step size of the update.
Watch the explanation
3:12 – 3:36Watch this moment ↗
Explore next
Answers are generated from source material and independently checked. Consult the original video or creator if something is unclear.