From 17ce605eae81ec4d36850bd014f2652f94bfb99b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Est=C3=A8ve?= Date: Mon, 24 Apr 2023 09:44:45 +0200 Subject: [PATCH 1/4] MNT Use fixed version of Pyodide (#26247) --- doc/jupyter-lite.json | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 doc/jupyter-lite.json diff --git a/doc/jupyter-lite.json b/doc/jupyter-lite.json new file mode 100644 index 0000000000000..32a5e43af987b --- /dev/null +++ b/doc/jupyter-lite.json @@ -0,0 +1,10 @@ +{ + "jupyter-lite-schema-version": 0, + "jupyter-config-data": { + "litePluginSettings": { + "@jupyterlite/pyodide-kernel-extension:kernel": { + "pyodideUrl": "https://cdn.jsdelivr.net/pyodide/v0.23.1/full/pyodide.js" + } + } + } +} From 7250c69b78bc43c1f55279d2b551ac2931139fc3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Est=C3=A8ve?= Date: Mon, 24 Apr 2023 10:39:45 +0200 Subject: [PATCH 2/4] MNT Reset transform_output default in example to fix doc build build (#26269) --- examples/preprocessing/plot_target_encoder_cross_val.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/examples/preprocessing/plot_target_encoder_cross_val.py b/examples/preprocessing/plot_target_encoder_cross_val.py index 455625cc47460..bf1a1faacd3b8 100644 --- a/examples/preprocessing/plot_target_encoder_cross_val.py +++ b/examples/preprocessing/plot_target_encoder_cross_val.py @@ -158,3 +158,8 @@ # :class:`TargetEncoder` is a part of a :class:`~sklearn.pipeline.Pipeline` and the # pipeline is fitted, the pipeline will correctly call # :meth:`TargetEncoder.fit_transform` and pass the encoding along. + +# %% +# This resets `transform_output` to its default value to avoid impacting other +# examples when generating the scikit-learn documentation +sklearn.set_config(transform_output="default") From 9670b4243dce06255b341cb3aa613c0da0aeb212 Mon Sep 17 00:00:00 2001 From: Phil Date: Mon, 24 Apr 2023 10:51:21 +0200 Subject: [PATCH 3/4] DOC Update example plot_nearest_centroid.py (#26263) --- examples/neighbors/plot_nearest_centroid.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/examples/neighbors/plot_nearest_centroid.py b/examples/neighbors/plot_nearest_centroid.py index 0ea3c0c6b1209..4eb0e0388a30b 100644 --- a/examples/neighbors/plot_nearest_centroid.py +++ b/examples/neighbors/plot_nearest_centroid.py @@ -15,7 +15,6 @@ from sklearn.neighbors import NearestCentroid from sklearn.inspection import DecisionBoundaryDisplay -n_neighbors = 15 # import some data to play with iris = datasets.load_iris() @@ -29,7 +28,7 @@ cmap_bold = ListedColormap(["darkorange", "c", "darkblue"]) for shrinkage in [None, 0.2]: - # we create an instance of Neighbours Classifier and fit the data. + # we create an instance of Nearest Centroid Classifier and fit the data. clf = NearestCentroid(shrink_threshold=shrinkage) clf.fit(X, y) y_pred = clf.predict(X) From 89ff82cd6ae1c144b2a38d9b79e87b17d1ac8dbc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Est=C3=A8ve?= Date: Mon, 24 Apr 2023 14:17:11 +0200 Subject: [PATCH 4/4] MNT reduce JupyterLite build size (#26246) --- doc/jupyter_lite_config.json | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 doc/jupyter_lite_config.json diff --git a/doc/jupyter_lite_config.json b/doc/jupyter_lite_config.json new file mode 100644 index 0000000000000..6b25be20912a8 --- /dev/null +++ b/doc/jupyter_lite_config.json @@ -0,0 +1,5 @@ +{ + "LiteBuildConfig": { + "no_sourcemaps": true + } +}