code: def fit(self, X, y=None, **fit_params):
          
          if not self.warm_start or not self.initialized_:
              self.initialize()
  
          self.partial_fit(X, y, **fit_params)
          return self
docs: Initialize and fit the module.
  
          If the module was already initialized, by calling fit, the
          module will be re-initialized (unless ``warm_start`` is True).
  
          Parameters
          ----------
          X : input data, compatible with skorch.dataset.Dataset
            By default, you should be able to pass:
  
              * numpy arrays
              * torch tensors
              * pandas DataFrame or Series
              * scipy sparse CSR matrices
              * a dictionary of the former three
              * a list/tuple of the former three
              * a Dataset
  
            If this doesn't work with your data, you have to pass a
            ``Dataset`` that can deal with the data.
  
          y : target data, compatible with skorch.dataset.Dataset
            The same data types as for ``X`` are supported. If your X is
            a Dataset that contains the target, ``y`` may be set to
            None.
  
          **fit_params : dict
            Additional parameters passed to the ``forward`` method of
            the module and to the ``self.train_split`` call.