What’s New¶
v0.4.0 (June 18, 2020)¶
Breaking changes¶
Python <3.6 is no longer officially supported. The package might still work, but we don’t test against these versions anymore.
Enhancements¶
The package can now be installed via conda:
conda install -c phausamann -c conda-forge sklearn-xarray
v0.3.0 (November 5, 2018)¶
Breaking changes¶
wrap
now returns a new classCompatEstimatorWrapper
whencompat=True
.The standard
EstimatorWrapper
directly reflects the parameters of the underlying estimator as instance attributes, regardless of the value ofcompat
(which is deprecated and has no effect).
Enhancements¶
EstimatorWrapper
now directly reflects both the parameters and the fitted attributes (e.g.mean_
) of the underlying estimator. Theestimator
attribute is still an instance of the actual estimator but is treated mostly as just thetype
of the instance (It’s not stored as the type for compatibility withclone
).Added the
CompatEstimatorWrapper
which acts like a standard sklearn estimator (with the wrapped estimator as nested) and does not present the attributes of the underlying estimator.Added
inverse_transform
topreprocessing.Concatenator
.
Bug fixes¶
Fixed failing tests with sklearn 0.20.
v0.2.0 (April 9, 2018)¶
Breaking changes¶
wrap
now returns a decoratedEstimatorWrapper
instead of an estimator-specific wrapper class.Removed the
common.decorators
module, because the decorated estimators could not be pickled and therefore didn’t pass the usual sklearn estimator checks.Removed the
dataset
anddataarray
modules. Wrappers have to be directly imported fromsklearn_xarray
.Removed the
data
module (now calleddatasets
).
Enhancements¶
Added wrappers for
fit_transform
,partial_fit
,predict_proba
,predict_log_proba
anddecision_function
.
v0.1.4 (March 15, 2018)¶
Enhancements¶
preprocessing.Transposer
now also accepts a subset ofX.dims
for theorder
parameter.preprocessing.Splitter
andpreprocessing.Segmenter
now accept anaxis
argument that specifies where to insert the new dimension.Huge performance improvements for
preprocessing.Segmenter
by usingnumpy.lib.stride_tricks.as_strided
instead of a loop. The general-purpose backend for segmenting can be found inutils.segment_array
.
Deprecations¶
The
data
module containing different example datasets is being renamed todatasets
according to the scikit-learn standards. Since thedataset
module will be removed, there will no longer be confusion due to similar naming.
v0.1.3 (January 9, 2018)¶
Enhancements¶
The wrapper now passes the DataArray’s data
attribute to the wrapped
estimator, making it possible to wrap estimators from dask-ml and use
dask-backed DataArrays and Datasets as inputs.
v0.1.2 (December 10, 2017)¶
Enhancements¶
The wrapping mechanism has been changed to work with both DataArrays and
Datasets. From now on, you can use from sklearn_xarray import wrap
which
will automatically determine the type of xarray object when calling fit
.
Note that a wrapper fitted for DataArrays cannot be used for Datasets and
vice-versa.
The wrappers now also support passing an estimator type rather than an instance and passing the parameters of the wrapped estimator directly to the wrapper.