Logistic Regression from Scratch, with Nesterov Accelerated Descent#34
Open
stevenkolawole wants to merge 9 commits intoDataScienceNigeria:masterfrom
Open
Logistic Regression from Scratch, with Nesterov Accelerated Descent#34stevenkolawole wants to merge 9 commits intoDataScienceNigeria:masterfrom
stevenkolawole wants to merge 9 commits intoDataScienceNigeria:masterfrom
Conversation
A Customized Logistic Regression with Nesterov Accelerated Gradient with Early Stopping option: Nesterov Accelerated Gradient is theorized to converge by at least, a 10 times faster rate than Stochastic Gradient Descent, and over 25 times faster rate than the naive batch gradient descent. Nesterov Gradient combines the properties of Stochastic Gradient Descent -which supposedly have the properties that allows it to “jump” out of shallow local minima giving it a better chance of finding a true global minimum - with a 'smarter' momentum, that has a somewhat prescient notion of the global minimum, and knows to slow down before the hill slopes up again. But there is a catch; Converging too fast makes it easier for the model to overfit, causing the well-known bias-variance tradeoff. A way to avoid that is to introduce Early Stopping, which works by simply waiting for a certain number of epochs with no improvement in validation loss, and then stopping the iterations.
A Customized Logistic Regression with Nesterov Accelerated Gradient with Early Stopping option: Nesterov Accelerated Gradient is theorized to converge by at least, a 10 times faster rate than Stochastic Gradient Descent, and over 25 times faster rate than the naive batch gradient descent. Nesterov Gradient combines the properties of Stochastic Gradient Descent -which supposedly have the properties that allows it to “jump” out of shallow local minima giving it a better chance of finding a true global minimum- with a 'smarter' momentum, that has a somewhat prescient notion of the global minimum, and knows to slow down before the hill slopes up again. But there is a catch; Converging too fast makes it easier for the model to overfit, causing the well-known bias-variance tradeoff. My way of avoiding that is to introduce Early Stopping, which works by simply waiting for a certain number of epochs with no improvement in validation loss.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.