code: def test_roi_align_forward_backward(
      seed,
      inshape,
      boxes,
      output_size,
      spatial_scale,
      sampling_ratio,
      channel_last,
      ctx,
      func_name,
  ):
      from nbla_test_utils import function_tester
  
      if channel_last and not func_name.endswith("Cuda"):
          pytest.skip(
              "channel_last=True is only supported in CUDA backend"
          )
      rng = np.random.RandomState(seed)
      inputs = [
          rng.randn(*inshape).astype(np.float32),
          np.array(boxes, dtype=np.float32),
      ]
      if channel_last:
          inputs[0] = np.transpose(inputs[0], (0, 2, 3, 1))
      func_args = [
          output_size,
          spatial_scale,
          sampling_ratio,
          channel_last,
      ]
      function_tester(
          rng,
          F.roi_align,
          ref_roi_align,
          inputs,
          func_args,
          atol_f=1e-4,
          atol_b=1e-2,
          backward=[True, False],
          ctx=ctx,
          func_name=func_name,
      )
  
imports: import pytest
  import numpy
  import nnabla.functions
  from nbla_test_utils import list_context
label_desc: Use image node_id 2 for calling a global function with example usage: test_roi_align_forward_backward(seed, inshape, boxes, output_size, spatial_scale, sampling_ratio, channel_last, ctx, func_name) without return types