code: def sphere_density(npoints):
      """Return the points and area of a npoints**2 points sampled on a sphere
  
      Returns
      -------
      s : array of shape(npoints ** 2, 3)
      area: array of shape(npoints)
      """
      u = np.linspace(0, 2 * np.pi, npoints + 1)[:npoints]
      v = np.linspace(0, np.pi, npoints + 1)[:npoints]
      s = np.vstack(
          (
              np.ravel(np.outer(np.cos(u), np.sin(v))),
              np.ravel(np.outer(np.sin(u), np.sin(v))),
              np.ravel(np.outer(np.ones(np.size(u)), np.cos(v))),
          )
      ).T
      area = (
          np.abs(np.ravel(np.outer(np.ones(np.size(u)), np.sin(v))))
          * np.pi**2
          * 2
          * 1.0
          / (npoints**2)
      )
      return s, area
  
imports: from warnings import warn
  import numpy
label_desc: Use image node_id 4 for calling a global function with example usage: sphere_density(npoints) and returns: s,  area