Question: ( 4 0 points ) A Python Implementation of Stochastic Gradient Descent. Assume we are given a data set S = { ( x i
points A Python Implementation of Stochastic Gradient Descent.
Assume we are given a data set
and wish to fit a linear regression predictor for some parameters Recall that stochastic gradient descent is defined similarly to gradient descent, except that the update step to the current set of parameters is based off a single training point That is the algorithm takes successive passes over that data set and updates according to the rule
:
This problem will have you implement stochastic gradient descent by modifying code in the attached file hwproblempy You will need to submit a modified version huproblem py that has the appropriate code filled in
The implementation that you submit will be tested through Python unit tests executed by the file testhwproblempy The test file is attached and may be used to check your progress. In a terminal navigate to the directory containing both Python files and run the command python testhuproblempy to execute the tests.
However, you should not modify the test file as it will not be part of your submission. In addition, your implementation will be graded based upon inspection of the completed Python functions and not just passing the unit tests.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
