code: def test_builder_eval_ios17_invalid(self, backend):
      x = np.arange(1, 17, dtype=np.float32).reshape(1, 1, 4, 4)
      three_boxes = np.array(
          [
              [0.1, 0.3, 1.3, 1.0],
              [0.5, 1.8, 1.0, 0.3],
              [0.0, 0.4, 0.6, 0.7],
          ],
          dtype=np.float32,
      )
      with pytest.raises(
          ValueError,
          match='N dimension of "boxes" \(3\) should not be greater '
          'than the B dimension of "x" \(1\)',
      ):
  
          @mb.program(
              input_specs=[], opset_version=backend.opset_version
          )
          def prog():
              return mb.crop_resize(x=x, boxes=three_boxes)
  
      one_box = np.array([1, 1, 2, 2], dtype=np.float32).reshape(1, 4)
      indices_out_of_bound = np.array([10], dtype=np.int32)
      with pytest.raises(
          ValueError,
          match='input "box_indices" should not have values >= B '
          "dimension of x \(1\), but got \[10\]",
      ):
  
          @mb.program(
              input_specs=[], opset_version=backend.opset_version
          )
          def prog():
              return mb.crop_resize(
                  x=x, boxes=one_box, box_indices=indices_out_of_bound
              )
  
      indices_two_dim = np.array([[0]], dtype=np.int32)
      with pytest.raises(
          ValueError,
          match='input "box_indices" must has shape \[1\], but got \(1, 1\)',
      ):
  
          @mb.program(
              input_specs=[], opset_version=backend.opset_version
          )
          def prog():
              return mb.crop_resize(
                  x=x, boxes=one_box, box_indices=indices_two_dim
              )
  
      x_rank5 = np.arange(1, 17, dtype=np.float32).reshape(
          1, 1, 4, 4, 1
      )
      with pytest.raises(
          ValueError,
          match='input to the "crop_resize" op must be of rank 4, but got 5',
      ):
  
          @mb.program(
              input_specs=[], opset_version=backend.opset_version
          )
          def prog():
              return mb.crop_resize(x=x_rank5, boxes=one_box)
  
imports: import itertools
  import numpy
  import pytest
  from coremltools.converters.mil.mil import Builder
  from coremltools.converters.mil.mil import types
  from coremltools.converters.mil.mil.ops.tests.iOS15.test_image_resizing import TestResample
  from coremltools.converters.mil.mil.ops.tests.iOS17 import backends
  from coremltools.converters.mil.mil.ops.tests.testing_utils import UNK_SYM, run_compare_builder
  from coremltools.converters.mil.testing_reqs import compute_units
label_desc: Use image node_id 3 for calling the TestCropResize obj's underlying member method code with example usage: obj.test_builder_eval_ios17_invalid(backend) and returns: mb, mb, mb, mb