code: def _upcast_non_float(t: Tensor) -> Tensor:
      # Protects from numerical overflows in multiplications by upcasting to the equivalent higher type
      if t.dtype not in (torch.float32, torch.float64):
          return t.float()
      return t
  
file_path: vision/torchvision/ops/_utils.py
imports: from typing import List, Optional, Tuple, Union
  import torch
  from torch import nn, Tensor
label_desc: Use image node_id 6 for calling a global function with example usage: _upcast_non_float(t) and returns: t, t