From 722d582f9d88ecefb486dae90e0ca6d835d42024 Mon Sep 17 00:00:00 2001 From: Philip Loche Date: Tue, 28 Jan 2025 17:49:55 +0100 Subject: [PATCH] limitt scikit-learn < 1.6.0 --- CHANGELOG | 1 - examples/pcovr/PCovR_Regressors.py | 9 +++++---- .../selection/FeatureSelection-WHODataset.py | 2 +- pyproject.toml | 4 ++-- src/skmatter/sample_selection/_base.py | 2 +- ...age.tsf-492-wpa-0-247.epfl.ch.11311.XpjwIfdx | Bin 0 -> 53248 bytes 6 files changed, 9 insertions(+), 9 deletions(-) create mode 100644 tests/.coverage.tsf-492-wpa-0-247.epfl.ch.11311.XpjwIfdx diff --git a/CHANGELOG b/CHANGELOG index 7d9c0e581..46008bb47 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -13,7 +13,6 @@ The rules for CHANGELOG file: 0.3.0 (XXXX/XX/XX) ------------------ -- Fixed moved function import from scipy and bump scipy dependency to 1.15.0 (#236) - Fix rendering issues for `SparseKDE` and `QuickShift` (#236) - Updating ``FPS`` to allow a numpy array of ints as an initialize parameter (#145) - Supported Python versions are now ranging from 3.9 - 3.12. diff --git a/examples/pcovr/PCovR_Regressors.py b/examples/pcovr/PCovR_Regressors.py index 0b62cac2b..777009d56 100644 --- a/examples/pcovr/PCovR_Regressors.py +++ b/examples/pcovr/PCovR_Regressors.py @@ -55,10 +55,11 @@ # Use a fitted regressor # ---------------------- # -# You can pass a fitted regressor to PCovR to rely on the predetermined -# regression parameters. Currently, scikit-matter supports ``scikit-learn`` -# classes ``LinearModel``, ``Ridge``, and ``RidgeCV``, with plans to support anu -# regressor with similar architecture in the future. +# You can pass a fitted regressor to ``PCovR`` to rely on the predetermined regression +# parameters. Currently, scikit-matter supports ``scikit-learn`` classes +# class:`LinearModel `, :class:`Ridge +# `, and class:`RidgeCV `, +# with plans to support any regressor with similar architecture in the future. regressor = Ridge(alpha=1e-6, fit_intercept=False, tol=1e-12) diff --git a/examples/selection/FeatureSelection-WHODataset.py b/examples/selection/FeatureSelection-WHODataset.py index afbdb519e..e7abbc6ab 100644 --- a/examples/selection/FeatureSelection-WHODataset.py +++ b/examples/selection/FeatureSelection-WHODataset.py @@ -120,7 +120,7 @@ # ^^^^^^^^ -pcur = PCovCUR(n_to_select=n_select, progress_bar=True, mixing=0.0) +pcur = PCovCUR(n_to_select=n_select, progress_bar=True, mixing=1e-3) pcur.fit(X_train, yp_train) # %% diff --git a/pyproject.toml b/pyproject.toml index 4290b257a..e05c76026 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -38,8 +38,8 @@ classifiers = [ "Topic :: Scientific/Engineering", ] dependencies = [ - "scikit-learn>=1.1.0", - "scipy >= 1.15.0", # explicit here since need a newer version as scikit-learn + "scikit-learn < 1.6.0", + "scipy < 1.15.0", ] dynamic = ["version"] diff --git a/src/skmatter/sample_selection/_base.py b/src/skmatter/sample_selection/_base.py index 67d5f0472..f5531d897 100644 --- a/src/skmatter/sample_selection/_base.py +++ b/src/skmatter/sample_selection/_base.py @@ -4,7 +4,7 @@ import numpy as np from scipy.interpolate import LinearNDInterpolator, interp1d -from scipy.interpolate._interpnd import _ndim_coords_from_arrays +from scipy.interpolate.interpnd import _ndim_coords_from_arrays from scipy.spatial import ConvexHull from sklearn.utils.validation import check_array, check_is_fitted, check_X_y diff --git a/tests/.coverage.tsf-492-wpa-0-247.epfl.ch.11311.XpjwIfdx b/tests/.coverage.tsf-492-wpa-0-247.epfl.ch.11311.XpjwIfdx new file mode 100644 index 0000000000000000000000000000000000000000..5d637632bf921d7fd0c0dfe157ca23af76774c48 GIT binary patch literal 53248 zcmeI)O>Y}T7zglOyYv4m3ax6_rXM;(~-bUXPOn@2<1E z&dUKIr$~{I_y&mY#5dsB6E{v=c%GddubsqIZ&l5I6+8PfGduH}XJ(vi+Hamc@e(Bl zVdTq1yl<^rwrxEU!m_L~z1HYuHivfZm;?H5&+ISSEnDr&M{Bijt!n8vtM>ic)7oD3 z_qF#{|E&7uUswNdWZ9()*dPD_2teTfEiidjb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