code: def __init__(self):
      app.Canvas.__init__(self, keys="interactive")
      ps = self.pixel_scale
  
      n = 10000
      pos = 0.25 * np.random.randn(n, 2).astype(np.float32)
      color = np.random.uniform(0, 1, (n, 3)).astype(np.float32)
      size = np.random.uniform(2 * ps, 12 * ps, (n, 1)).astype(
          np.float32
      )
  
      self.points = MarkerVisual(pos=pos, color=color, size=size)
      w, h = self.size
      self.points.transform = STTransform(
          scale=(w / 2.0, h / 2.0), translate=(w / 2.0, h / 2.0)
      )
  
file_path: vispy/examples/basics/visuals/custom_visual.py
imports: from __future__ import division
  import numpy
  from vispy import app
  from vispy.gloo import VertexBuffer
  from vispy.visuals import Visual
  from vispy.visuals.transforms import STTransform
label_desc: Use image node_id 1 to create a new Canvas object from inherited base classes: app with example: obj = Canvas()