Skip to content

DOC Release highlights for 1.10 - #35333

Open
virchan wants to merge 23 commits into
scikit-learn:mainfrom
virchan:release-highlights-1.10
Open

virchan wants to merge 23 commits into
scikit-learn:mainfrom
virchan:release-highlights-1.10

Conversation

@virchan

@virchan virchan commented Nov 6, 2026 •

Copy link
Copy Markdown
Member

Here are some changes that Claude and I found worth-mentioning. The current goal is to have this merged on November 29. Direct commits are always welcome.

  1. Categorical support in tree-based models.
  2. Linear models (LogisticRegression API change, GLM, and the new solvers)
  3. IterativeImputer graduates from experimental (remove?)
  4. Metadata routing (auto-requests)
  5. array API Performance update
  6. Callbacks

Edit: updated PR description to reflect #35333 (comment).

@virchan virchan added this to the 1.10 milestone Nov 9, 2026

@virchan virchan left a comment •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note to myself: The documentation renders correctly, but the release highlights are not sorted by version in the left sidebar:

Image

Edit: Fixed by 482dcaf.

@StefanieSenger

StefanieSenger commented Nov 9, 2026 •

Copy link
Copy Markdown
Member

Yes, exactly, I will push the updates on the metadata routing auto requests to this branch.

Tagging @lorentzenchr to go over and verify the Linear models section.

I think there were not a lot of new things on the callbacks side this release. We could leave it out and prepare it for 1.11.

@github-actions github-actions Bot added size/L and removed size/M labels Nov 9, 2026
@github-project-automation github-project-automation Bot moved this to Todo in Labs Nov 9, 2026
@StefanieSenger StefanieSenger moved this from Todo to PR in progress in Labs Nov 9, 2026
@virchan
virchan marked this pull request as ready for review November 9, 2026 12:33
@StefanieSenger

Copy link
Copy Markdown
Member

@jeremiedbb / @FrancoisPgm, do you want to add something for the callbacks?

@lorentzenchr

lorentzenchr commented Nov 10, 2026 •

Copy link
Copy Markdown
Member

Some high level feeback: Less is more, I would remove callbacks, iterative imputer and maybe also array api. If we keep array api, we could also mention our plan to keep all array attributes as numpy array, which simplifies reasoning about it a lot.

What to do with the LR C->alpha change? Usually, we don’t list deprecations in the highlights.

@FrancoisPgm

Copy link
Copy Markdown
Member

@jeremiedbb / @FrancoisPgm, do you want to add something for the callbacks?

The changes in this release regarding callbacks are almost exclusively under the hood plumbing improvements, I don't see anything meaningful to add.

@lorentzenchr

Copy link
Copy Markdown
Member

@virchan 2 questions

  • What is the approx timeline for thi PR
  • How to contribute? Review comments, PRs to your clone, direct commits (if you enabled them)?

@StefanieSenger StefanieSenger left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have a few minor comments, but overall this looks good to me. Already approving to not be a blocker.

Thanks for taking care of this, @virchan! 🫶

@virchan

virchan commented Nov 17, 2026

Copy link
Copy Markdown
Member Author

@virchan 2 questions

  • What is the approx timeline for thi PR
  • How to contribute? Review comments, PRs to your clone, direct commits (if you enabled them)?

Historically, we've merged the release highlights one day before the release. Therefore, I'm aiming to have this PR merged on November 29.

Direct commits are always welcome! I should have mentioned this earlier 😅.


To install the latest version (with pip)::

pip install --upgrade scikit-learn

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder: does this also upgrade joblib and threadpoolctl? Recently, I merged a PR to use a feature of threadpoolctl, it was an old feature but it had been never used and it was buggy, it's fixed in the latest threadpoolctl.

@ogrisel : WDYT? Maybe we should put 3.8 as the min requirement for threadpoolctl.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If users wants a bug fix in threadpoolctl then they should update threadpoolctl. Bumping the minimum dependency of scikit-learn feels too aggressive. You would force people that don't care about the bug in threadpoolctl to update and there doesn't seem to be a good enough reason to.

tl;dr with recent pip versions pip install -U scikit-learn does not update threadpoolctl.

content spout out by an LLM that matches my vague recollection of things

(so it must be right, right 😜)

pip install -U bla upgrades bla, but it doesn’t automatically upgrade every dependency to its latest version. By default, pip uses only-if-needed: it upgrades a dependency only if the newly selected version of bla requires a version that the installed dependency doesn’t satisfy. This has been the default since pip 10.0.

To also upgrade dependencies that already satisfy bla’s requirements, use:

pip install -U --upgrade-strategy eager bla

So your recollection is partly right: older pip versions defaulted to eager dependency upgrades; newer ones default to the more conservative behavior.

@cakedev0 cakedev0 Nov 18, 2026 •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, I don't think calling it a bug in threadpooctl is accurate: the fix is in threadpoolctl yes, but the bug is only visible on scikit-learn (and only since #35180 was merged, as it started using an option of threadpoolctl that was existing for a long time but was never used and was buggy, despite being useful nice once fixed).

For me, silently shipping a tremendous perf regression is way more aggressive than forcing an upgrade on a python-only package 99% of users don't know about 😅

So either we fix scikit-learn before the release (not hard, we can do it, just sad to revert), or we bump min version of threadpoolctl (which I honestly think does more good than harm).

@lesteve lesteve Nov 20, 2026 •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about adding some logic in scikit-learn where we use sequential_blas_under_openmp only for threadpoolctl >= 3.7?

The performance bug likely affects a tiny fraction of the users 🔮, the minimum version bump affects all of them.

In general, as a library putting strong constraints on dependencies is to be avoided, because you never know some other packages package may have separate constraints and the user ends up with mutually exclusive constraints. I don't think this is likely to happen with threadpoolctl but you never know.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The performance bug likely affects a tiny fraction of the users 🔮

I don't think this is likely to happen with threadpoolctl but you never know.

I think both statements are 🔮-ish and I'll try to find ways to assess them a bit more objectively (might not be easy but I have some ideas 😉)


What about adding some logic in scikit-learn where we use sequential_blas_under_openmp only for threadpoolctl >= 3.7?

I think the workaround I have in mind is prettier than that (it avoids branching). But yeah in both case, it's not hard to make a workaround. So why am I arguing so much here you might ask ^^

As someone working on performance and running benchmarks all day long, the support of a range of versions on loky/threadpoolctl/joblib scares the hell out of me: I can't test all combinations (and given how pip install -U works, many are likely to exist somewhere), and each one represent a fairly important performance risk (especially with the current & future work around free-threading).

So I think the tradeoff that pushes us to be conservative on those libraires might be worth being re-considered (once again, some data on what other packages do will help, I'll try to get that).

cc @itamarst: I'm interested to hear your opinion here, you might be the one understanding those performance risks the best. Maybe I'm too scared because of this bad surprise I had with the sequential_blas_under_openmp bug.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(I'm writing an issue)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, missed this.

Perhaps scikit-learn should grow a concept of recommended minimum version, as opposed to required minimum version? And then warn on import if the version is supported but not recommended?

@cakedev0 cakedev0 Nov 30, 2026 •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For this release, PR #35547 will do. And for the next one, let's think again once we start changing scikit-learn to benefit from your work on threadpoolctl & joblib, it might be clearer by then.

(ah I can't resolve the thread)

@cakedev0

Copy link
Copy Markdown
Member

RFC about a random idea: if the HGB PR and the Array API Cholesky Ridge PR gets merged (which is reasonably likely, as both already have one approval), I could write up a fairly impressive "performance update" for the 1.10:

  • HGB
  • Array API Ridge
  • k-means++ (maybe I could also link to my e-means package there)
  • Encoders (I think a PR from @itamarst made a big difference for the slowest cases)

And maybe other stuffs but I don't remember, I'll look at my notes and ask an agent to parse my github activity ^^

WDYT? Separate document or integrated in the release highlights?

@lorentzenchr

lorentzenchr commented Nov 20, 2026 •

Copy link
Copy Markdown
Member

How to others think about removing the "is no longer experimental" section?
In case we keep it, the title should not contain IterativeImputer as HGBT is out of experimental, too.

@virchan

virchan commented Nov 22, 2026

Copy link
Copy Markdown
Member Author

I've taken the liberty of removing the Imputer section.

@lorentzenchr

lorentzenchr commented Nov 26, 2026 •

Copy link
Copy Markdown
Member

RFC […]: if the HGB PR […] gets merged, I could write up a fairly impressive "performance update" for the 1.10:

If it is a real measurable boost for users, then yes. Meanwhile there is another HGBT PR #35526. If that gets merged, the HGBT improvement is a good story of up to 30-40% (higgs with 100 trees from ~62s to ~44s on my laptop).

# %%
# Performance update
# ------------------
# TODO

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here is a proposal for the performance update.

Suggested change
# TODO
# Many estimators are faster in this release, without any change in user code. Some
# improvements speed up a single core, which helps most when many models are fitted
# in parallel, e.g. in a hyper-parameter search with `n_jobs=-1`. Others let a single
# fit benefit more from all the cores of the machine.
#
# :class:`~ensemble.HistGradientBoostingClassifier` and
# :class:`~ensemble.HistGradientBoostingRegressor` got most of the attention. Fit
# times below are in seconds, with scikit-learn 1.9.1 → 1.10:
#
# - Binning the data and building the histograms are faster: on a single thread, a
# fit is 10 to 50% faster depending on the dataset, with the largest gains on
# categorical or binary features.
# - Fitting with `sample_weight` on fewer than 200,000 samples no longer spends most
# of its time in binning: 5.2 → 0.9 for 100,000 x 30 samples on a single thread.
# - The number of threads is now chosen from the size of the data instead of always
# using all the cores. This matters most with the conda-forge packages, whose
# OpenMP runtime lets idle threads sleep on recent desktop and laptop CPUs: on a
# desktop CPU with 24 cores, the covertype dataset (581,012 x 12) goes from 187 to
# 7.9 (6.6 → 4.2 with the wheels from PyPI).
# - It also helps on machines with many cores: on a server with 2 x 86 cores,
# covertype goes from 59 to 19, and the SUSY dataset (4,500,000 x 18) from 22 to
# 11, even if a single fit is still not the best way to use such a machine.
#
# Other notable speed-ups, on the same desktop CPU:
#
# - The k-means++ initialization of :class:`~cluster.KMeans` and
# :class:`~cluster.MiniBatchKMeans` now runs in parallel: a `KMeans` fit on
# 1,000,000 x 50 samples with 100 clusters goes from 6.3 to 1.2 seconds with 24
# threads.
# - Queries on :class:`~neighbors.KDTree` and :class:`~neighbors.BallTree` now scale
# with the number of threads: a :class:`~neighbors.KNeighborsClassifier` prediction
# goes from 7.3 to 0.34 seconds with 24 threads (6.0 to 4.0 with one).
# - :class:`~preprocessing.OneHotEncoder`, :class:`~preprocessing.OrdinalEncoder` and
# :class:`~preprocessing.TargetEncoder` are up to 2 times faster on integer
# categories, and up to 4 times faster on strings with `min_frequency`.
# - With :ref:`array API support <array_api>` enabled, :class:`~linear_model.Ridge`
# now uses its `"cholesky"` solver on GPU arrays. Fitting 200,000 x 5,000 float32
# samples with PyTorch takes 0.9 seconds on the Intel Arc B580 GPU of this machine,
# against 4.3 seconds with NumPy on its CPU (1.1 against 13.5 seconds for an NVIDIA
# L4 GPU and the 8 vCPUs of its cloud instance).
# - :class:`~linear_model.ElasticNetCV` and :class:`~linear_model.LassoCV` are up to
# 4 times faster on sparse data, and :class:`~isotonic.IsotonicRegression` is 3
# times faster to fit.
#
# See the "Efficiency" entries of the :ref:`release notes <release_notes_1_10>` for
# the full list.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants