erse of regularization
        alphas = np.flip(np.logspace(-4, 4, num=100, base=10))

    # alphas are sorted from highest to lowest regularization
    for i, alpha in enumerate(alphas):

        if prediction_task == &#39;regression&#39;:
            m = Lasso(alpha=alpha, random_state=random_state, max_iter=2000)
            cv_scoring = &#39;neg_mean_squared_error&#39;
        else:
            m = LogisticRegression(
                penalty=penalty, C=(1 / alpha), solver=&#39;liblinear&#39;, random_sta