
.. DO NOT EDIT.
.. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY.
.. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE:
.. "auto_examples/decomposition/plot_faces_decomposition.py"
.. LINE NUMBERS ARE GIVEN BELOW.

.. only:: html

    .. note::
        :class: sphx-glr-download-link-note

        :ref:`Go to the end <sphx_glr_download_auto_examples_decomposition_plot_faces_decomposition.py>`
        to download the full example code or to run this example in your browser via JupyterLite or Binder.

.. rst-class:: sphx-glr-example-title

.. _sphx_glr_auto_examples_decomposition_plot_faces_decomposition.py:


============================
Faces dataset decompositions
============================

This example applies to :ref:`olivetti_faces_dataset` different unsupervised
matrix decomposition (dimension reduction) methods from the module
:mod:`sklearn.decomposition` (see the documentation chapter
:ref:`decompositions`).

.. GENERATED FROM PYTHON SOURCE LINES 11-15

.. code-block:: Python


    # Authors: The scikit-learn developers
    # SPDX-License-Identifier: BSD-3-Clause








.. GENERATED FROM PYTHON SOURCE LINES 16-20

Dataset preparation
-------------------

Loading and preprocessing the Olivetti faces dataset.

.. GENERATED FROM PYTHON SOURCE LINES 20-45

.. code-block:: Python


    import logging

    import matplotlib.pyplot as plt
    from numpy.random import RandomState

    from sklearn import cluster, decomposition
    from sklearn.datasets import fetch_olivetti_faces

    rng = RandomState(0)

    # Display progress logs on stdout
    logging.basicConfig(level=logging.INFO, format="%(asctime)s %(levelname)s %(message)s")

    faces, _ = fetch_olivetti_faces(return_X_y=True, shuffle=True, random_state=rng)
    n_samples, n_features = faces.shape

    # Global centering (focus on one feature, centering all samples)
    faces_centered = faces - faces.mean(axis=0)

    # Local centering (focus on one sample, centering all features)
    faces_centered -= faces_centered.mean(axis=1).reshape(n_samples, -1)

    print("Dataset consists of %d faces" % n_samples)





.. rst-class:: sphx-glr-script-out

 .. code-block:: none

    Dataset consists of 400 faces




.. GENERATED FROM PYTHON SOURCE LINES 46-47

Define a base function to plot the gallery of faces.

.. GENERATED FROM PYTHON SOURCE LINES 47-79

.. code-block:: Python


    n_row, n_col = 2, 3
    n_components = n_row * n_col
    image_shape = (64, 64)


    def plot_gallery(title, images, n_col=n_col, n_row=n_row, cmap=plt.cm.gray):
        fig, axs = plt.subplots(
            nrows=n_row,
            ncols=n_col,
            figsize=(2.0 * n_col, 2.3 * n_row),
            facecolor="white",
            constrained_layout=True,
        )
        fig.get_layout_engine().set(w_pad=0.01, h_pad=0.02, hspace=0, wspace=0)
        fig.set_edgecolor("black")
        fig.suptitle(title, size=16)
        for ax, vec in zip(axs.flat, images):
            vmax = max(vec.max(), -vec.min())
            im = ax.imshow(
                vec.reshape(image_shape),
                cmap=cmap,
                interpolation="nearest",
                vmin=-vmax,
                vmax=vmax,
            )
            ax.axis("off")

        fig.colorbar(im, ax=axs, orientation="horizontal", shrink=0.99, aspect=40, pad=0.01)
        plt.show()









.. GENERATED FROM PYTHON SOURCE LINES 80-82

Let's take a look at our data. Gray color indicates negative values,
white indicates positive values.

.. GENERATED FROM PYTHON SOURCE LINES 82-85

.. code-block:: Python


    plot_gallery("Faces from dataset", faces_centered[:n_components])




.. image-sg:: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_001.png
   :alt: Faces from dataset
   :srcset: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_001.png
   :class: sphx-glr-single-img





.. GENERATED FROM PYTHON SOURCE LINES 86-95

Decomposition
-------------

Initialise different estimators for decomposition and fit each
of them on all images and plot some results. Each estimator extracts
6 components as vectors :math:`h \in \mathbb{R}^{4096}`.
We just displayed these vectors in human-friendly visualisation as 64x64 pixel images.

Read more in the :ref:`User Guide <decompositions>`.

.. GENERATED FROM PYTHON SOURCE LINES 97-108

Eigenfaces - PCA using randomized SVD
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Linear dimensionality reduction using Singular Value Decomposition (SVD) of the data
to project it to a lower dimensional space.


.. note::

    The Eigenfaces estimator, via the :py:mod:`sklearn.decomposition.PCA`,
    also provides a scalar `noise_variance_` (the mean of pixelwise variance)
    that cannot be displayed as an image.

.. GENERATED FROM PYTHON SOURCE LINES 110-118

.. code-block:: Python

    pca_estimator = decomposition.PCA(
        n_components=n_components, svd_solver="randomized", whiten=True
    )
    pca_estimator.fit(faces_centered)
    plot_gallery(
        "Eigenfaces - PCA using randomized SVD", pca_estimator.components_[:n_components]
    )




.. image-sg:: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_002.png
   :alt: Eigenfaces - PCA using randomized SVD
   :srcset: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_002.png
   :class: sphx-glr-single-img





.. GENERATED FROM PYTHON SOURCE LINES 119-123

Non-negative components - NMF
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Estimate non-negative original data as production of two non-negative matrices.

.. GENERATED FROM PYTHON SOURCE LINES 125-129

.. code-block:: Python

    nmf_estimator = decomposition.NMF(n_components=n_components, tol=5e-3)
    nmf_estimator.fit(faces)  # original non- negative dataset
    plot_gallery("Non-negative components - NMF", nmf_estimator.components_[:n_components])




.. image-sg:: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_003.png
   :alt: Non-negative components - NMF
   :srcset: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_003.png
   :class: sphx-glr-single-img





.. GENERATED FROM PYTHON SOURCE LINES 130-134

Independent components - FastICA
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Independent component analysis separates a multivariate vectors into additive
subcomponents that are maximally independent.

.. GENERATED FROM PYTHON SOURCE LINES 136-144

.. code-block:: Python

    ica_estimator = decomposition.FastICA(
        n_components=n_components, max_iter=400, whiten="arbitrary-variance", tol=15e-5
    )
    ica_estimator.fit(faces_centered)
    plot_gallery(
        "Independent components - FastICA", ica_estimator.components_[:n_components]
    )




.. image-sg:: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_004.png
   :alt: Independent components - FastICA
   :srcset: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_004.png
   :class: sphx-glr-single-img





.. GENERATED FROM PYTHON SOURCE LINES 145-152

Sparse components - MiniBatchSparsePCA
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Mini-batch sparse PCA (:class:`~sklearn.decomposition.MiniBatchSparsePCA`)
extracts the set of sparse components that best reconstruct the data. This
variant is faster but less accurate than the similar
:class:`~sklearn.decomposition.SparsePCA`.

.. GENERATED FROM PYTHON SOURCE LINES 154-163

.. code-block:: Python

    batch_pca_estimator = decomposition.MiniBatchSparsePCA(
        n_components=n_components, alpha=0.1, max_iter=100, batch_size=3, random_state=rng
    )
    batch_pca_estimator.fit(faces_centered)
    plot_gallery(
        "Sparse components - MiniBatchSparsePCA",
        batch_pca_estimator.components_[:n_components],
    )




.. image-sg:: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_005.png
   :alt: Sparse components - MiniBatchSparsePCA
   :srcset: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_005.png
   :class: sphx-glr-single-img





.. GENERATED FROM PYTHON SOURCE LINES 164-170

Dictionary learning
^^^^^^^^^^^^^^^^^^^

By default, :class:`~sklearn.decomposition.MiniBatchDictionaryLearning`
divides the data into mini-batches and optimizes in an online manner by
cycling over the mini-batches for the specified number of iterations.

.. GENERATED FROM PYTHON SOURCE LINES 172-178

.. code-block:: Python

    batch_dict_estimator = decomposition.MiniBatchDictionaryLearning(
        n_components=n_components, alpha=0.1, max_iter=50, batch_size=3, random_state=rng
    )
    batch_dict_estimator.fit(faces_centered)
    plot_gallery("Dictionary learning", batch_dict_estimator.components_[:n_components])




.. image-sg:: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_006.png
   :alt: Dictionary learning
   :srcset: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_006.png
   :class: sphx-glr-single-img





.. GENERATED FROM PYTHON SOURCE LINES 179-187

Cluster centers - MiniBatchKMeans
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

:class:`sklearn.cluster.MiniBatchKMeans` is computationally efficient and
implements on-line learning with a
:meth:`~sklearn.cluster.MiniBatchKMeans.partial_fit` method. That is
why it could be beneficial to enhance some time-consuming algorithms with
:class:`~sklearn.cluster.MiniBatchKMeans`.

.. GENERATED FROM PYTHON SOURCE LINES 189-203

.. code-block:: Python

    kmeans_estimator = cluster.MiniBatchKMeans(
        n_clusters=n_components,
        tol=1e-3,
        batch_size=20,
        max_iter=50,
        random_state=rng,
    )
    kmeans_estimator.fit(faces_centered)
    plot_gallery(
        "Cluster centers - MiniBatchKMeans",
        kmeans_estimator.cluster_centers_[:n_components],
    )





.. image-sg:: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_007.png
   :alt: Cluster centers - MiniBatchKMeans
   :srcset: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_007.png
   :class: sphx-glr-single-img





.. GENERATED FROM PYTHON SOURCE LINES 204-211

Factor Analysis components - FA
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

:class:`~sklearn.decomposition.FactorAnalysis` is similar to
:class:`~sklearn.decomposition.PCA` but has the advantage of modelling the
variance in every direction of the input space independently (heteroscedastic
noise). Read more in the :ref:`User Guide <FA>`.

.. GENERATED FROM PYTHON SOURCE LINES 213-233

.. code-block:: Python

    fa_estimator = decomposition.FactorAnalysis(n_components=n_components, max_iter=20)
    fa_estimator.fit(faces_centered)
    plot_gallery("Factor Analysis (FA)", fa_estimator.components_[:n_components])

    # --- Pixelwise variance
    plt.figure(figsize=(3.2, 3.6), facecolor="white", tight_layout=True)
    vec = fa_estimator.noise_variance_
    vmax = max(vec.max(), -vec.min())
    plt.imshow(
        vec.reshape(image_shape),
        cmap=plt.cm.gray,
        interpolation="nearest",
        vmin=-vmax,
        vmax=vmax,
    )
    plt.axis("off")
    plt.title("Pixelwise variance from \n Factor Analysis (FA)", size=16, wrap=True)
    plt.colorbar(orientation="horizontal", shrink=0.8, pad=0.03)
    plt.show()




.. rst-class:: sphx-glr-horizontal


    *

      .. image-sg:: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_008.png
         :alt: Factor Analysis (FA)
         :srcset: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_008.png
         :class: sphx-glr-multi-img

    *

      .. image-sg:: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_009.png
         :alt: Pixelwise variance from   Factor Analysis (FA)
         :srcset: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_009.png
         :class: sphx-glr-multi-img





.. GENERATED FROM PYTHON SOURCE LINES 234-247

Decomposition: Dictionary learning
----------------------------------

In the further section, let's consider :ref:`DictionaryLearning` more precisely.
Dictionary learning is a problem that amounts to finding a sparse representation
of the input data as a combination of simple elements. These simple elements form
a dictionary. It is possible to constrain the dictionary and/or coding coefficients
to be positive to match constraints that may be present in the data.

:class:`~sklearn.decomposition.MiniBatchDictionaryLearning` implements a
faster, but less accurate version of the dictionary learning algorithm that
is better suited for large datasets. Read more in the :ref:`User Guide
<MiniBatchDictionaryLearning>`.

.. GENERATED FROM PYTHON SOURCE LINES 249-252

Plot the same samples from our dataset but with another colormap.
Red indicates negative values, blue indicates positive values,
and white represents zeros.

.. GENERATED FROM PYTHON SOURCE LINES 252-255

.. code-block:: Python


    plot_gallery("Faces from dataset", faces_centered[:n_components], cmap=plt.cm.RdBu)




.. image-sg:: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_010.png
   :alt: Faces from dataset
   :srcset: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_010.png
   :class: sphx-glr-single-img





.. GENERATED FROM PYTHON SOURCE LINES 256-266

Similar to the previous examples, we change parameters and train
:class:`~sklearn.decomposition.MiniBatchDictionaryLearning` estimator on all
images. Generally, the dictionary learning and sparse encoding decompose
input data into the dictionary and the coding coefficients matrices. :math:`X
\approx UV`, where :math:`X = [x_1, . . . , x_n]`, :math:`X \in
\mathbb{R}^{m×n}`, dictionary :math:`U \in \mathbb{R}^{m×k}`, coding
coefficients :math:`V \in \mathbb{R}^{k×n}`.

Also below are the results when the dictionary and coding
coefficients are positively constrained.

.. GENERATED FROM PYTHON SOURCE LINES 268-272

Dictionary learning - positive dictionary
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

In the following section we enforce positivity when finding the dictionary.

.. GENERATED FROM PYTHON SOURCE LINES 274-289

.. code-block:: Python

    dict_pos_dict_estimator = decomposition.MiniBatchDictionaryLearning(
        n_components=n_components,
        alpha=0.1,
        max_iter=50,
        batch_size=3,
        random_state=rng,
        positive_dict=True,
    )
    dict_pos_dict_estimator.fit(faces_centered)
    plot_gallery(
        "Dictionary learning - positive dictionary",
        dict_pos_dict_estimator.components_[:n_components],
        cmap=plt.cm.RdBu,
    )




.. image-sg:: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_011.png
   :alt: Dictionary learning - positive dictionary
   :srcset: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_011.png
   :class: sphx-glr-single-img





.. GENERATED FROM PYTHON SOURCE LINES 290-294

Dictionary learning - positive code
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Below we constrain the coding coefficients as a positive matrix.

.. GENERATED FROM PYTHON SOURCE LINES 296-312

.. code-block:: Python

    dict_pos_code_estimator = decomposition.MiniBatchDictionaryLearning(
        n_components=n_components,
        alpha=0.1,
        max_iter=50,
        batch_size=3,
        fit_algorithm="cd",
        random_state=rng,
        positive_code=True,
    )
    dict_pos_code_estimator.fit(faces_centered)
    plot_gallery(
        "Dictionary learning - positive code",
        dict_pos_code_estimator.components_[:n_components],
        cmap=plt.cm.RdBu,
    )




.. image-sg:: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_012.png
   :alt: Dictionary learning - positive code
   :srcset: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_012.png
   :class: sphx-glr-single-img


.. rst-class:: sphx-glr-script-out

 .. code-block:: none

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 4.510e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 5.341e-05, tolerance: 1.486e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 9.135e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.049e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.220e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 1.014e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 9.130e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.136e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 8.803e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.859e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.526e-05, tolerance: 9.354e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 2.379e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.710e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 1.298e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 5.098e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.008e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.140e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.572e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.612e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.848e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.609e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 9.119e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 3.944e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 2.830e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.822e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.025e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.188e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.567e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.709e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.725e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.261e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.240e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.552e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 1.514e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.287e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.686e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.320e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.144e-05, tolerance: 1.173e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.566e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 5.318e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 5.837e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.638e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 2.732e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.144e-05, tolerance: 8.032e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.144e-05, tolerance: 7.027e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.286e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.564e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 2.428e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 5.890e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 7.313e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 6.210e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.615e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 7.904e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 5.956e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 6.345e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.135e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 7.107e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 6.383e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.570e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 4.386e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 7.082e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 4.342e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 4.869e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.354e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 7.919e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 5.891e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.396e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.309e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.538e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 5.722e-06, tolerance: 4.625e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.669e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.518e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.748e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.306e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 4.026e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 7.025e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 1.078e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.292e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.611e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.548e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.016e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 7.624e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 5.722e-06, tolerance: 3.595e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.144e-05, tolerance: 8.678e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 3.633e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.608e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.300e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.862e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 4.080e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.331e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 8.233e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.956e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 2.861e-06, tolerance: 2.093e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.737e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.176e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 2.861e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 1.003e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 4.061e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.564e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.753e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.128e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 4.768e-06, tolerance: 4.819e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.841e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 7.874e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.303e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 9.258e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 6.750e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.817e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 6.054e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.102e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 5.722e-06, tolerance: 6.107e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 9.537e-06, tolerance: 5.981e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.055e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 5.340e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 2.753e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 8.344e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 5.722e-06, tolerance: 4.195e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.017e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 1.918e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.631e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.879e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.526e-05, tolerance: 1.198e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.329e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 5.170e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.284e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.102e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.845e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 3.914e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.755e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.526e-05, tolerance: 6.518e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.206e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 5.985e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.533e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.043e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.948e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-05, tolerance: 9.802e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 5.722e-06, tolerance: 5.125e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.033e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 7.508e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.168e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.976e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 4.134e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 8.913e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 3.857e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.526e-05, tolerance: 9.957e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 6.478e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 8.434e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.138e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.159e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.369e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 3.795e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.335e-05, tolerance: 6.651e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 1.127e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.358e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.183e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.904e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 6.697e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 5.881e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.355e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.396e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.569e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 9.065e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.946e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 1.170e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 7.474e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 3.649e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 9.537e-06, tolerance: 5.379e-07





.. GENERATED FROM PYTHON SOURCE LINES 313-318

Dictionary learning - positive dictionary & code
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Also below are the results if the dictionary values and coding
coefficients are positively constrained.

.. GENERATED FROM PYTHON SOURCE LINES 320-336

.. code-block:: Python

    dict_pos_estimator = decomposition.MiniBatchDictionaryLearning(
        n_components=n_components,
        alpha=0.1,
        max_iter=50,
        batch_size=3,
        fit_algorithm="cd",
        random_state=rng,
        positive_dict=True,
        positive_code=True,
    )
    dict_pos_estimator.fit(faces_centered)
    plot_gallery(
        "Dictionary learning - positive dictionary & code",
        dict_pos_estimator.components_[:n_components],
        cmap=plt.cm.RdBu,
    )



.. image-sg:: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_013.png
   :alt: Dictionary learning - positive dictionary & code
   :srcset: /auto_examples/decomposition/images/sphx_glr_plot_faces_decomposition_013.png
   :class: sphx-glr-single-img


.. rst-class:: sphx-glr-script-out

 .. code-block:: none

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.346e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 8.388e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.777e-04, tolerance: 7.257e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.068e-04, tolerance: 9.927e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.298e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.096e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 8.637e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.277e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.178e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.518e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 3.733e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 8.026e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 3.308e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.956e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.746e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 6.859e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.567e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 8.734e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.300e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.318e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.041e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 1.298e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.678e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 2.994e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.342e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 1.114e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.370e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.340e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 3.956e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.135e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 9.119e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.943e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.370e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 4.566e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.128e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.686e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 6.202e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.355e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.042e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 8.032e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.342e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.058e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 3.795e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.891e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.350e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.548e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.732e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.841e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.710e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 3.762e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.015e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.547e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.918e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 1.198e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.932e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.870e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 8.803e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 4.301e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.489e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 4.026e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 3.557e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 2.355e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 5.981e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.564e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.374e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 5.717e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.228e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 5.069e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.890e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.793e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.907e-06, tolerance: 2.944e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 7.785e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.287e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 1.593e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 1.526e-05, tolerance: 1.918e-06

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.750e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 4.288e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.822e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 8.758e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.844e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 8.923e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 9.957e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 5.176e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 6.309e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 6.709e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 4.164e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 3.815e-06, tolerance: 7.082e-07

    /home/circleci/project/sklearn/linear_model/_coordinate_descent.py:701: ConvergenceWarning:

    Objective did not converge. You might want to increase the number of iterations, check the scale of the features or consider increasing regularisation. Duality gap: 7.629e-06, tolerance: 6.546e-07






.. rst-class:: sphx-glr-timing

   **Total running time of the script:** (0 minutes 7.743 seconds)


.. _sphx_glr_download_auto_examples_decomposition_plot_faces_decomposition.py:

.. only:: html

  .. container:: sphx-glr-footer sphx-glr-footer-example

    .. container:: binder-badge

      .. image:: images/binder_badge_logo.svg
        :target: https://mybinder.org/v2/gh/scikit-learn/scikit-learn/1.8.X?urlpath=lab/tree/notebooks/auto_examples/decomposition/plot_faces_decomposition.ipynb
        :alt: Launch binder
        :width: 150 px

    .. container:: lite-badge

      .. image:: images/jupyterlite_badge_logo.svg
        :target: ../../lite/lab/index.html?path=auto_examples/decomposition/plot_faces_decomposition.ipynb
        :alt: Launch JupyterLite
        :width: 150 px

    .. container:: sphx-glr-download sphx-glr-download-jupyter

      :download:`Download Jupyter notebook: plot_faces_decomposition.ipynb <plot_faces_decomposition.ipynb>`

    .. container:: sphx-glr-download sphx-glr-download-python

      :download:`Download Python source code: plot_faces_decomposition.py <plot_faces_decomposition.py>`

    .. container:: sphx-glr-download sphx-glr-download-zip

      :download:`Download zipped: plot_faces_decomposition.zip <plot_faces_decomposition.zip>`


.. include:: plot_faces_decomposition.recommendations


.. only:: html

 .. rst-class:: sphx-glr-signature

    `Gallery generated by Sphinx-Gallery <https://sphinx-gallery.github.io>`_
