Batch Gradient Descent Python