code: def g_subset(g, atwts, atwt,
              digits=_DEF.SYMM_ATWT_ROUND_DIGITS):
      
  
      # Imports
      import numpy as np
  
      # Ensure g and atwts are n-D vectors
      g = make_nd_vec(g, nd=None, t=np.float64, norm=False)
      atwts = make_nd_vec(atwts, nd=None, t=np.float64, norm=False)
  
      # Ensure dims match (should already be checked at object creation...)
      if not (len(g) == 3*len(atwts)):
          raise ValueError("Dim mismatch [len(g) != 3*len(ats)].")
      ## end if
  
      # Pull into coordinate groups
      co = np.split(g, g.shape[0] // 3)
  
      # Filter by the indicated atomic weight
      cf = [c for (c,a) in zip(co, atwts) if \
                      np.round(a, digits) == np.round(atwt, digits)]
  
      # Expand back to single vector, if possible
      if not cf == []:
          g_sub = np.concatenate(cf, axis=0)
          g_sub = g_sub.reshape((g_sub.shape[0],1))
      else:
          g_sub = []
      ## end if
  
      # Return the subset
      return g_sub
docs: Extract a subset of a geometry matching a desired atom.
  
      .. todo:: Complete g_subset docstring