From c3f34f22f189d97acd183ecc6e0a461601e722b6 Mon Sep 17 00:00:00 2001 From: Jim Crist-Harif Date: Thu, 16 Jul 2026 20:32:24 -0500 Subject: [PATCH 1/9] Deprecate legacy output types This deprecates the 'numba', 'array', 'df_obj', 'dataframe', and 'series' output types. - 'numba': `numba.cuda` itself is being deprecated, and `DeviceNDArray` is going away. The advice from `numba.cuda` devs is to stop directly using it. - 'array': this is an alias for 'cupy', the user should just use 'cupy'. - 'df_obj': this is an alias for 'cudf', the user should just use 'cudf'. - 'dataframe' and 'series': these are 'cudf', but with coercion to a specific ndim value (erroring if not possible). This doesn't fit well within the standard sklearn api. If a user wants an output to be specifically a Series or DataFrame, they should handle the coercion themselves later on. --- python/cuml/cuml/internals/base.py | 25 +++++++++- python/cuml/cuml/internals/outputs.py | 14 ++++++ .../tests/test_dataset_generator_types.py | 2 + python/cuml/tests/test_make_arima.py | 1 + python/cuml/tests/test_reflection.py | 48 +++++++++++++++++-- python/cuml/tests/test_svm.py | 4 +- 6 files changed, 88 insertions(+), 6 deletions(-) diff --git a/python/cuml/cuml/internals/base.py b/python/cuml/cuml/internals/base.py index 2630e3f7e6..0280d3a673 100644 --- a/python/cuml/cuml/internals/base.py +++ b/python/cuml/cuml/internals/base.py @@ -6,6 +6,7 @@ import os import re import threading +import warnings import pylibraft.common.handle @@ -15,7 +16,10 @@ import cuml.internals.logger as logger import cuml.internals.nvtx as nvtx from cuml.internals.mixins import TagsMixin, _ensure_transformer_tags -from cuml.internals.outputs import infer_output_type +from cuml.internals.outputs import ( + infer_output_type, + warn_if_output_type_deprecated, +) _THREAD_STATE = threading.local() @@ -51,6 +55,14 @@ def get_handle(*, n_streams=0, device_ids=None): return pylibraft.common.handle.Handle(n_streams=n_streams) +class _DeprecatedOutputTypeDescriptor: + """A descriptor to warn when a deprecated `output_type` is configured.""" + + def __set__(self, obj, value): + warn_if_output_type_deprecated(value) + obj.__dict__["output_type"] = value + + class Base(TagsMixin): """Base class for cuml estimators. @@ -114,6 +126,8 @@ def predict(self, X): return cp.ones(len(X), dtype="int32") """ + output_type = _DeprecatedOutputTypeDescriptor() + def __init__( self, *, @@ -240,6 +254,15 @@ class output type and global output type. else: # Determine the output from the input output_type = infer_output_type(inp) + if output_type == "numba": + warnings.warn( + "Outputting `numba` arrays was deprecated " + "in version 26.08 and will be removed " + "in version 26.10. In the future this call will return a " + "`cupy` array instead. You may silence this warning by " + "explicitly setting `output_type='cupy'` now.", + FutureWarning, + ) return output_type diff --git a/python/cuml/cuml/internals/outputs.py b/python/cuml/cuml/internals/outputs.py index b583803ab6..825135b1c8 100644 --- a/python/cuml/cuml/internals/outputs.py +++ b/python/cuml/cuml/internals/outputs.py @@ -5,6 +5,7 @@ import contextlib import functools import inspect +import warnings import cudf import cupy as cp @@ -55,6 +56,18 @@ def check_output_type(output_type: str) -> str: return output_type +def warn_if_output_type_deprecated(output_type: str): + """Warn if the specified `output_type` is deprecated""" + if output_type in ("numba", "array", "df_obj", "dataframe", "series"): + alt = "cupy" if output_type in ("numba", "array") else "cudf" + warnings.warn( + f"`output_type={output_type!r}` was deprecated in version 26.08 " + "and will be removed in version 26.10. Please use " + f"`output_type={alt!r}` instead.", + FutureWarning, + ) + + def set_global_output_type(output_type): """Set the global output type. @@ -132,6 +145,7 @@ def set_global_output_type(output_type): """ if output_type is not None: output_type = check_output_type(output_type) + warn_if_output_type_deprecated(output_type) GlobalSettings().output_type = output_type diff --git a/python/cuml/tests/test_dataset_generator_types.py b/python/cuml/tests/test_dataset_generator_types.py index 985671b538..b41de2b4c3 100644 --- a/python/cuml/tests/test_dataset_generator_types.py +++ b/python/cuml/tests/test_dataset_generator_types.py @@ -36,6 +36,7 @@ @pytest.mark.parametrize("generator", GENERATORS) @pytest.mark.parametrize("output_str,output_types", TEST_OUTPUT_TYPES) +@pytest.mark.filterwarnings("ignore:`output_type='numba'`:FutureWarning") def test_xy_output_type(generator, output_str, output_types): # Set the output type and ensure data of that type is generated with cuml.using_output_type(output_str): @@ -50,6 +51,7 @@ def test_xy_output_type(generator, output_str, output_types): "ignore:`cuml.datasets.make_arima`, along with the entire `cuml.tsa` module, " "was deprecated:FutureWarning" ) +@pytest.mark.filterwarnings("ignore:`output_type='numba'`:FutureWarning") def test_time_series_label_output_type(output_str, output_types): # Set the output type and ensure data of that type is generated with cuml.using_output_type(output_str): diff --git a/python/cuml/tests/test_make_arima.py b/python/cuml/tests/test_make_arima.py index 337e825991..69d5bd6860 100644 --- a/python/cuml/tests/test_make_arima.py +++ b/python/cuml/tests/test_make_arima.py @@ -40,6 +40,7 @@ @pytest.mark.parametrize("n_obs", n_obs) @pytest.mark.parametrize("random_state", random_state) @pytest.mark.parametrize("order", order) +@pytest.mark.filterwarnings("ignore:`output_type='numba'`:FutureWarning") def test_make_arima( dtype, output_type, batch_size, n_obs, random_state, order ): diff --git a/python/cuml/tests/test_reflection.py b/python/cuml/tests/test_reflection.py index a16851b6f6..2084b21c4a 100644 --- a/python/cuml/tests/test_reflection.py +++ b/python/cuml/tests/test_reflection.py @@ -227,16 +227,50 @@ def test_infer_output_type_non_arrays(obj): def test_default_output_type(input_type): X = rand_array(input_type) model = cuml.DBSCAN(eps=1.0, min_samples=1) - labels = model.fit_predict(X) + if input_type == "numba": + with pytest.warns(FutureWarning, match="Outputting `numba` arrays"): + labels = model.fit_predict(X) + else: + labels = model.fit_predict(X) assert_output_type(labels, input_type) assert_output_type(model.components_, input_type) +@pytest.mark.parametrize( + "output_type", ("numba", "array", "df_obj", "series", "dataframe") +) +def test_deprecated_output_type(output_type): + X = rand_array("cupy") + + with pytest.warns( + FutureWarning, + match=f"`{output_type=!r}` was deprecated", + ): + model = cuml.DBSCAN(eps=1.0, min_samples=1, output_type=output_type) + + labels = model.fit_predict(X) + if alias := {"numba": "numba", "array": "cupy", "df_obj": "cudf"}.get( + output_type + ): + assert_output_type(labels, alias) + assert_output_type(model.labels_, alias) + else: + cls = cudf.Series if output_type == "series" else cudf.DataFrame + assert isinstance(labels, cls) + assert isinstance(model.labels_, cls) + + @pytest.mark.parametrize("input_type", OUTPUT_TYPES) @pytest.mark.parametrize("output_type", OUTPUT_TYPES) def test_estimator_output_type(input_type, output_type): X = rand_array(input_type) - model = cuml.DBSCAN(eps=1.0, min_samples=1, output_type=output_type) + if output_type == "numba": + with pytest.warns(FutureWarning, match="`output_type='numba'`"): + model = cuml.DBSCAN( + eps=1.0, min_samples=1, output_type=output_type + ) + else: + model = cuml.DBSCAN(eps=1.0, min_samples=1, output_type=output_type) labels = model.fit_predict(X) assert_output_type(labels, output_type) assert_output_type(model.components_, output_type) @@ -245,7 +279,11 @@ def test_estimator_output_type(input_type, output_type): @pytest.mark.parametrize("input_type", OUTPUT_TYPES) @pytest.mark.parametrize("output_type", OUTPUT_TYPES) def test_global_output_type(input_type, output_type): - cuml.set_global_output_type(output_type) + if output_type == "numba": + with pytest.warns(FutureWarning, match="`output_type='numba'`"): + cuml.set_global_output_type(output_type) + else: + cuml.set_global_output_type(output_type) X = rand_array(input_type) model = cuml.DBSCAN(eps=1.0, min_samples=1) @@ -412,6 +450,7 @@ def check_nested_types(res, sol): @pytest.mark.parametrize("output_type", [None, *OUTPUT_TYPES]) +@pytest.mark.filterwarnings("ignore:`output_type='numba'`:FutureWarning") def test_mlfunc_dense_outputs(output_type): cuml.set_global_output_type(output_type) X = rand_array("cupy") @@ -430,6 +469,7 @@ def test_mlfunc_dense_outputs(output_type): @pytest.mark.parametrize("output_type", [None, *OUTPUT_TYPES]) +@pytest.mark.filterwarnings("ignore:`output_type='numba'`:FutureWarning") def test_mlfunc_sparse_outputs(output_type): @mlfunc def make_sparse(): @@ -527,6 +567,7 @@ def myfunc(df): @pytest.mark.parametrize("dtype", ["int32", "object", "U"]) @pytest.mark.parametrize("output_type", OUTPUT_TYPES) +@pytest.mark.filterwarnings("ignore:`output_type='numba'`:FutureWarning") def test_class_labels(dtype, output_type): if dtype in ("object", "U"): classes = np.array(["a", "b", "c"], dtype=dtype) @@ -630,6 +671,7 @@ def test_estimator_method_with_no_array_input(): assert_output_type(model.example_no_args(), "pandas") +@pytest.mark.filterwarnings("ignore:`output_type='numba'`:FutureWarning") @pytest.mark.parametrize("output_type", [None, *OUTPUT_TYPES]) def test_reflected_attr(output_type): cuml.set_global_output_type(output_type) diff --git a/python/cuml/tests/test_svm.py b/python/cuml/tests/test_svm.py index 0bd5d6ee3e..9d00b66d01 100644 --- a/python/cuml/tests/test_svm.py +++ b/python/cuml/tests/test_svm.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import platform @@ -305,7 +305,7 @@ def test_svc_weights(class_weight, sample_weight): "degree": 40, "C": 1, "gamma": "scale", - "x_arraytype": "numba", + "x_arraytype": "cupy", } ), ], From 746ebf9b65a6d17a8859f98a1e72791fcfd3555e Mon Sep 17 00:00:00 2001 From: Jim Crist-Harif Date: Mon, 20 Jul 2026 16:12:32 -0500 Subject: [PATCH 2/9] Respond to feedback --- python/cuml/cuml/internals/outputs.py | 11 ++++++++++- python/cuml/tests/test_reflection.py | 7 ++++++- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/python/cuml/cuml/internals/outputs.py b/python/cuml/cuml/internals/outputs.py index 825135b1c8..0b7eab194e 100644 --- a/python/cuml/cuml/internals/outputs.py +++ b/python/cuml/cuml/internals/outputs.py @@ -60,10 +60,19 @@ def warn_if_output_type_deprecated(output_type: str): """Warn if the specified `output_type` is deprecated""" if output_type in ("numba", "array", "df_obj", "dataframe", "series"): alt = "cupy" if output_type in ("numba", "array") else "cudf" + if output_type in ("dataframe", "series"): + suffix = ( + " Note that `output_type='cudf'` will return `cudf.Series` " + "objects for 1-dimensional outputs and `cudf.DataFrame` " + "objects for 2-dimensional outputs. You may need to " + "update consumers as necessary." + ) + else: + suffix = "" warnings.warn( f"`output_type={output_type!r}` was deprecated in version 26.08 " "and will be removed in version 26.10. Please use " - f"`output_type={alt!r}` instead.", + f"`output_type={alt!r}` instead.{suffix}", FutureWarning, ) diff --git a/python/cuml/tests/test_reflection.py b/python/cuml/tests/test_reflection.py index 2084b21c4a..91f7e91815 100644 --- a/python/cuml/tests/test_reflection.py +++ b/python/cuml/tests/test_reflection.py @@ -245,9 +245,14 @@ def test_deprecated_output_type(output_type): with pytest.warns( FutureWarning, match=f"`{output_type=!r}` was deprecated", - ): + ) as rec: model = cuml.DBSCAN(eps=1.0, min_samples=1, output_type=output_type) + if output_type in ("series", "dataframe"): + assert "Note that `output_type='cudf'`" in str(rec[0].message) + else: + assert "Note that `output_type='cudf'`" not in str(rec[0].message) + labels = model.fit_predict(X) if alias := {"numba": "numba", "array": "cupy", "df_obj": "cudf"}.get( output_type From 9c575dc70dd76e90651bb1e41167d4cab25b32ea Mon Sep 17 00:00:00 2001 From: Jim Crist-Harif Date: Mon, 20 Jul 2026 16:28:46 -0500 Subject: [PATCH 3/9] Update `output_type` docstrings --- python/cuml/cuml/cluster/agglomerative.pyx | 3 +-- python/cuml/cuml/cluster/dbscan.pyx | 3 +-- python/cuml/cuml/cluster/hdbscan/hdbscan.pyx | 3 +-- python/cuml/cuml/cluster/kmeans.pyx | 3 +-- .../cuml/cuml/cluster/spectral_clustering.pyx | 3 +-- .../cuml/covariance/empirical_covariance.py | 3 +-- python/cuml/cuml/covariance/ledoit_wolf.py | 3 +-- python/cuml/cuml/dask/cluster/dbscan.py | 5 ++--- .../cuml/cuml/dask/linear_model/elastic_net.py | 5 ++--- .../dask/linear_model/logistic_regression.py | 5 ++--- .../cuml/cuml/decomposition/incremental_pca.py | 3 +-- python/cuml/cuml/decomposition/pca.pyx | 3 +-- python/cuml/cuml/decomposition/tsvd.pyx | 3 +-- .../cuml/ensemble/randomforestclassifier.py | 5 ++--- .../cuml/cuml/ensemble/randomforestregressor.py | 5 ++--- python/cuml/cuml/feature_extraction/_tfidf.py | 3 +-- python/cuml/cuml/internals/base.py | 3 +-- python/cuml/cuml/kernel_ridge/kernel_ridge.py | 3 +-- python/cuml/cuml/linear_model/elastic_net.py | 5 ++--- python/cuml/cuml/linear_model/lars.pyx | 3 +-- python/cuml/cuml/linear_model/lasso.py | 5 ++--- .../cuml/linear_model/linear_regression.pyx | 3 +-- .../cuml/linear_model/logistic_regression.py | 5 ++--- .../cuml/cuml/linear_model/mbsgd_classifier.py | 5 ++--- .../cuml/cuml/linear_model/mbsgd_regressor.py | 5 ++--- python/cuml/cuml/linear_model/ridge.pyx | 3 +-- .../cuml/cuml/manifold/spectral_embedding.pyx | 3 +-- python/cuml/cuml/manifold/t_sne.pyx | 3 +-- python/cuml/cuml/manifold/umap/umap.pyx | 3 +-- python/cuml/cuml/multiclass/multiclass.py | 8 +++----- python/cuml/cuml/naive_bayes/naive_bayes.py | 17 ++++++----------- python/cuml/cuml/neighbors/kernel_density.pyx | 5 ++--- .../cuml/neighbors/kneighbors_classifier.pyx | 5 ++--- .../cuml/neighbors/kneighbors_regressor.pyx | 5 ++--- .../cuml/cuml/neighbors/nearest_neighbors.pyx | 5 ++--- python/cuml/cuml/preprocessing/_label.py | 3 +-- .../cuml/cuml/preprocessing/_target_encoder.py | 3 +-- python/cuml/cuml/preprocessing/encoders.py | 9 +++------ python/cuml/cuml/preprocessing/label.py | 5 ++--- .../cuml/random_projection/random_projection.py | 6 ++---- python/cuml/cuml/solvers/cd.pyx | 5 ++--- python/cuml/cuml/solvers/qn.pyx | 5 ++--- python/cuml/cuml/solvers/sgd.pyx | 5 ++--- python/cuml/cuml/svm/linear_svc.py | 5 ++--- python/cuml/cuml/svm/linear_svr.py | 5 ++--- python/cuml/cuml/svm/svc.py | 5 ++--- python/cuml/cuml/svm/svr.py | 5 ++--- python/cuml/cuml/tsa/arima.pyx | 3 +-- python/cuml/cuml/tsa/auto_arima.pyx | 3 +-- python/cuml/cuml/tsa/holtwinters.pyx | 3 +-- 50 files changed, 82 insertions(+), 140 deletions(-) diff --git a/python/cuml/cuml/cluster/agglomerative.pyx b/python/cuml/cuml/cluster/agglomerative.pyx index 5ffe98a116..ace463118e 100644 --- a/python/cuml/cuml/cluster/agglomerative.pyx +++ b/python/cuml/cuml/cluster/agglomerative.pyx @@ -81,8 +81,7 @@ class AgglomerativeClustering(ClusterMixin, CMajorInputTagMixin, Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/cluster/dbscan.pyx b/python/cuml/cuml/cluster/dbscan.pyx index 502ad4b925..e875a05d70 100644 --- a/python/cuml/cuml/cluster/dbscan.pyx +++ b/python/cuml/cuml/cluster/dbscan.pyx @@ -169,8 +169,7 @@ class DBSCAN(InteropMixin, Note: this option does not set the maximum total memory used in the DBSCAN computation and so this value will not be able to be set to the total memory available on the device. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/cluster/hdbscan/hdbscan.pyx b/python/cuml/cuml/cluster/hdbscan/hdbscan.pyx index c443518e24..073b335c39 100644 --- a/python/cuml/cuml/cluster/hdbscan/hdbscan.pyx +++ b/python/cuml/cuml/cluster/hdbscan/hdbscan.pyx @@ -559,8 +559,7 @@ class HDBSCAN(InteropMixin, ClusterMixin, CMajorInputTagMixin, Base): utilizing plotting tools. This requires the `hdbscan` CPU Python package to be installed. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/cluster/kmeans.pyx b/python/cuml/cuml/cluster/kmeans.pyx index 9dbd8f121f..04ffbd3bcb 100644 --- a/python/cuml/cuml/cluster/kmeans.pyx +++ b/python/cuml/cuml/cluster/kmeans.pyx @@ -368,8 +368,7 @@ class KMeans(InteropMixin, batched pairwise distance computation is :py:`max_samples_per_batch * n_clusters`. It might become necessary to lower this number when `n_clusters` becomes prohibitively large. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/cluster/spectral_clustering.pyx b/python/cuml/cuml/cluster/spectral_clustering.pyx index e3841cd42b..aa6f17215e 100644 --- a/python/cuml/cuml/cluster/spectral_clustering.pyx +++ b/python/cuml/cuml/cluster/spectral_clustering.pyx @@ -103,8 +103,7 @@ class SpectralClustering(InteropMixin, verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. diff --git a/python/cuml/cuml/covariance/empirical_covariance.py b/python/cuml/cuml/covariance/empirical_covariance.py index 8e569c3b2b..565e580bba 100644 --- a/python/cuml/cuml/covariance/empirical_covariance.py +++ b/python/cuml/cuml/covariance/empirical_covariance.py @@ -50,8 +50,7 @@ class EmpiricalCovariance(InteropMixin, Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/covariance/ledoit_wolf.py b/python/cuml/cuml/covariance/ledoit_wolf.py index c43a6c063d..b12cc9df4f 100644 --- a/python/cuml/cuml/covariance/ledoit_wolf.py +++ b/python/cuml/cuml/covariance/ledoit_wolf.py @@ -114,8 +114,7 @@ class LedoitWolf(InteropMixin, Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/dask/cluster/dbscan.py b/python/cuml/cuml/dask/cluster/dbscan.py index 724a414d78..ad7aab30cd 100644 --- a/python/cuml/cuml/dask/cluster/dbscan.py +++ b/python/cuml/cuml/dask/cluster/dbscan.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2020-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2020-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # @@ -45,8 +45,7 @@ class DBSCAN(BaseEstimator, DelayedPredictionMixin, DelayedTransformMixin): Note: this option does not set the maximum total memory used in the DBSCAN computation and so this value will not be able to be set to the total memory available on the device. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/dask/linear_model/elastic_net.py b/python/cuml/cuml/dask/linear_model/elastic_net.py index ec02866480..7a9942b25b 100644 --- a/python/cuml/cuml/dask/linear_model/elastic_net.py +++ b/python/cuml/cuml/dask/linear_model/elastic_net.py @@ -1,5 +1,5 @@ # -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # @@ -46,8 +46,7 @@ class ElasticNet(BaseEstimator): rather than looping over features sequentially by default. This (setting to 'random') often leads to significantly faster convergence especially when tol is higher than 1e-4. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/dask/linear_model/logistic_regression.py b/python/cuml/cuml/dask/linear_model/logistic_regression.py index 2d4dcad76e..61e00f1d84 100644 --- a/python/cuml/cuml/dask/linear_model/logistic_regression.py +++ b/python/cuml/cuml/dask/linear_model/logistic_regression.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2023-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2023-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # @@ -93,8 +93,7 @@ class LogisticRegression(LinearRegression): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/decomposition/incremental_pca.py b/python/cuml/cuml/decomposition/incremental_pca.py index a9b1fb230d..86cf89ca41 100644 --- a/python/cuml/cuml/decomposition/incremental_pca.py +++ b/python/cuml/cuml/decomposition/incremental_pca.py @@ -64,8 +64,7 @@ class IncrementalPCA(PCA): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/decomposition/pca.pyx b/python/cuml/cuml/decomposition/pca.pyx index 93eea9e3d6..d9f41aab95 100644 --- a/python/cuml/cuml/decomposition/pca.pyx +++ b/python/cuml/cuml/decomposition/pca.pyx @@ -186,8 +186,7 @@ class PCA(InteropMixin, Whitening allows each component to have unit variance and removes multi-collinearity. It might be beneficial for downstream tasks like LinearRegression where correlated features cause problems. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/decomposition/tsvd.pyx b/python/cuml/cuml/decomposition/tsvd.pyx index 22fcf1de28..143cea62aa 100644 --- a/python/cuml/cuml/decomposition/tsvd.pyx +++ b/python/cuml/cuml/decomposition/tsvd.pyx @@ -157,8 +157,7 @@ class TruncatedSVD(InteropMixin, verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/ensemble/randomforestclassifier.py b/python/cuml/cuml/ensemble/randomforestclassifier.py index 1dcfd7e701..1058ab04dc 100644 --- a/python/cuml/cuml/ensemble/randomforestclassifier.py +++ b/python/cuml/cuml/ensemble/randomforestclassifier.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 import cupy as cp import numpy as np @@ -125,8 +125,7 @@ class RandomForestClassifier(ClassifierMixin, BaseRandomForestModel): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/ensemble/randomforestregressor.py b/python/cuml/cuml/ensemble/randomforestregressor.py index e8319630eb..ca7d17c61f 100644 --- a/python/cuml/cuml/ensemble/randomforestregressor.py +++ b/python/cuml/cuml/ensemble/randomforestregressor.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 import cuml.internals.nvtx as nvtx from cuml.common.doc_utils import generate_docstring, insert_into_docstring @@ -117,8 +117,7 @@ class RandomForestRegressor(RegressorMixin, BaseRandomForestModel): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/feature_extraction/_tfidf.py b/python/cuml/cuml/feature_extraction/_tfidf.py index 4437f73ebe..8775f11376 100644 --- a/python/cuml/cuml/feature_extraction/_tfidf.py +++ b/python/cuml/cuml/feature_extraction/_tfidf.py @@ -91,8 +91,7 @@ class TfidfTransformer(Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/internals/base.py b/python/cuml/cuml/internals/base.py index 0280d3a673..a3cb9f5b77 100644 --- a/python/cuml/cuml/internals/base.py +++ b/python/cuml/cuml/internals/base.py @@ -85,8 +85,7 @@ class Base(TagsMixin): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/kernel_ridge/kernel_ridge.py b/python/cuml/cuml/kernel_ridge/kernel_ridge.py index 223b5fd107..ff365fc8db 100644 --- a/python/cuml/cuml/kernel_ridge/kernel_ridge.py +++ b/python/cuml/cuml/kernel_ridge/kernel_ridge.py @@ -127,8 +127,7 @@ class KernelRidge(InteropMixin, RegressorMixin, Base): kernel_params : mapping of str to any, default=None Additional parameters (keyword arguments) for kernel function passed as callable object. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/linear_model/elastic_net.py b/python/cuml/cuml/linear_model/elastic_net.py index 0775ced7ff..f47348e6c2 100644 --- a/python/cuml/cuml/linear_model/elastic_net.py +++ b/python/cuml/cuml/linear_model/elastic_net.py @@ -1,5 +1,5 @@ # -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import cupy as cp @@ -69,8 +69,7 @@ class ElasticNet( features sequentially by default. This (setting to 'random') often leads to significantly faster convergence especially when tol is higher than 1e-4. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/linear_model/lars.pyx b/python/cuml/cuml/linear_model/lars.pyx index 9bd5ccfc94..cfab2e5d78 100644 --- a/python/cuml/cuml/linear_model/lars.pyx +++ b/python/cuml/cuml/linear_model/lars.pyx @@ -87,8 +87,7 @@ class Lars(RegressorMixin, Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/linear_model/lasso.py b/python/cuml/cuml/linear_model/lasso.py index bbadb2f684..6b76ae2831 100644 --- a/python/cuml/cuml/linear_model/lasso.py +++ b/python/cuml/cuml/linear_model/lasso.py @@ -1,5 +1,5 @@ # -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # @@ -44,8 +44,7 @@ class Lasso(ElasticNet): rather than looping over features sequentially by default. This (setting to 'random') often leads to significantly faster convergence especially when tol is higher than 1e-4. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/linear_model/linear_regression.pyx b/python/cuml/cuml/linear_model/linear_regression.pyx index 9a960b29bb..1f332f55a8 100644 --- a/python/cuml/cuml/linear_model/linear_regression.pyx +++ b/python/cuml/cuml/linear_model/linear_regression.pyx @@ -116,8 +116,7 @@ class LinearRegression(InteropMixin, verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/linear_model/logistic_regression.py b/python/cuml/cuml/linear_model/logistic_regression.py index 4a0fe80b67..ae1e5b91d5 100644 --- a/python/cuml/cuml/linear_model/logistic_regression.py +++ b/python/cuml/cuml/linear_model/logistic_regression.py @@ -1,5 +1,5 @@ # -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import cupy as cp @@ -80,8 +80,7 @@ class LogisticRegression( verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/linear_model/mbsgd_classifier.py b/python/cuml/cuml/linear_model/mbsgd_classifier.py index 20ee972c18..392d796f1e 100644 --- a/python/cuml/cuml/linear_model/mbsgd_classifier.py +++ b/python/cuml/cuml/linear_model/mbsgd_classifier.py @@ -1,5 +1,5 @@ # -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import cupy as cp @@ -82,8 +82,7 @@ class MBSGDClassifier( verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/linear_model/mbsgd_regressor.py b/python/cuml/cuml/linear_model/mbsgd_regressor.py index 6b91347274..9b0c1dbf0c 100644 --- a/python/cuml/cuml/linear_model/mbsgd_regressor.py +++ b/python/cuml/cuml/linear_model/mbsgd_regressor.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 from cuml.common.doc_utils import generate_docstring from cuml.internals.base import Base @@ -73,8 +73,7 @@ class MBSGDRegressor( verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/linear_model/ridge.pyx b/python/cuml/cuml/linear_model/ridge.pyx index 17c2ca8a7a..1dc4004d48 100644 --- a/python/cuml/cuml/linear_model/ridge.pyx +++ b/python/cuml/cuml/linear_model/ridge.pyx @@ -109,8 +109,7 @@ class Ridge(InteropMixin, copy_X: bool, default=True If True, X will never be mutated. Setting to False may reduce memory usage, at the cost of potentially mutating X. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/manifold/spectral_embedding.pyx b/python/cuml/cuml/manifold/spectral_embedding.pyx index 5532da5913..78d6285968 100644 --- a/python/cuml/cuml/manifold/spectral_embedding.pyx +++ b/python/cuml/cuml/manifold/spectral_embedding.pyx @@ -78,8 +78,7 @@ class SpectralEmbedding(InteropMixin, CMajorInputTagMixin, Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/manifold/t_sne.pyx b/python/cuml/cuml/manifold/t_sne.pyx index 8004c43bdb..b7da596a31 100644 --- a/python/cuml/cuml/manifold/t_sne.pyx +++ b/python/cuml/cuml/manifold/t_sne.pyx @@ -341,8 +341,7 @@ class TSNE(InteropMixin, In all cases the KNN should be computed using the same ``metric`` as provided to ``TSNE``. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/manifold/umap/umap.pyx b/python/cuml/cuml/manifold/umap/umap.pyx index b873af9bbb..c6dfcfcea4 100644 --- a/python/cuml/cuml/manifold/umap/umap.pyx +++ b/python/cuml/cuml/manifold/umap/umap.pyx @@ -844,8 +844,7 @@ class UMAP(InteropMixin, CMajorInputTagMixin, SparseInputTagMixin, Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/multiclass/multiclass.py b/python/cuml/cuml/multiclass/multiclass.py index b09eae20a4..5b5c8e5dbb 100644 --- a/python/cuml/cuml/multiclass/multiclass.py +++ b/python/cuml/cuml/multiclass/multiclass.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2020-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2020-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import cupy as cp @@ -133,8 +133,7 @@ class OneVsRestClassifier(_BaseMulticlassClassifier): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See @@ -181,8 +180,7 @@ class OneVsOneClassifier(_BaseMulticlassClassifier): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/naive_bayes/naive_bayes.py b/python/cuml/cuml/naive_bayes/naive_bayes.py index 6b63d65259..9711b5fb4e 100644 --- a/python/cuml/cuml/naive_bayes/naive_bayes.py +++ b/python/cuml/cuml/naive_bayes/naive_bayes.py @@ -1,5 +1,5 @@ # -# SPDX-FileCopyrightText: Copyright (c) 2020-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2020-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import cupy as cp @@ -234,8 +234,7 @@ class GaussianNB(_BaseNB): var_smoothing : float, default=1e-9 Portion of the largest variance of all features that is added to variances for calculation stability. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See @@ -820,8 +819,7 @@ class MultinomialNB(_BaseDiscreteNB): class_prior : array-like, size (n_classes) (default=None) Prior probabilities of the classes. If specified, the priors are not adjusted according to the data. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See @@ -916,8 +914,7 @@ class BernoulliNB(_BaseDiscreteNB): class_prior : array-like of shape (n_classes,), default=None Prior probabilities of the classes. If specified the priors are not adjusted according to the data. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See @@ -1053,8 +1050,7 @@ class ComplementNB(_BaseDiscreteNB): The default behavior mirrors the implementation found in Mahout and Weka, which do not follow the full algorithm described in Table 9 of the paper. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See @@ -1180,8 +1176,7 @@ class CategoricalNB(_BaseDiscreteNB): class_prior : array-like of shape (n_classes,), default=None Prior probabilities of the classes. If specified the priors are not adjusted according to the data. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/neighbors/kernel_density.pyx b/python/cuml/cuml/neighbors/kernel_density.pyx index 2b5f5afe37..767e954b73 100644 --- a/python/cuml/cuml/neighbors/kernel_density.pyx +++ b/python/cuml/cuml/neighbors/kernel_density.pyx @@ -1,5 +1,5 @@ # -# SPDX-FileCopyrightText: Copyright (c) 2022-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2022-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import cupy as cp @@ -102,8 +102,7 @@ class KernelDensity(InteropMixin, Base): metric_params : dict, default=None Additional parameters to be passed to the tree for use with the metric. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/neighbors/kneighbors_classifier.pyx b/python/cuml/cuml/neighbors/kneighbors_classifier.pyx index 4506bbf7b5..16d3676b3a 100644 --- a/python/cuml/cuml/neighbors/kneighbors_classifier.pyx +++ b/python/cuml/cuml/neighbors/kneighbors_classifier.pyx @@ -1,5 +1,5 @@ # -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import cupy as cp @@ -101,8 +101,7 @@ class KNeighborsClassifier(ClassifierMixin, FMajorInputTagMixin, NeighborsBase): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/neighbors/kneighbors_regressor.pyx b/python/cuml/cuml/neighbors/kneighbors_regressor.pyx index dc94f4a0f4..307e4d607a 100644 --- a/python/cuml/cuml/neighbors/kneighbors_regressor.pyx +++ b/python/cuml/cuml/neighbors/kneighbors_regressor.pyx @@ -1,5 +1,5 @@ # -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import cupy as cp @@ -107,8 +107,7 @@ class KNeighborsRegressor(RegressorMixin, FMajorInputTagMixin, NeighborsBase): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/neighbors/nearest_neighbors.pyx b/python/cuml/cuml/neighbors/nearest_neighbors.pyx index 32e4d67603..d94b3a650e 100644 --- a/python/cuml/cuml/neighbors/nearest_neighbors.pyx +++ b/python/cuml/cuml/neighbors/nearest_neighbors.pyx @@ -1,5 +1,5 @@ # -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import warnings @@ -1071,8 +1071,7 @@ class NearestNeighbors(NeighborsBase): Additional keyword arguments for the metric function. n_jobs : int (default = None) Ignored, here for scikit-learn API compatibility. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/preprocessing/_label.py b/python/cuml/cuml/preprocessing/_label.py index bf36c8fcdf..6e7e8140e9 100644 --- a/python/cuml/cuml/preprocessing/_label.py +++ b/python/cuml/cuml/preprocessing/_label.py @@ -28,8 +28,7 @@ class LabelEncoder(InteropMixin, Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/preprocessing/_target_encoder.py b/python/cuml/cuml/preprocessing/_target_encoder.py index c457a38700..8cda3b52ed 100644 --- a/python/cuml/cuml/preprocessing/_target_encoder.py +++ b/python/cuml/cuml/preprocessing/_target_encoder.py @@ -56,8 +56,7 @@ class TargetEncoder(InteropMixin, Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/preprocessing/encoders.py b/python/cuml/cuml/preprocessing/encoders.py index a1cc56b4fc..ceffc4a401 100644 --- a/python/cuml/cuml/preprocessing/encoders.py +++ b/python/cuml/cuml/preprocessing/encoders.py @@ -27,8 +27,7 @@ class BaseEncoder(Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See @@ -173,8 +172,7 @@ class OneHotEncoder(BaseEncoder): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See @@ -598,8 +596,7 @@ def __init__( verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/preprocessing/label.py b/python/cuml/cuml/preprocessing/label.py index 6836e5c172..42fbe46e0b 100644 --- a/python/cuml/cuml/preprocessing/label.py +++ b/python/cuml/cuml/preprocessing/label.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2020-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2020-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import cudf @@ -268,8 +268,7 @@ class LabelBinarizer(InteropMixin, Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/random_projection/random_projection.py b/python/cuml/cuml/random_projection/random_projection.py index a2d7264205..bf234136cd 100644 --- a/python/cuml/cuml/random_projection/random_projection.py +++ b/python/cuml/cuml/random_projection/random_projection.py @@ -190,8 +190,7 @@ class GaussianRandomProjection(_BaseRandomProjection): Controls the pseudo random number generator used to generate the projection matrix at fit time. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See @@ -296,8 +295,7 @@ class SparseRandomProjection(_BaseRandomProjection): Controls the pseudo random number generator used to generate the projection matrix at fit time. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/solvers/cd.pyx b/python/cuml/cuml/solvers/cd.pyx index 16d1094174..0c89a7b320 100644 --- a/python/cuml/cuml/solvers/cd.pyx +++ b/python/cuml/cuml/solvers/cd.pyx @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2018-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2018-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import cupy as cp @@ -245,8 +245,7 @@ class CD(FMajorInputTagMixin, Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/solvers/qn.pyx b/python/cuml/cuml/solvers/qn.pyx index a8778ec404..4ae6011ac9 100644 --- a/python/cuml/cuml/solvers/qn.pyx +++ b/python/cuml/cuml/solvers/qn.pyx @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import cupy as cp @@ -446,8 +446,7 @@ class QN(Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/solvers/sgd.pyx b/python/cuml/cuml/solvers/sgd.pyx index 207f40f73b..df7c474766 100644 --- a/python/cuml/cuml/solvers/sgd.pyx +++ b/python/cuml/cuml/solvers/sgd.pyx @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2018-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2018-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 import cupy as cp import numpy as np @@ -339,8 +339,7 @@ class SGD(FMajorInputTagMixin, Base): The old learning rate is generally divide by 5 n_iter_no_change : int (default = 5) The number of epochs to train without any improvement in the model - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/svm/linear_svc.py b/python/cuml/cuml/svm/linear_svc.py index a19da266e3..89cb813c96 100644 --- a/python/cuml/cuml/svm/linear_svc.py +++ b/python/cuml/cuml/svm/linear_svc.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2021-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2021-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import numbers @@ -61,8 +61,7 @@ class LinearSVC(InteropMixin, LinearClassifierMixin, ClassifierMixin, Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/svm/linear_svr.py b/python/cuml/cuml/svm/linear_svr.py index 7d58ea9404..9923956c21 100644 --- a/python/cuml/cuml/svm/linear_svr.py +++ b/python/cuml/cuml/svm/linear_svr.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2021-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2021-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import cupy as cp @@ -54,8 +54,7 @@ class LinearSVR(InteropMixin, LinearPredictMixin, RegressorMixin, Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/svm/svc.py b/python/cuml/cuml/svm/svc.py index 71498a2ee2..05c4089404 100644 --- a/python/cuml/cuml/svm/svc.py +++ b/python/cuml/cuml/svm/svc.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import cupy as cp @@ -87,8 +87,7 @@ class SVC(ClassifierMixin, SVMBase): We monitor how much our stopping criteria changes during outer iterations. If it does not change (changes less then 1e-3*tol) for nochange_steps consecutive steps, then we stop training. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/svm/svr.py b/python/cuml/cuml/svm/svr.py index 8abeba33c3..afc15d14f3 100644 --- a/python/cuml/cuml/svm/svr.py +++ b/python/cuml/cuml/svm/svr.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # from cuml.common.doc_utils import generate_docstring @@ -61,8 +61,7 @@ class SVR(RegressorMixin, SVMBase): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/tsa/arima.pyx b/python/cuml/cuml/tsa/arima.pyx index 4f2c15ae70..43b9cd7f31 100644 --- a/python/cuml/cuml/tsa/arima.pyx +++ b/python/cuml/cuml/tsa/arima.pyx @@ -181,8 +181,7 @@ class ARIMA(Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/tsa/auto_arima.pyx b/python/cuml/cuml/tsa/auto_arima.pyx index 99f3b08ed4..731184070c 100644 --- a/python/cuml/cuml/tsa/auto_arima.pyx +++ b/python/cuml/cuml/tsa/auto_arima.pyx @@ -115,8 +115,7 @@ class AutoARIMA(Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See diff --git a/python/cuml/cuml/tsa/holtwinters.pyx b/python/cuml/cuml/tsa/holtwinters.pyx index 3bae98fdf7..3ef06d0976 100644 --- a/python/cuml/cuml/tsa/holtwinters.pyx +++ b/python/cuml/cuml/tsa/holtwinters.pyx @@ -145,8 +145,7 @@ class ExponentialSmoothing(Base): verbose : int or boolean, default=False Sets logging level. It must be one of `cuml.common.logger.level_*`. See :ref:`verbosity-levels` for more info. - output_type : {'input', 'array', 'dataframe', 'series', 'df_obj', \ - 'numba', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None + output_type : {None, 'input', 'cupy', 'numpy', 'cudf', 'pandas'}, default=None Return results and set estimator attributes to the indicated output type. If None, the output type set at the module level (`cuml.global_settings.output_type`) will be used. See From 8d8bb1dfb91145786b6ef00496b8ef5f1807ab4e Mon Sep 17 00:00:00 2001 From: Jim Crist-Harif Date: Mon, 20 Jul 2026 16:43:29 -0500 Subject: [PATCH 4/9] Deprecate numba special casing in `train_test_split` --- python/cuml/cuml/model_selection/_split.py | 18 ++++++++++++++---- python/cuml/tests/test_train_test_split.py | 10 +++++++--- 2 files changed, 21 insertions(+), 7 deletions(-) diff --git a/python/cuml/cuml/model_selection/_split.py b/python/cuml/cuml/model_selection/_split.py index 6d0bfb2c77..4754558155 100644 --- a/python/cuml/cuml/model_selection/_split.py +++ b/python/cuml/cuml/model_selection/_split.py @@ -1,6 +1,8 @@ -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # +import warnings + import cudf import cupy as cp from numba import cuda as numba_cuda @@ -31,9 +33,9 @@ def train_test_split( Parameters ---------- *arrays : sequence of indexables with same length / shape[0] - Allowed inputs are cudf DataFrames/Series, cupy arrays, numba device - arrays, numpy arrays, pandas DataFrames/Series, or any array-like - objects with a shape attribute. + Allowed inputs are cudf DataFrames/Series, cupy arrays, numpy arrays, + pandas DataFrames/Series, or any array-like objects with a shape + attribute. test_size : float or int, default=None If float, should be between 0.0 and 1.0 and represent the proportion @@ -112,6 +114,14 @@ def train_test_split( stratify=stratify, ) + if any(o == "numba" for o in original_types): + warnings.warn( + "Handling `numba` arrays in `train_test_split` was " + "deprecated in 26.08 and will be removed in 26.10. Please " + "coerce the input to `cupy` with `cupy.asarray` instead.", + FutureWarning, + ) + # Convert numba arrays back to numba device arrays # There are two results for each original array. final_results = [] diff --git a/python/cuml/tests/test_train_test_split.py b/python/cuml/tests/test_train_test_split.py index 708314a823..9660555332 100644 --- a/python/cuml/tests/test_train_test_split.py +++ b/python/cuml/tests/test_train_test_split.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # @@ -40,9 +40,13 @@ def ctor(X): else: return array_constructor.Series(X) - return (backend_name, ctor) + yield (backend_name, ctor) - return (backend_name, array_constructor) + elif backend_name == "numba": + with pytest.warns(FutureWarning, match="Handling `numba` arrays"): + yield (backend_name, array_constructor) + else: + yield (backend_name, array_constructor) @pytest.mark.parametrize("train_size", [0.2, 0.6, 0.8]) From 05eaa733d50bf756b104ed5dcfd8b79e26332666 Mon Sep 17 00:00:00 2001 From: Jim Crist-Harif Date: Mon, 20 Jul 2026 20:51:40 -0500 Subject: [PATCH 5/9] Fixup tests --- python/cuml/tests/dask/test_dask_global_settings.py | 4 ++-- python/cuml/tests/test_compose.py | 6 +++++- python/cuml/tests/test_preprocessing.py | 6 +++++- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/python/cuml/tests/dask/test_dask_global_settings.py b/python/cuml/tests/dask/test_dask_global_settings.py index 2e300ad01c..5def44ae90 100644 --- a/python/cuml/tests/dask/test_dask_global_settings.py +++ b/python/cuml/tests/dask/test_dask_global_settings.py @@ -1,5 +1,5 @@ # -# SPDX-FileCopyrightText: Copyright (c) 2021-2025, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2021-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # # pylint: disable=no-member @@ -17,7 +17,7 @@ _GlobalSettingsData, ) -test_output_types_str = ("numpy", "numba", "cupy", "cudf") +test_output_types_str = ("numpy", "cupy", "cudf") test_global_settings_data_obj = _GlobalSettingsData() diff --git a/python/cuml/tests/test_compose.py b/python/cuml/tests/test_compose.py index d5f65adfb4..225ec41696 100644 --- a/python/cuml/tests/test_compose.py +++ b/python/cuml/tests/test_compose.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2021-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2021-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # @@ -31,6 +31,10 @@ sparse_clf_dataset, ) +pytestmark = pytest.mark.filterwarnings( + "ignore:Outputting `numba` arrays:FutureWarning" +) + @pytest.mark.parametrize("remainder", ["drop", "passthrough"]) @pytest.mark.parametrize( diff --git a/python/cuml/tests/test_preprocessing.py b/python/cuml/tests/test_preprocessing.py index 2dd2fecb93..df8f1d5532 100644 --- a/python/cuml/tests/test_preprocessing.py +++ b/python/cuml/tests/test_preprocessing.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2020-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2020-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # @@ -72,6 +72,10 @@ sparse_nan_filled_positive, ) +pytestmark = pytest.mark.filterwarnings( + "ignore:Outputting `numba` arrays:FutureWarning" +) + @pytest.mark.parametrize("feature_range", [(0, 1), (0.1, 0.8)]) def test_minmax_scaler( From c24abeface3675b3c470cf2e0b4e88890db42897 Mon Sep 17 00:00:00 2001 From: Jim Crist-Harif Date: Tue, 21 Jul 2026 11:56:58 -0500 Subject: [PATCH 6/9] Fixup --- python/cuml/cuml/internals/outputs.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/python/cuml/cuml/internals/outputs.py b/python/cuml/cuml/internals/outputs.py index 0b7eab194e..259636193c 100644 --- a/python/cuml/cuml/internals/outputs.py +++ b/python/cuml/cuml/internals/outputs.py @@ -58,7 +58,13 @@ def check_output_type(output_type: str) -> str: def warn_if_output_type_deprecated(output_type: str): """Warn if the specified `output_type` is deprecated""" - if output_type in ("numba", "array", "df_obj", "dataframe", "series"): + if isinstance(output_type, str) and output_type in ( + "numba", + "array", + "df_obj", + "dataframe", + "series", + ): alt = "cupy" if output_type in ("numba", "array") else "cudf" if output_type in ("dataframe", "series"): suffix = ( From d1d38a855a093d996fd8af2d2ea35cfca8187014 Mon Sep 17 00:00:00 2001 From: Jim Crist-Harif Date: Wed, 22 Jul 2026 14:34:40 -0500 Subject: [PATCH 7/9] Exclude xgboost on 3.11 test runs --- dependencies.yaml | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/dependencies.yaml b/dependencies.yaml index dd2e5d6c4d..4ff7313ea9 100644 --- a/dependencies.yaml +++ b/dependencies.yaml @@ -41,6 +41,9 @@ files: output: none includes: # "devcontainers" includes everything in "all", excluding test_python_xgboost + # The libxgboost package depends on librmm but we do not want to have a + # package depending on librmm in devcontainers since it should be built + # from source. - common_build - cuda - cuda_version @@ -715,17 +718,20 @@ dependencies: packages: - dask-ml>=2024 test_python_xgboost: - common: - - output_types: [conda] - packages: - # We must separate xgboost into its own list so that it is not - # included in the "devcontainers" key. The libxgboost package depends - # on librmm but we do not want to have a package depending on librmm - # in devcontainers since it should be built from source. - - rapids-xgboost==26.8.*,>=0.0.0a0 specific: + - output_types: [conda] + matrices: + - matrix: + py: "3.11" + packages: [] + - matrix: + packages: + - rapids-xgboost==26.8.*,>=0.0.0a0 - output_types: [requirements, pyproject] matrices: + - matrix: + py: "3.11" + packages: [] - matrix: cuda: "12.*" cuda_suffixed: "true" From 580a4698963ab78820562922c44a4a826e60be2b Mon Sep 17 00:00:00 2001 From: Jim Crist-Harif Date: Wed, 22 Jul 2026 15:28:23 -0500 Subject: [PATCH 8/9] Fixup flaky ivfpq test --- python/cuml/tests/test_pickle.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/python/cuml/tests/test_pickle.py b/python/cuml/tests/test_pickle.py index 54e466f5cc..8fd3ad1318 100644 --- a/python/cuml/tests/test_pickle.py +++ b/python/cuml/tests/test_pickle.py @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2019-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # @@ -483,8 +483,9 @@ def test_nearest_neighbors_pickle(algorithm): # differences upon reload. For now we check for comparable performance # just to ensure things are wired together properly. # See https://github.com/rapidsai/cuml/issues/8144. + min_acc = 0.75 if algorithm == "ivfpq" else 0.9 accuracy = (i1 == i2).sum() / i1.size - assert accuracy >= 0.9 + assert accuracy >= min_acc atol = 5e-3 if algorithm == "ivfpq" else 1e-3 np.testing.assert_allclose(d1, d2, atol=atol) else: From faade36879ea6257bf8ebe3863baa1683db878b0 Mon Sep 17 00:00:00 2001 From: Jim Crist-Harif Date: Wed, 22 Jul 2026 16:17:01 -0500 Subject: [PATCH 9/9] More fixup Doesn't actually make sense to compare distances if indices are shuffled, since distances would likewise be shuffled. Just compare indices. --- python/cuml/tests/test_pickle.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/python/cuml/tests/test_pickle.py b/python/cuml/tests/test_pickle.py index 8fd3ad1318..4777626ccd 100644 --- a/python/cuml/tests/test_pickle.py +++ b/python/cuml/tests/test_pickle.py @@ -486,8 +486,6 @@ def test_nearest_neighbors_pickle(algorithm): min_acc = 0.75 if algorithm == "ivfpq" else 0.9 accuracy = (i1 == i2).sum() / i1.size assert accuracy >= min_acc - atol = 5e-3 if algorithm == "ivfpq" else 1e-3 - np.testing.assert_allclose(d1, d2, atol=atol) else: np.testing.assert_allclose(i1, i2) np.testing.assert_allclose(d1, d2)