code: def test_scale(self, device, dtype):
      sc = 0.5
      sim = kornia.geometry.transform.Similarity(True, True, True).to(
          device, dtype
      )
      sim.scale.data *= sc
      expected = torch.tensor(
          [[0.5, 0, 0.0], [0, 0.5, 0], [0, 0, 1]],
          device=device,
          dtype=dtype,
      )[None]
      inv_expected = torch.tensor(
          [[2.0, 0, 0.0], [0, 2.0, 0], [0, 0, 1]],
          device=device,
          dtype=dtype,
      )[None]
      assert_close(
          sim.forward_inverse(), inv_expected, atol=1e-4, rtol=1e-4
      )
      assert_close(sim(), expected, atol=1e-4, rtol=1e-4)
  
imports: import sys
  import pytest
  import torch
  import kornia
  import kornia.testing
  from kornia.geometry import transform_points
  from kornia.geometry.conversions import denormalize_homography
  from kornia.geometry.transform import ImageRegistrator
  from kornia.testing import assert_close
  from kornia.utils._compat import torch_version
label_desc: Use image node_id 3 for calling the TestSimilarity obj's underlying member method code with example usage: obj.test_scale(device, dtype) without return types