code: def _to_dtype_tensor_dispatch(
      inpt: torch.Tensor, dtype: torch.dtype, scale: bool = False
  ) -> torch.Tensor:
      # We don't need to unwrap and rewrap here, since TVTensor.to() preserves the type
      return inpt.to(dtype)
  
imports: import math
  from typing import List, Optional
  import PIL.Image
  import torch
  from torch.nn.functional import conv2d, pad
  from torchvision import tv_tensors
  from torchvision.transforms._functional_tensor import _max_value
  from torchvision.transforms.functional import pil_to_tensor, to_pil_image
  from torchvision.utils import _log_api_usage_once
  from ._utils import _get_kernel, _register_kernel_internal
label_desc: Use image node_id 15 for calling a global function with example usage: _to_dtype_tensor_dispatch(inpt, dtype, scale) and returns: inpt