docstr: 测试反向传播的梯度
docstr_tok: ["\u6d4b\u8bd5\u53cd\u5411\u4f20\u64ad\u7684\u68af\u5ea6"]
code: def test_gradient(self):
      """
      测试反向传播的梯度
      """
  
      x = torch.tensor([1.0, 2.0, 3.0, 4.0, 5.0], requires_grad=True)
      y = torch2jittor(x)
      z = 3 * (y**2)
      grad = jittor.grad(z, y)
      assert grad.tolist() == [6.0, 12.0, 18.0, 24.0, 30.0]
  
imports: import pytest
  from fastNLP.envs.imports import _NEED_IMPORT_JITTOR, _NEED_IMPORT_PADDLE, _NEED_IMPORT_TORCH
  from fastNLP.modules.mix_modules.utils import paddle2torch, torch2paddle, jittor2torch, torch2jittor
label_desc: Use image node_id 2 for calling the TestTorch2Jittor obj's underlying member method code with example usage: obj.test_gradient() without return types