WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Conversation

@stratakis
Copy link

@stratakis stratakis commented Dec 3, 2025

scikit-learn 1.8.0+ removed the algorithm parameter from AdaBoostClassifier and changed the function signature of _check_targets().

scikit-learn/scikit-learn#32262
scikit-learn/scikit-learn#31701

The changes maintain compatibility with previous version of scikit-learn

What does this implement/fix? Explain your changes.

This fixes compatibility with scikit-learn 1.8.0+

Any other comments?

Tested on Fedora with scikit-learn 1.8.0rc1 as well as 1.7.2 and Python 3.14. All tests passed.

scikit-learn 1.8.0+ removed the algorithm parameter from AdaBoostClassifier

scikit-learn/scikit-learn#32262

The changes maintain compatibility with previous version of scikit-learn
@stratakis stratakis changed the title Fix compatibility with scikit-learn 1.8+ [DRAFT]Fix compatibility with scikit-learn 1.8+ Dec 4, 2025
@stratakis stratakis marked this pull request as draft December 4, 2025 00:05
In scikit-learn 1.8, the _check_targets() function signature changed
to accept and return sample_weight as an extra value.

See: scikit-learn/scikit-learn#31701

This commit adds version checking to handle both APIs.

This maintains backward compatibility with scikit-learn < 1.8.
@stratakis stratakis changed the title [DRAFT]Fix compatibility with scikit-learn 1.8+ [MRG]Fix compatibility with scikit-learn 1.8+ Dec 4, 2025
@stratakis stratakis marked this pull request as ready for review December 4, 2025 01:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant