code: def test_slice_double_backward(
      seed, inshape, start, stop, step, ctx, fname
  ):
      from nbla_test_utils import (
          backward_function_tester,
          grad_function_forward_function_output,
      )
      from nnabla.backward_function.slice import SliceDataGrad
  
      rng = np.random.RandomState(seed)
      x = rng.randn(*inshape).astype(np.float32)
      func_args = [start, stop, step]
      # 2nd-order
      backward_function_tester(
          rng, F.slice, [x], ctx=ctx, func_args=func_args
      )
      # 3rd-order
      df, y = grad_function_forward_function_output(
          SliceDataGrad, F.slice, ctx, [x], *func_args
      )
      df.xshape = x.shape
      ginputs = [rng.randn(*y.shape)]
      backward_function_tester(
          rng, df, ginputs, func_args=[], ctx=ctx, non_accum_check=True
      )
  
file_path: nnabla/python/test/function/test_slice.py
imports: import pytest
  import numpy
  import nnabla
  import nnabla.functions
  from nbla_test_utils import list_context, function_tester
  from nnabla.testing import assert_allclose
label_desc: Use image node_id 4 for calling a global function with example usage: test_slice_double_backward(seed, inshape, start, stop, step, ctx, fname) without return types