¡@

Home 

python Programming Glossary: theta2

How to create a simple Gradient Descent algorithm

http://stackoverflow.com/questions/3837692/how-to-create-a-simple-gradient-descent-algorithm

step 0.0001 dthresh 0.1 import random theta1 random.random theta2 random.random theta0 random.random while derror dthresh diff.. while derror dthresh diff 400 theta0 2104 theta1 3 theta2 theta0 theta0 step diff 1 theta1 theta1 step diff 2104 theta2.. theta0 theta0 step diff 1 theta1 theta1 step diff 2104 theta2 theta2 step diff 3 hserror diff 2 2 derror abs error hserror..