dask / dask/dask-ml

CI Failures for upstream

Open
#936 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
951
Forks
262
PR merge metrics
No merged PRs in 30d

Description

https://github.com/dask/dask-ml/runs/6626696391?check_suite_focus=true

```pytb
=================================== FAILURES ===================================
_____________________________ test_check_estimator _____________________________

def test_check_estimator():
with warnings.catch_warnings(record=True):
warnings.simplefilter("ignore", RuntimeWarning)
> check_estimator(DKKMeans())

tests/test_kmeans.py:27:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/usr/share/miniconda3/envs/test-environment/lib/python3.9/site-packages/sklearn/utils/estimator_checks.py:625: in check_estimator
check(estimator)
/usr/share/miniconda3/envs/test-environment/lib/python3.9/site-packages/sklearn/utils/estimator_checks.py:1740: in check_transformer_preserve_dtypes
X_trans = transformer.fit_transform(X_cast, y)
/usr/share/miniconda3/envs/test-environment/lib/python3.9/site-packages/sklearn/base.py:885: in fit_transform
return self.fit(X, y, **fit_params).transform(X)
dask_ml/cluster/k_means.py:193: in fit
labels, centroids, inertia, n_iter = k_means(
dask_ml/cluster/k_means.py:265: in k_means
labels, inertia, centers, n_iter = _kmeans_single_lloyd(
dask_ml/cluster/k_means.py:529: in _kmeans_single_lloyd
centers = k_init(
dask_ml/cluster/k_means.py:365: in k_init
return init_scalable(X, n_clusters, random_state, max_iter, oversampling_factor)
dask_ml/utils.py:550: in wraps
results = f(*args, **kwargs)
dask_ml/cluster/k_means.py:478: in init_scalable
km.fit(centers)
/usr/share/miniconda3/envs/test-environment/lib/python3.9/site-packages/sklearn/cluster/_kmeans.py:1411: in fit
self._check_params_vs_input(X)
/usr/share/miniconda3/envs/test-environment/lib/python3.9/site-packages/sklearn/cluster/_kmeans.py:1347: in _check_params_vs_input
super()._check_params_vs_input(X, default_n_init=10)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = KMeans(random_state=893558233)
X = array([[2.51189522, 2.6430893 , 2.54847718],
[0.4992157 , 0.44898092, 0.83202587],
[2.6891034 , 2.588484... , 0.34700649, 0.57520[755](https://github.com/dask/dask-ml/runs/6626696391?check_suite_focus=true#step:5:756)],
[2.46349115, 2.27001103, 2.73159826],
[0.35039398, 0.20177502, 0.26329427]])
default_n_init = 10

def _check_params_vs_input(self, X, default_n_init=None):
# n_clusters
if X.shape[0] < self.n_clusters:
raise ValueError(
f"n_samples={X.shape[0]} should be >= n_clusters={self.n_clusters}."
)

# tol
self._tol = _tolerance(X, self.tol)

# n-init
# TODO(1.4): Remove
self._n_init = self.n_init
if self._n_init == "warn":
> warnings.warn(
"The default value of `n_init` will change from "
f"{default_n_init} to 'auto' in 1.4. Set the value of `n_init`"
" explicitly to suppress the warning",
FutureWarning,
)
E FutureWarning: The default value of `n_init` will change from 10 to 'auto' in 1.4. Set the value of `n_init` explicitly to suppress the warning

/usr/share/miniconda3/envs/test-environment/lib/python3.9/site-packages/sklearn/cluster/_kmeans.py:858: FutureWarning

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.