parameters: (self, X, y, classes=None)
return_statement: return self
docstring: Partially fit underlying estimators
  
          Should be used when memory is inefficient to train all data.
          Chunks of data can be passed in several iteration.
  
          Parameters
          ----------
          X : (sparse) array-like, shape = [n_samples, n_features]
              Data.
  
          y : (sparse) array-like, shape = [n_samples, ], [n_samples, n_classes]
              Multi-class targets. An indicator matrix turns on multilabel
              classification.
  
          classes : array, shape (n_classes, )
              Classes across all calls to partial_fit.
              Can be obtained via `np.unique(y_all)`, where y_all is the
              target vector of the entire dataset.
              This argument is only required in the first call of partial_fit
              and can be omitted in the subsequent calls.
  
          Returns
          -------
          self
docstring_summary: Partially fit underlying estimators
docstring_tokens: Partially fit underlying estimators
function: def partial_fit(self, X, y, classes=None):
          """Partially fit underlying estimators
  
          Should be used when memory is inefficient to train all data.
          Chunks of data can be passed in several iteration.
  
          Parameters
          ----------
          X : (sparse) array-like, shape = [n_samples, n_features]
              Data.
  
          y : (sparse) array-like, shape = [n_samples, ], [n_samples, n_classes]
              Multi-class targets. An indicator matrix turns on multilabel
              classification.
  
          classes : array, shape (n_classes, )
              Classes across all calls to partial_fit.
              Can be obtained via `np.unique(y_all)`, where y_all is the
              target vector of the entire dataset.
              This argument is only required in the first call of partial_fit
              and can be omitted in the subsequent calls.
  
          Returns
          -------
          self
          """
          if _check_partial_fit_first_call(self, classes):
              if not hasattr(self.estimator, "partial_fit"):
                  raise ValueError(("Base estimator {0}, doesn't have "
                                   "partial_fit method").format(self.estimator))
              self.estimators_ = [clone(self.estimator) for _ in range
                                  (self.n_classes_)]
  
              # A sparse LabelBinarizer, with sparse_output=True, has been
              # shown to outperform or match a dense label binarizer in all
              # cases and has also resulted in less or equal memory consumption
              # in the fit_ovr function overall.
              self.label_binarizer_ = LabelBinarizer(sparse_output=True)
              self.label_binarizer_.fit(self.classes_)
  
          if np.setdiff1d(y, self.classes_):
              raise ValueError(("Mini-batch contains {0} while classes " +
                               "must be subset of {1}").format(np.unique(y),
                                                               self.classes_))
  
          Y = self.label_binarizer_.transform(y)
          Y = Y.tocsc()
          columns = (col.toarray().ravel() for col in Y.T)
  
          self.estimators_ = Parallel(n_jobs=self.n_jobs)(
              delayed(_partial_fit_binary)(self.estimators_[i], X,
                                           next(columns))
              for i in range(self.n_classes_))
  
          return self
function_tokens: def partial_fit ( self , X , y , classes = None ) : if _check_partial_fit_first_call ( self , classes ) : if not hasattr ( self . estimator , "partial_fit" ) : raise ValueError ( ( "Base estimator {0}, doesn't have " "partial_fit method" ) . format ( self . estimator ) ) self . estimators_ = [ clone ( self . estimator ) for _ in range ( self . n_classes_ ) ] # A sparse LabelBinarizer, with sparse_output=True, has been # shown to outperform or match a dense label binarizer in all # cases and has also resulted in less or equal memory consumption # in the fit_ovr function overall. self . label_binarizer_ = LabelBinarizer ( sparse_output = True ) self . label_binarizer_ . fit ( self . classes_ ) if np . setdiff1d ( y , self . classes_ ) : raise ValueError ( ( "Mini-batch contains {0} while classes " + "must be subset of {1}" ) . format ( np . unique ( y ) , self . classes_ ) ) Y = self . label_binarizer_ . transform ( y ) Y = Y . tocsc ( ) columns = ( col . toarray ( ) . ravel ( ) for col in Y . T ) self . estimators_ = Parallel ( n_jobs = self . n_jobs ) ( delayed ( _partial_fit_binary ) ( self . estimators_ [ i ] , X , next ( columns ) ) for i in range ( self . n_classes_ ) ) return self