code: def test_bilinear():
      image = tf.constant(
          [
              [0, 0, 0, 0, 0],
              [0, 1, 1, 1, 0],
              [0, 1, 0, 1, 0],
              [0, 1, 1, 1, 0],
              [0, 0, 0, 0, 0],
          ],
          tf.float32,
      )
      # The following result matches:
      # >>> scipy.ndimage.rotate(image, 45, order=1, reshape=False)
      # which uses spline interpolation of order 1, equivalent to bilinear
      # interpolation.
      transformed = transform_ops.rotate(
          image, np.pi / 4.0, interpolation="BILINEAR"
      )
      np.testing.assert_allclose(
          transformed.numpy(),
          [
              [0.000, 0.000, 0.343, 0.000, 0.000],
              [0.000, 0.586, 0.914, 0.586, 0.000],
              [0.343, 0.914, 0.000, 0.914, 0.343],
              [0.000, 0.586, 0.914, 0.586, 0.000],
              [0.000, 0.000, 0.343, 0.000, 0.000],
          ],
          atol=0.001,
      )
      transformed = transform_ops.rotate(
          image, np.pi / 4.0, interpolation="NEAREST"
      )
      np.testing.assert_allclose(
          transformed.numpy(),
          [
              [0, 0, 1, 0, 0],
              [0, 1, 1, 1, 0],
              [1, 1, 0, 1, 1],
              [0, 1, 1, 1, 0],
              [0, 0, 1, 0, 0],
          ],
      )
  
imports: import pytest
  import numpy
  import tensorflow
  from skimage import transform
  from tensorflow_addons.image import transform_ops
  from tensorflow_addons.utils import test_utils
label_desc: Use image node_id 17 for calling a global function with example usage: test_bilinear() without return types