code: def PMIS(S):
      
      S = remove_diagonal(S)
      weights, G, S, T = preprocess(S)
      return MIS(G, weights)
docs: C/F splitting using the Parallel Modified Independent Set method.
  
      Parameters
      ----------
      S : csr_matrix
          Strength of connection matrix indicating the strength between nodes i
          and j (S_ij)
  
      Returns
      -------
      splitting : ndarray
          Array of length of S of ones (coarse) and zeros (fine)
  
      Examples
      --------
      >>> from pyamg.gallery import poisson
      >>> from pyamg.classical import PMIS
      >>> S = poisson((7,), format='csr') # 1D mesh with 7 vertices
      >>> splitting = PMIS(S)
  
      See Also
      --------
      MIS
  
      References
      ----------
      .. [6] Hans De Sterck, Ulrike M Yang, and Jeffrey J Heys
         "Reducing complexity in parallel algebraic multigrid preconditioners"
         SIAM Journal on Matrix Analysis and Applications 2006; 27:1019-1039.