Version 1.7#
Legend for changelogs
Major Feature something big that you couldn’t do before.
Feature something that you couldn’t do before.
Efficiency an existing feature now may not require as much computation or memory.
Enhancement a miscellaneous minor improvement.
Fix something that previously didn’t work as documented – or according to reasonable expectations – should now work.
API Change you will need to change your code to have the same effect in the future; or a feature will be removed in the future.
Version 1.7.dev0#
February 2025
Support for Array API#
Additional estimators and functions have been updated to include support for all Array API compliant inputs.
See Array API support (experimental) for more details.
Feature
sklearn.utils.check_consistent_length
now supports Array API compatible inputs. By Stefanie Senger #29519Feature
sklearn.metrics.explained_variance_score
andsklearn.metrics.mean_pinball_loss
now support Array API compatible inputs. By Virgil Chan #29978Feature
sklearn.metrics.fbeta_score
,sklearn.metrics.precision_score
andsklearn.metrics.recall_score
now support Array API compatible inputs. By Omar Salman #30395
sklearn.covariance
#
Fix Support for
n_samples == n_features
insklearn.covariance.MinCovDet
has been restored. By Antony Lee. #30483
sklearn.datasets
#
Enhancement New parameter
return_X_y
added todatasets.make_classification
. The default value of the parameter does not change how the function behaves. By Success Moses and Adam Cooper #30196
sklearn.decomposition
#
Feature
DictionaryLearning
,SparseCoder
andMiniBatchDictionaryLearning
now have ainverse_transform
method. By Rémi Flamary #30443
sklearn.ensemble
#
Fix
ensemble.VotingClassifier
andensemble.VotingRegressor
validateestimators
to make sure it is a list of tuples. By Thomas Fan. #30649
sklearn.inspection
#
Enhancement Add
custom_values
parameter ininspection.partial_dependence
. It enables users to pass their own grid of values at which the partial dependence should be calculated. By Freddy A. Boulton and Stephen Pardy #26202API Change
inspection.partial_dependence
does no longer accept integer dtype for numerical feature columns. Explicit conversion to floating point values is now required before calling this tool (and preferably even before fitting the model to inspect). By Olivier Grisel #30409
sklearn.linear_model
#
- Fix Enhancement Added a new parameter
tol
to linear_model.LinearRegression
that determines the precision of the solutioncoef_
when fitting on sparse data. By Success Moses #30521
- Fix Enhancement Added a new parameter
- Fix The update and initialization of the hyperparameters now properly handle
sample weights in
linear_model.BayesianRidge
. By Antoine Baker. #30644
sklearn.metrics
#
Enhancement
class_likelihood_ratios
now has areplace_undefined_by
param. When there is a division by zero, the metric is undefined and the set values are returned forLR+
andLR-
. By Stefanie Senger #29288Fix
class_likelihood_ratios
now raisesUndefinedMetricWarning
instead ofUserWarning
when a division by zero occurs. By Stefanie Senger #29288Fix
metrics.RocCurveDisplay
will no longer set a legend whenlabel
isNone
in both theline_kwargs
and thechance_level_kw
. By Arturo Amor #29727
sklearn.mixture
#
Efficiency Simplified redundant computation when estimating covariances in
GaussianMixture
with acovariance_type="spherical"
orcovariance_type="diag"
. By Leonce Mekinda and Olivier Grisel #30414Efficiency
GaussianMixture
now consistently operates atfloat32
precision when fitted withfloat32
data to improve training speed and memory efficiency. Previously, part of the computation would be implicitly cast tofloat64
. By Olivier Grisel and Omar Salman. #30415
sklearn.multioutput
#
Enhancement The parameter
base_estimator
has been deprecated in favour ofestimator
formultioutput.RegressorChain
andmultioutput.ClassifierChain
. By Success Moses and dikraMasrour #30152
sklearn.neural_network
#
Feature Added support for
sample_weight
inneural_network.MLPClassifier
andneural_network.MLPRegressor
. By Zach Shu and Christian Lorentzen #30155
sklearn.pipeline
#
Enhancement Expose the
verbose_feature_names_out
argument in thepipeline.make_union
function, allowing users to control feature name uniqueness in thepipeline.FeatureUnion
. By Abhijeetsingh Meena #30406
sklearn.utils
#
Enhancement Warning filters from the main process are propagated to joblib workers. By Thomas Fan #30380
Code and documentation contributors
Thanks to everyone who has contributed to the maintenance and improvement of the project since version 1.7, including:
TODO: update at the time of the release.