code: def fit(self, X, y, random_state=np.random):
      
      X, y = self._prepare_inputs(X, y, ensure_min_samples=2)
      chunks = Constraints(y).chunks(num_chunks=self.num_chunks,
                                     chunk_size=self.chunk_size,
                                     random_state=random_state)
      return RCA.fit(self, X, chunks)
docs: Create constraints from labels and learn the RCA model.
      Needs num_constraints specified in constructor.
  
      Parameters
      ----------
      X : (n x d) data matrix
          each row corresponds to a single instance
      y : (n) data labels
      random_state : a random.seed object to fix the random_state if needed.