code: def points3d_color_by_scalar(
      positions,
      scalars,
      sizes=None,
      mode="sphere",
      scale_factor=1.0,
      colormap="jet",
      opacity=1.0,
  ):
      assert scalars is not None
  
      num_pts = positions.shape[0]
  
      S = c_[ones(num_pts), zeros(num_pts), zeros(num_pts)]
  
      if sizes is not None:
          S = S * sizes[:, newaxis]
  
      pts = mayavi.mlab.quiver3d(
          positions[:, 0],
          positions[:, 1],
          positions[:, 2],
          S[:, 0],
          S[:, 1],
          S[:, 2],
          scalars=scalars,
          mode=mode,
          scale_factor=scale_factor,
          colormap=colormap,
          opacity=opacity,
      )
      pts.glyph.color_mode = "color_by_scalar"
      pts.glyph.glyph_source.glyph_source.center = [0, 0, 0]
  
imports: from pylab import *
  import mayavi.mlab
label_desc: Use image node_id 1 for calling a global function with example usage: points3d_color_by_scalar(positions, scalars, sizes, mode, scale_factor, colormap, opacity) without return types