Commit Graph

90 Commits

Author SHA1 Message Date
Thomas J. Fan 831c49aca3
ENH Adds polars output support to `set_output` API (#27315) 2023-11-19 22:46:56 +01:00
Loïc Estève 19932fcdbf
TST Use _sklearn_version rather than version in pickle tests (#27554) 2023-10-09 22:46:49 +02:00
Adrin Jalali b004f3ad26
ENH warn if {transform, predict} consume metadata but no custom fit_{transform, predict} is defined (#26831)
Co-authored-by: Omar Salman <omar.salman@arbisoft.com>
2023-07-14 17:46:19 +05:00
Adrin Jalali ba6896ec36
FIX clone to handle dict and GridSearchCV changing original params (#26786)
Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
2023-07-13 16:16:29 -05:00
Thomas J. Fan 0e1f170d8a
ENH Adds feature names support to dataframe protocol (#26464)
Co-authored-by: Olivier Grisel <olivier.grisel@ensta.org>
2023-06-21 23:45:55 +00:00
Adrin Jalali 42173fdb34
MNT add isort to ruff's rules (#26649) 2023-06-21 17:50:07 +02:00
Jérémie du Boisberranger 1e8a5b833d
TST Fix test_clone_sparse_matrices on scipy dev (#26556) 2023-06-12 11:26:44 +02:00
Thomas J. Fan 948b49d8de
CLN Clean up logic in validate_data and cast_to_ndarray (#26300) 2023-05-04 13:34:16 +02:00
Thomas J. Fan 3f82f84059
ENH Introduces the __sklearn_clone__ protocol (#24568) 2023-01-19 17:40:16 +01:00
Thomas J. Fan 70c690ebdd
ENH Adds InconsistentVersionWarning when unpickling version doesn't match (#25297)
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@gmail.com>
2023-01-12 10:32:23 +01:00
Guillaume Lemaitre f30d35befd
Revert "ENH added original version of pickled estimator in state dict" (#25279) 2023-01-03 10:33:15 -05:00
Edern affaa62b1d
ENH added original version of pickled estimator in state dict (#22094)
Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@gmail.com>
2022-12-28 18:52:46 +00:00
Benjamin Bossan 9017c70183
FIX fix pickling for empty object with Python 3.11+ (#25188)
Co-authored-by: Adrin Jalali <adrin.jalali@gmail.com>
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@gmail.com>

Python 3.11 introduces `__getstate__` on the `object` level, which breaks our existing `__getstate__` code for objects w/o any attributes. This fixes the issue.
2022-12-16 11:52:29 +00:00
Thomas J. Fan f1963445fc
ENH Improves error message for mixed types for feature names (#25018)
Co-authored-by: jeremie du boisberranger <jeremiedbb@yahoo.fr>
2022-11-25 14:58:58 +01:00
Jérémie du Boisberranger 04d0e4a388
MAINT Clean deprecation for 1.2: feature names exact match (#24660) 2022-10-14 15:59:59 +02:00
Jérémie du Boisberranger 8648cf9218
MAINT clean deprecation for 1.2: leftovers (#24647) 2022-10-13 14:54:53 +02:00
Thomas J. Fan 2a6703d9e8
ENH Introduces set_output API for pandas output (#23734)
* Introduces set_output API for all transformers

* TransformerMixin inherits from _SetOutputMixin

* Adds tests

* Adds whatsnew

* Adds example on using set_output API

* Adds developer docs for set_output
2022-10-13 00:19:12 +02:00
Jérémie du Boisberranger 9f9f1684e9
MAINT Clean deprecation for 1.2: validation (#24493)
* cln deprecations

* cln

* fix tst switch to pytest.raises
2022-09-22 13:46:31 -04:00
Henry Sorsky 626b4608d4
FIX Allow `BaseEstimator.get_params` to handle `type` type params (#24017)
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@gmail.com>
Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
2022-07-29 11:11:32 +02:00
Thomas J. Fan 24cda2d780
MNT Fixes flake8 issues (#23542) 2022-06-07 10:08:10 +02:00
Ben3940 e8454cf205
TST replace pytest.warns(None) in tests/test_base.py (#23056) 2022-04-06 13:22:22 -04:00
Jérémie du Boisberranger bb5ab53f94
API Config: change default display to "diagram" (#22856) 2022-03-21 15:43:07 +01:00
Guillaume Lemaitre 229bd226ab
MNT remove _pairwise attribute (#21594) 2022-02-09 16:58:01 +01:00
Thomas J. Fan 9f85c9d449
TST Better info when checking for no warnings in tests (#22362) 2022-02-03 11:42:48 +01:00
Jérémie du Boisberranger a9bf7f38d7
FIX delete feature_names_in_ when refitting on a ndarray (#21389)
Co-authored-by: Olivier Grisel <olivier.grisel@ensta.org>
2021-10-23 12:30:05 +02:00
Thomas J. Fan 416898b7f4
ENH Adds Column name consistency (#18010)
Co-authored-by: Olivier Grisel <olivier.grisel@ensta.org>
2021-08-17 14:48:21 +02:00
Thomas J. Fan 3ae7c76153
STY Enables black with experimental_string_processing=true (#20412) 2021-06-29 09:47:04 +02:00
Felipe Rodrigues 6835cb3399
TST Remove `assert_warns_message` from `test_base` and `test_dummy` (#20388) 2021-06-27 09:42:15 -04:00
Thomas J. Fan 82df48934e
MNT Applies black formatting to most of the code base (#18948) 2021-06-17 14:21:09 -04:00
Alihan Zihna 7bb3e22b3c
TST change load_boston in test_base to make_* (#20174)
Co-authored-by: maikia <maja_ka@hotmail.com>
Co-authored-by: Alihan Zihna <a.zihna@ckhgbdp.onmicrosoft.com>
2021-05-31 15:36:23 -04:00
Thomas J. Fan d996eaf088
ENH Adds _num_features for array-likes (#19633)
Co-authored-by: Olivier Grisel <olivier.grisel@ensta.org>
Co-authored-by: Christian Lorentzen <lorentzen.ch@gmail.com>
2021-03-16 15:14:25 +01:00
Alihan Zihna 1000d0a61b
TST replace assert_raise with pytest.raises in test_base.py (#19500)
Co-authored-by: Alihan Zihna <a.zihna@ckhgbdp.onmicrosoft.com>
2021-02-22 16:25:34 +01:00
Guillaume Lemaitre 2218ec4622
MNT change 0.25 to 1.0 and 0.26 to 1.1 in deprecation messages (#19005)
Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
2020-12-18 16:09:19 +00:00
Guillaume Lemaitre 255718b4ad
introduce _safe_tags for estimator not inheriting from BaseEstimator (#18797)
Co-authored-by: Nicolas Hug <contact@nicolas-hug.com>
Co-authored-by: Olivier Grisel <olivier.grisel@ensta.org>
2020-12-02 11:18:53 +01:00
Juan Carlos Alfaro Jiménez 1864ed442e
MNT Raise error if parameter cannot be retrieved (#17448)
* MNT Raise error if parameter cannot be retrieved

* MNT Prefer pytest.raises over assert_raises_regex

* FIX Fix tests

* DOC Add what's new entry
2020-10-28 19:05:15 +01:00
Thomas J. Fan 02fa8f1adb
ENH Deprecates _pairwise attribute and adds pairwise to estimator tags (#18143) 2020-10-07 21:53:36 +11:00
Thomas J Fan f23b940dca
FIX Adjusts html_repr based on configuration (#17093)
* ENH Adjusts html_repr based on configuration

* CLN Returns None instead

* CLN Uses property hack

* CLN Address comments
2020-05-05 09:58:10 +02:00
Thomas J Fan ee2508ce45
ENH Adds HTML visualizations for estimators (#14180) 2020-04-30 08:31:58 +10:00
Nicolas Hug 964c830328
MNT Change print_changed_only default to True (#17061) 2020-04-27 18:22:21 -04:00
olicairns 3ae671e07b ENH Improve error message in clone when passed class instances (#16189) 2020-01-27 09:21:09 +01:00
Nicolas Hug 4256542b10 MNT Removed deprecated attributes and parameters (#15803) 2019-12-09 22:17:06 +08:00
Nicolas Hug b92455a6b2 MAINT Deprecate all of utils.testing except all_estimators (#15367) 2019-10-28 17:28:56 +01:00
Thomas J Fan dba753a200 API Auto generates deprecation for sklearn.utils.mocking (#15071) 2019-10-03 00:09:28 +10:00
Andreas Mueller 03ea20db0f Fix mixin inheritance order, allow overwriting tags (#14884) 2019-09-05 10:13:30 +02:00
Joel Nothman 0279108bef
API don't default get_params output to None in the future (#14464) 2019-07-28 23:37:47 +10:00
Adrin Jalali 19c068a2ec MNT towards removing assert_equal, etc (#14222) 2019-07-01 09:13:32 -04:00
Hanmin Qin 8f35843d98
MNT Update deprecation message in RegressorMixin.score to tell users how to avoid the warning (#13477) 2019-03-29 15:22:03 +08:00
Hanmin Qin 85206250ce DOC Typo metric.make_scorer -> metrics.make_scorer 2019-03-15 20:42:59 +08:00
Hanmin Qin 73e2ecf7ce
API Change default multioutput in RegressorMixin.score to keep consistent with metrics.r2_score (#13157) 2019-03-15 17:47:50 +08:00
Andreas Mueller ab2f539a32 API: Estimator tags (#8022) 2019-02-23 22:54:41 +01:00