# HG changeset patch # User Jeff Hammel # Date 1504137903 25200 # Node ID 1214c127fe43415e1d6a67f9fd5f5297923a1ccc # Parent 92a402736bcc4cabc10089451006609cb6e997f5 steps towards logistic regression diff -r 92a402736bcc -r 1214c127fe43 tvii/dot.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tvii/dot.py Wed Aug 30 17:05:03 2017 -0700 @@ -0,0 +1,8 @@ +""" +dot product +""" + +def dot(w, x): + """inner dot product""" + + raise NotImplementedError('TODO') diff -r 92a402736bcc -r 1214c127fe43 tvii/logistic_regression.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tvii/logistic_regression.py Wed Aug 30 17:05:03 2017 -0700 @@ -0,0 +1,5 @@ +""" +z = w'x + b +a = sigmoid(z) +L(a,y) = -(y*log(a) + (1-y)*log(1-a)) +"""