code: def simulated_bundles(no_streamlines=50, n_pts=100):
      rng = np.random.default_rng()
  
      t = np.linspace(-10, 10, n_pts)
  
      bundle = []
      for i in np.linspace(3, 5, no_streamlines):
          pts = np.vstack(
              (np.cos(2 * t / np.pi), np.zeros(t.shape) + i, t)
          ).T
          bundle.append(pts)
  
      start = rng.integers(10, 30, no_streamlines)
      end = rng.integers(60, 100, no_streamlines)
  
      bundle = [
          10 * streamline[start[i] : end[i]]
          for (i, streamline) in enumerate(bundle)
      ]
      bundle = [
          np.ascontiguousarray(streamline) for streamline in bundle
      ]
  
      return bundle
  
imports: import numpy
  from dipy.tracking.distances import approx_polygon_track
  from dipy.tracking.streamline import set_number_of_points
  from dipy.tracking.utils import length
  import matplotlib.pyplot
  from dipy.viz import window, actor
label_desc: Use image node_id 1 for calling a global function with example usage: simulated_bundles(no_streamlines, n_pts) and returns: bundle