code: def test_vat_noise(seed, base_axis, shape, eps, ctx, func_name):
      rng = np.random.RandomState(313)
      r = 1.0e-6 + rng.randn(*(shape)).astype(np.float32)
      ref = ref_vat_noise(r, base_axis, eps)
  
      x = nn.Variable(shape, need_grad=True)
      w = nn.Variable(shape, need_grad=True)
      y = F.vat_noise(x, w, base_axis, eps)
      x.d = r
      y.forward()
      y.backward()
      res = y.d
  
      atol_f = 1e-6
      assert_allclose(ref, res, atol=atol_f)
  
      atol_b = 1e-6
      ref = np.ones(shape) * eps
      res = w.d
      assert_allclose(ref, res, atol=atol_b)
  
file_path: nnabla/python/test/function/test_vat_noise.py
imports: import pytest
  import numpy
  import nnabla
  import nnabla.functions
  from nbla_test_utils import list_context
  from nnabla.testing import assert_allclose
label_desc: Use image node_id 2 for calling a global function with example usage: test_vat_noise(seed, base_axis, shape, eps, ctx, func_name) without return types