code: def test_bundle_maps(rng):
      scene = window.Scene()
      bundle = fornix_streamlines()
      bundle, _ = center_streamlines(bundle)
  
      mat = np.array(
          [
              [1, 0, 0, 100],
              [0, 1, 0, 100],
              [0, 0, 1, 100],
              [0, 0, 0, 1.0],
          ]
      )
  
      bundle = transform_streamlines(bundle, mat)
  
      # metric = np.random.rand(*(200, 200, 200))
      metric = 100 * np.ones((200, 200, 200))
  
      # add lower values
      metric[100, :, :] = 100 * 0.5
  
      # create a nice orange-red colormap
      lut = actor.colormap_lookup_table(
          scale_range=(0.0, 100.0),
          hue_range=(0.0, 0.1),
          saturation_range=(1, 1),
          value_range=(1.0, 1),
      )
  
      line = actor.line(
          bundle, metric, linewidth=0.1, lookup_colormap=lut
      )
      scene.add(line)
      scene.add(actor.scalar_bar(lut, " "))
  
      report = window.analyze_scene(scene)
  
      npt.assert_almost_equal(report.actors, 1)
      # window.show(scene)
  
      scene.clear()
  
      nb_points = np.sum([len(b) for b in bundle])
      values = 100 * rng.random((nb_points))
      # values[:nb_points/2] = 0
  
      line = actor.streamtube(
          bundle, values, linewidth=0.1, lookup_colormap=lut
      )
      scene.add(line)
      # window.show(scene)
  
      report = window.analyze_scene(scene)
      npt.assert_equal(report.actors_classnames[0], "vtkLODActor")
  
      scene.clear()
  
      colors = rng.random((nb_points, 3))
      # values[:nb_points/2] = 0
  
      line = actor.line(bundle, colors, linewidth=2)
      scene.add(line)
      # window.show(scene)
  
      report = window.analyze_scene(scene)
      npt.assert_equal(report.actors_classnames[0], "vtkLODActor")
      # window.show(scene)
  
      arr = window.snapshot(scene)
      report2 = window.analyze_snapshot(arr)
      npt.assert_equal(report2.objects, 1)
  
      # try other input options for colors
      scene.clear()
      actor.line(bundle, (1.0, 0.5, 0))
      actor.line(bundle, np.arange(len(bundle)))
      actor.line(bundle)
      colors = [rng.random(b.shape) for b in bundle]
      actor.line(bundle, colors=colors)
  
imports: import warnings
  import pytest
  import numpy
  import numpy.testing
  from dipy.testing.decorators import use_xvfb, set_random_number_generator
  from dipy.utils.optpkg import optional_package
  from dipy.data import get_sphere
  from dipy.align.reslice import reslice
  from dipy.data import read_stanford_labels
  from dipy.reconst.shm import CsaOdfModel
  from dipy.data import default_sphere
  from dipy.direction import peaks_from_model
  from dipy.tracking import utils
  from dipy.tracking.stopping_criterion import ThresholdStoppingCriterion
  from dipy.tracking.local_tracking import LocalTracking
  from dipy.reconst.shm import descoteaux07_legacy_msg, sh_to_sf_matrix
  from dipy.align.tests.test_streamlinear import fornix_streamlines
  from dipy.tracking.streamline import center_streamlines, transform_streamlines
  from dipy.reconst.dti import color_fa, fractional_anisotropy
label_desc: Use image node_id 3 for calling a global function with example usage: test_bundle_maps(rng) without return types