code: def core_test_convolution_double_backward(
      inshape,
      kernel,
      outmaps,
      pad,
      stride,
      dilation,
      group,
      channel_last,
      with_bias,
      base_axis,
      seed,
      ctx,
      func_name,
      non_accum_check=True,
      atol_f=1e-4,
      atol_b=1e-3,
      atol_accum=8e-2,
      dstep=1e-3,
  ):
      from nbla_test_utils import (
          backward_function_tester,
          grad_function_forward_function_output,
      )
      from nnabla.backward_function.convolution import (
          ConvolutionDataGrad,
          ConvolutionFilterGrad,
      )
  
      if func_name == "ConvolutionCuda":
          pytest.skip(
              "CUDA Convolution N-D is only supported in CUDNN extension"
          )
      if channel_last and not func_name.endswith("Cudnn"):
          pytest.skip(
              "channel_last=True is only supported in CUDNN backend so far."
          )
      if (
          channel_last
          and func_name.endswith("Cudnn")
          and (np.any(np.asarray(dilation) > 1) or group > 1)
      ):
          import nnabla_ext.cuda as nc
  
          major, minor, revision = map(
              int, nc.__cudnn_version__.split(".")
          )
          version = major * 1000 + minor * 100
          if version < 7200:
              pytest.skip(
                  "channel_last dilated convolution not work in CUDNN {}.".format(
                      version
                  )
              )
  
      # base_axis = len(inshape) - len(kernel) - 1
      inmaps = inshape[base_axis]
      if channel_last:
          t = refs.ChannelLastToFirstTranspose(
              len(inshape), len(kernel)
          )
          inshape = tuple(inshape[i] for i in t.inv_axes)
      rng = np.random.RandomState(seed)
      i = np.clip(rng.randn(*inshape).astype(np.float32), -0.8, 0.8)
      kshape = (outmaps,) + (inmaps // group,) + kernel
      if channel_last:
          t = refs.ChannelLastToFirstTranspose(len(kshape), len(kernel))
          kshape = tuple(kshape[i] for i in t.inv_axes)
      k = np.clip(rng.randn(*kshape).astype(np.float32), -0.8, 0.8)
      b = None
      if with_bias:
          b = np.clip(rng.randn(outmaps).astype(np.float32), -0.8, 0.8)
      inputs = [i, k, b]
      atol_half = 1.0 if inmaps > 64 else 1e-1
      func_args = [
          base_axis,
          pad,
          stride,
          dilation,
          group,
          channel_last,
      ]
      # Convolution
      backward_function_tester(
          rng,
          F.convolution,
          inputs,
          func_args=func_args,
          atol_f=atol_f,
          atol_accum=atol_accum,
          dstep=dstep,
          ctx=ctx,
      )
      # DataGrad
      df, y = grad_function_forward_function_output(
          ConvolutionDataGrad, F.convolution, ctx, inputs, *func_args
      )
      df.xshape = i.shape
      ginputs = [rng.randn(*y.shape), k]
      backward_function_tester(
          rng,
          df,
          ginputs,
          func_args=[],
          atol_f=atol_f,
          atol_b=atol_b,
          atol_accum=atol_accum,
          dstep=dstep,
          ctx=ctx,
          non_accum_check=non_accum_check,
      )
  
      # FilterGrad
      df, y = grad_function_forward_function_output(
          ConvolutionFilterGrad, F.convolution, ctx, inputs, *func_args
      )
      df.wshape = k.shape
      ginputs = [rng.randn(*y.shape), i]
      backward_function_tester(
          rng,
          df,
          ginputs,
          func_args=[],
          atol_f=atol_f,
          atol_b=atol_b,
          atol_accum=atol_accum,
          dstep=dstep,
          ctx=ctx,
          non_accum_check=non_accum_check,
      )
  
file_path: nnabla/python/test/function/test_convolution.py
imports: from __future__ import division
  import pytest
  import numpy
  import nnabla.functions
  import refs
  from nbla_test_utils import list_context
label_desc: Use image node_id 6 for calling a global function with example usage: core_test_convolution_double_backward(inshape, kernel, outmaps, pad, stride, dilation, group, channel_last, with_bias, base_axis, seed, ctx, func_name, non_accum_check, atol_f, atol_b, atol_accum, dstep) without return types