code: def fit(self, X, y=None):
          
          X = check_array(X, accept_sparse='csr')
  
          kwargs = self.get_params()
          del kwargs['metric_params']
          kwargs.update(self.metric_params)
  
          self.labels_, self._cluster_hierarchy = robust_single_linkage(
              X, **kwargs)
  
          return self
docs: Perform robust single linkage clustering from features or
          distance matrix.
  
          Parameters
          ----------
          X : array or sparse (CSR) matrix of shape (n_samples, n_features), or \
                  array of shape (n_samples, n_samples)
              A feature array, or array of distances between samples if
              ``metric='precomputed'``.
  
          Returns
          -------
          self : object
              Returns self