code: def test_bundlewarp_viz():
      with tempfile.TemporaryDirectory() as temp_dir:
          cingulum_bundles = two_cingulum_bundles()
  
          cb1 = cingulum_bundles[0]
          cb1 = Streamlines(set_number_of_points(cb1, 20))
  
          cb2 = cingulum_bundles[1]
          cb2 = Streamlines(set_number_of_points(cb2, 20))
  
          deformed_bundle, affine_bundle, _, _, _ = bundlewarp(cb1, cb2)
  
          offsets, directions, colors = bundlewarp_vector_filed(
              affine_bundle, deformed_bundle
          )
          points_aligned, _ = unlist_streamlines(affine_bundle)
  
          fname = os.path.join(temp_dir, "test_vector_field.png")
          viz_vector_field(
              points_aligned, directions, colors, offsets, fname
          )
          assert_equal(os.path.exists(fname), True)
  
          fname = os.path.join(temp_dir, "test_mag_viz.png")
          viz_displacement_mag(affine_bundle, offsets, fname)
          assert_equal(os.path.exists(fname), True)
  
file_path: dipy/dipy/viz/tests/test_streamline.py
imports: import tempfile
  import os
  from numpy.testing import assert_raises, assert_equal
  import pytest
  from dipy.align.streamwarp import bundlewarp, bundlewarp_vector_filed
  from dipy.data import read_five_af_bundles, two_cingulum_bundles
  from dipy.tracking.streamline import set_number_of_points, unlist_streamlines, Streamlines
  from dipy.utils.optpkg import optional_package
label_desc: Use image node_id 3 for calling a global function with example usage: test_bundlewarp_viz() without return types