O'Reilly logo
  • Thierry Herrmann thinks this is interesting:

Y_prev = Yt.copy()

From

Cover of Mastering Machine Learning Algorithms

Note

Y_prev = Yt.copy() should be done before calculating Yt. The code here does not iterate because the norm of Yt-Y_prev is always 0.

See pull request https://github.com/giuseppebonaccorso/Mastering-Machine-Learning-Algorithms/pull/1