code: def test_matching_image_shapes(self):
      to_match = {
          "image": (42, 43, 44, 1, 2),
          "label": (42, 43, 44, 1, 2),
      }
  
      new_shape = ImageWindow.from_data_reader_properties(
          **get_static_window_param()
      ).match_image_shapes(to_match)
      self.assertAllEqual(new_shape["image"], [10, 10, 2, 1, 2])
      self.assertAllEqual(new_shape["label"], [5, 5, 1, 1, 1])
  
      new_shape = ImageWindow.from_data_reader_properties(
          **get_dynamic_image_window()
      ).match_image_shapes(to_match)
      self.assertAllEqual(new_shape["image"], [10, 10, 44, 1, 2])
      self.assertAllEqual(new_shape["label"], [2, 43, 44, 1, 1])
  
      new_shape = ImageWindow.from_data_reader_properties(
          **get_all_dynamic_image_window()
      ).match_image_shapes(to_match)
      self.assertAllEqual(new_shape["image"], [42, 43, 44, 1, 2])
      self.assertAllEqual(new_shape["label"], [42, 43, 44, 1, 1])
  
file_path: NiftyNet/tests/image_window_test.py
imports: from __future__ import absolute_import, print_function
  import tensorflow
  from niftynet.engine.image_window import ImageWindow
  from niftynet.utilities.util_common import ParserNamespace
  from tests.niftynet_testcase import NiftyNetTestCase
label_desc: Use image node_id 3 for calling the ImageWindowTest obj's underlying member method code with example usage: obj.test_matching_image_shapes() without return types