Args: X (np.ndarray): Training data of shape[n_samples, n_features] y (np.ndarray): Target values of shape[n_samples, 1] gradient (function): Function to compute the gradient Gradient is a function of (X, y, weights) cost (function): Cost function (re
(X, y, gradient, cost=None, alpha=0.01, iterations=10000,
initial_weights=None, stochastic=False, reg_param=0,
backtrack_line_search=False, backtrack_alpha=0.5,
backtrack_beta=0.5)