code: def trilu(
      x: torch.Tensor,
      /,
      *,
      k: int = 0,
      upper: bool = True,
      out: Optional[torch.Tensor] = None,
  ) -> torch.Tensor:
      if upper:
          return torch.triu(x, diagonal=k, out=out)
      return torch.tril(x, diagonal=k, out=out)
  
file_path: ivy/ivy/functional/backends/torch/experimental/creation.py
imports: from typing import Optional, Tuple, Union
  import math
  import torch
  import ivy
  from ivy.func_wrapper import with_unsupported_dtypes, with_unsupported_device_and_dtypes
  from ..None import backend_version
label_desc: Use image node_id 9 for calling a global function with example usage: trilu() and returns: torch, torch