Skip to content

Instantly share code, notes, and snippets.

@curiousily
Created April 1, 2019 21:19
Show Gist options
  • Save curiousily/738a8ea73694525ee86683377927098e to your computer and use it in GitHub Desktop.
Save curiousily/738a8ea73694525ee86683377927098e to your computer and use it in GitHub Desktop.
class TestLinearRegression(unittest.TestCase):
def test_find_coefficients(self):
clf = LinearRegression()
clf.fit(x, y, n_iter=2000, lr=0.01)
np.testing.assert_array_almost_equal(clf._W, np.array([180921.19555322, 56294.90199925]))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment