code: def pca(X, n_components=2, random_state=None):
      
      pca_ = PCA(n_components=n_components, random_state=random_state)
      embedding = pca_.fit_transform(X)
  
      # The PCA embedding may have high variance, which leads to poor convergence
      normalization = np.std(embedding[:, 0]) * 100
      embedding /= normalization
  
      return embedding
docs: Initialize an embedding using the top principal components.
  
      Parameters
      ----------
      X: np.ndarray
          The data matrix.
  
      n_components: int
          The dimension of the embedding space.
  
      random_state: Union[int, RandomState]
          If the value is an int, random_state is the seed used by the random
          number generator. If the value is a RandomState instance, then it will
          be used as the random number generator. If the value is None, the random
          number generator is the RandomState instance used by `np.random`.
  
      Returns
      -------
      initialization: np.ndarray