class_docstr: Mixin class for all transformers in scikit-learn.
docstr: Fit to data, then transform it.
  
  Fits transformer to X and y with optional parameters fit_params
  and returns a transformed version of X.
  
  Parameters
  ----------
  X : {array-like, sparse matrix, dataframe} of shape                 (n_samples, n_features)
  
  y : ndarray of shape (n_samples,), default=None
      Target values.
  
  **fit_params : dict
      Additional fit parameters.
  
  Returns
  -------
  X_new : ndarray array of shape (n_samples, n_features_new)
      Transformed array.
docstr_tok: ["Fit","to","data",",","then","transform","it",".","Fits","transformer","to","X","and","y","with","optional","parameters","fit_params","and","returns","a","transformed","version","of","X.","Parameters","--","--","--","--","--","X",":","{","array-like",",","sparse","matrix",",","dataframe","}","of","shape","(","n_samples",",","n_features",")","y",":","ndarray","of","shape","(","n_samples",",",")",",","default=None","Target","values",".","*","*","fit_params",":","dict","Additional","fit","parameters",".","Returns","--","--","--","-","X_new",":","ndarray","array","of","shape","(","n_samples",",","n_features_new",")","Transformed","array","."]
code: def fit_transform(self, X, y=None, **fit_params) -> SparseCumlArray:
      """
          Fit to data, then transform it.
  
          Fits transformer to X and y with optional parameters fit_params
          and returns a transformed version of X.
  
          Parameters
          ----------
          X : {array-like, sparse matrix, dataframe} of shape \
                  (n_samples, n_features)
  
          y : ndarray of shape (n_samples,), default=None
              Target values.
  
          **fit_params : dict
              Additional fit parameters.
  
          Returns
          -------
          X_new : ndarray array of shape (n_samples, n_features_new)
              Transformed array.
          """
      # non-optimized default implementation; override when a better
      # method is possible for a given clustering algorithm
      if y is None:
          # fit method of arity 1 (unsupervised transformation)
          return self.fit(X, **fit_params).transform(X)
      else:
          # fit method of arity 2 (supervised transformation)
          return self.fit(X, y, **fit_params).transform(X)
  
file_path: cuml/python/cuml/_thirdparty/sklearn/utils/skl_dependencies.py
imports: from cuml.internals.array_sparse import SparseCumlArray
  from ....internals.base import Base
  from ..utils.validation import check_X_y
  from ....thirdparty_adapters import check_array
label_desc: Use image node_id 1 for calling the TransformerMixin obj's underlying member method code with example usage: obj.fit_transform(X, y) and returns: self, self