code: def test_gradcheck(self, device):
      batch_size, channels, height, width = 1, 1, 7, 7
      patches = torch.rand(
          batch_size, channels, height, width, device=device
      )
      patches = utils.tensor_to_gradcheck_var(patches)  # to var
      assert gradcheck(
          ScaleSpaceDetector(2).to(device),
          patches,
          raise_exception=True,
          nondet_tol=1e-4,
          fast_mode=True,
      )
  
file_path: kornia/test/feature/test_scale_space_detector.py
imports: import torch
  from torch.autograd import gradcheck
  import kornia
  import kornia.testing
  from kornia.feature.scale_space_detector import ScaleSpaceDetector
  from kornia.testing import assert_close
label_desc: Use image node_id 5 for calling the TestScaleSpaceDetector obj's underlying member method code with example usage: obj.test_gradcheck(device) without return types