code: def _predict_gpu(self, X, queue=None):
      X = _check_array(
          X, accept_sparse="csr", dtype=[np.float64, np.float32]
      )
      onedal_model = getattr(self, "_onedal_model", None)
      n_features = getattr(self, "n_features_in_", None)
      n_samples_fit_ = getattr(self, "n_samples_fit_", None)
      shape = getattr(X, "shape", None)
      if (
          n_features
          and shape
          and len(shape) > 1
          and shape[1] != n_features
      ):
          raise ValueError(
              (
                  f"X has {X.shape[1]} features, "
                  f"but KNNClassifier is expecting "
                  f"{n_features} features as input"
              )
          )
  
      _check_is_fitted(self)
  
      self._fit_method = super()._parse_auto_method(
          self.algorithm, n_samples_fit_, n_features
      )
  
      params = self._get_onedal_params(X)
  
      prediction_result = self._onedal_predict(
          onedal_model, X, params, queue=queue
      )
      responses = from_table(prediction_result.responses)
      result = responses.ravel()
  
      return result
  
imports: from abc import ABCMeta
  from numbers import Integral
  import numpy
  from daal4py import bf_knn_classification_prediction, bf_knn_classification_training, kdtree_knn_classification_prediction, kdtree_knn_classification_training
  from onedal import _backend
  from ..common._estimator_checks import _check_is_fitted, _is_classifier, _is_regressor
  from ..common._mixin import ClassifierMixin, RegressorMixin
  from ..common._policy import _get_policy
  from ..datatypes import _convert_to_supported, from_table, to_table
  from ..utils import _check_array, _check_classification_targets, _check_n_features, _check_X_y, _column_or_1d, _num_samples
label_desc: Use image node_id 8 for calling the KNeighborsRegressor obj's underlying member method code with example usage: obj._predict_gpu(X, queue) and returns: result