code: def test_scale(self, device, dtype, batch_size):
      params, image_size = self._make_rand_data(
          batch_size, device, dtype
      )
      cam = CameraModel(image_size, CameraModelType.PINHOLE, params)
      scale = torch.rand(batch_size, device=device, dtype=dtype)
      scaled_cam = cam.scale(scale)
      self.assert_close(cam.fx * scale, scaled_cam.fx)
      self.assert_close(cam.fy * scale, scaled_cam.fy)
      self.assert_close(cam.cx * scale, scaled_cam.cx)
      self.assert_close(cam.cy * scale, scaled_cam.cy)
      self.assert_close(cam.width * scale, scaled_cam.width)
      self.assert_close(cam.height * scale, scaled_cam.height)
  
file_path: kornia/test/sensors/camera/test_camera_model.py
imports: import pytest
  import torch
  from kornia.geometry.vector import Vector3
  from kornia.image import ImageSize
  from kornia.sensors.camera import CameraModel, CameraModelType
  from kornia.testing import BaseTester
label_desc: Use image node_id 11 for calling the TestPinholeCamera obj's underlying member method code with example usage: obj.test_scale(device, dtype, batch_size) without return types