Andrew Ng
Exponentially weighted averages
days
temperature
!"=$!"%&+(1−$),"
Andrew Ng
Exponentially weighted averages
!"##=0.9!((+0.1+"##
!((=0.9!(,+0.1+((
!(,=0.9!(-+0.1+(,
…
!/=0!/1"+(1−0)+/
Andrew Ng
Implementing exponentially weighted
averages
!"=0
!%=&!"+(1−&) -%
…
!/=&!%+(1−&) -/
!0=&!/+(1−&) -0
Optimization
Algorithms
Bias correction
in exponentially
weighted average
deeplearning.ai
Andrew Ng
Bias correction
days
temperature
!"=$!"%&+(1−$),"
Optimization
Algorithms
Gradient descent
with momentum
deeplearning.ai
Andrew Ng
Gradient descent example
Andrew Ng
Implementation details
!"#=%!"#+1−%)*
!"+=%!"++1−%),
*=*−-!"#,
Hyperparameters: -,%
On iteration 8:
Compute)*,), on the current mini-batch
,=,−-!"+
%=0.9
Optimization
Algorithms
RMSprop
deeplearning.ai
Andrew Ng
RMSprop
Optimization
Algorithms
Adam optimization
algorithm
deeplearning.ai
Andrew Ng
Adam optimization algorithm
yhat= np.array([.9, 0.2, 0.1, .4, .9])