Machine Learning, Data Science, Artificial Intelligence, Programming, Technology.
curve_fit(sigmoid, train_x, train_y) # Remember popt saves the ideal parameters from curve_fit method # While pcov stores the covariance print('Ideal params are: ', popt) >> Ideal params are: [670.91888462 0.99708276] Now, we make the predictions using the test set y_hat = sigmoid(test_x, *popt) #