code: def test_typeconvert_upcast(src_dtype, dst_dtype):
      if src_dtype == "float8e4nv" and torch.cuda.get_device_capability(
          0
      ) < (9, 0):
          pytest.skip(
              "float8e4nv upcast tests only supported on compute capability 9.0+"
          )
  
      # dtype : (exponent_bits, mantissa_bits, exponent_bias, max_repr)
      stuff = {
          "float8e4b15": (4, 3, 15, 0x7E),
          "float8e4nv": (4, 3, 7, 0x7E),
          "float8e5": (5, 2, 15, 0x7B),
          "float16": (5, 10, 15, 0x7BFF),
          "bfloat16": (8, 7, 127, 0x7F7F),
      }[src_dtype]
  
      upcast_test(
          getattr(tl, src_dtype), getattr(tl, dst_dtype), *stuff
      )
  
file_path: triton/python/test/unit/language/test_conversions.py
imports: import numpy
  import torch
  import pytest
  import triton
  import triton.language
label_desc: Use image node_id 13 for calling a global function with example usage: test_typeconvert_upcast(src_dtype, dst_dtype) without return types