From 7a274bdf81cd0ac5cd50894f2098cb722ca4e2a5 Mon Sep 17 00:00:00 2001 From: saldanhad Date: Wed, 25 Sep 2024 23:43:04 +0530 Subject: [PATCH 1/4] remove plot_digits_last_image.py --- examples/datasets/plot_digits_last_image.py | 30 --------------------- 1 file changed, 30 deletions(-) delete mode 100644 examples/datasets/plot_digits_last_image.py diff --git a/examples/datasets/plot_digits_last_image.py b/examples/datasets/plot_digits_last_image.py deleted file mode 100644 index eada3b12588da..0000000000000 --- a/examples/datasets/plot_digits_last_image.py +++ /dev/null @@ -1,30 +0,0 @@ -""" -========================================================= -The Digit Dataset -========================================================= - -This dataset is made up of 1797 8x8 images. Each image, -like the one shown below, is of a hand-written digit. -In order to utilize an 8x8 figure like this, we'd have to -first transform it into a feature vector with length 64. - -See `here -`_ -for more information about this dataset. - -""" - -# Authors: The scikit-learn developers -# SPDX-License-Identifier: BSD-3-Clause - -import matplotlib.pyplot as plt - -from sklearn import datasets - -# Load the digits dataset -digits = datasets.load_digits() - -# Display the last digit -plt.figure(1, figsize=(3, 3)) -plt.imshow(digits.images[-1], cmap=plt.cm.gray_r, interpolation="nearest") -plt.show() From b288a3f4092c80ec6ec7c97fefd135887ca0f1d3 Mon Sep 17 00:00:00 2001 From: saldanhad Date: Fri, 27 Sep 2024 23:03:26 +0530 Subject: [PATCH 2/4] update redirects in conf.py --- doc/conf.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/doc/conf.py b/doc/conf.py index d07926b8b27f4..2909020d8454d 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -447,6 +447,9 @@ def add_js_css_files(app, pagename, templatename, context, doctree): "auto_examples/model_selection/grid_search_text_feature_extraction.py": ( "auto_examples/model_selection/plot_grid_search_text_feature_extraction.py" ), + "auto_examples/model_selection/plot_digits_last_image.py": ( + "auto_examples/model_selection/plot_iris_dataset.py" + ), "auto_examples/miscellaneous/plot_changed_only_pprint_parameter": ( "auto_examples/miscellaneous/plot_estimator_representation" ), From a41822027cf53d08e18b2f4cbf3334f7b1edb97d Mon Sep 17 00:00:00 2001 From: saldanhad Date: Fri, 27 Sep 2024 23:06:28 +0530 Subject: [PATCH 3/4] correct redirect --- doc/conf.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/conf.py b/doc/conf.py index 2909020d8454d..a1d83d243fa37 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -447,8 +447,8 @@ def add_js_css_files(app, pagename, templatename, context, doctree): "auto_examples/model_selection/grid_search_text_feature_extraction.py": ( "auto_examples/model_selection/plot_grid_search_text_feature_extraction.py" ), - "auto_examples/model_selection/plot_digits_last_image.py": ( - "auto_examples/model_selection/plot_iris_dataset.py" + "auto_examples/datasets/plot_digits_last_image.py": ( + "auto_examples/datasets/plot_iris_dataset.py" ), "auto_examples/miscellaneous/plot_changed_only_pprint_parameter": ( "auto_examples/miscellaneous/plot_estimator_representation" From c7086b2eb22ee89686598f40d078b1fb0cb295f0 Mon Sep 17 00:00:00 2001 From: saldanhad Date: Fri, 27 Sep 2024 23:21:21 +0530 Subject: [PATCH 4/4] update with correct redirect --- doc/conf.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/conf.py b/doc/conf.py index a1d83d243fa37..c340782009cef 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -448,7 +448,7 @@ def add_js_css_files(app, pagename, templatename, context, doctree): "auto_examples/model_selection/plot_grid_search_text_feature_extraction.py" ), "auto_examples/datasets/plot_digits_last_image.py": ( - "auto_examples/datasets/plot_iris_dataset.py" + "auto_examples/exercises/plot_digits_classification_exercises.py" ), "auto_examples/miscellaneous/plot_changed_only_pprint_parameter": ( "auto_examples/miscellaneous/plot_estimator_representation"