added simple printing of weights
add l2 regularization
remove tol