code: def dirichlet(
      alpha: Union[torch.tensor, float, Sequence[float]],
      /,
      *,
      size: Optional[Union[ivy.NativeShape, Sequence[int]]] = None,
      out: Optional[torch.Tensor] = None,
      seed: Optional[int] = None,
      dtype: Optional[torch.dtype] = None,
  ) -> torch.Tensor:
      size = size if size is not None else len(alpha)
      if seed is not None:
          torch.manual_seed(seed)
      return torch.tensor(
          torch.distributions.dirichlet.Dirichlet(alpha).rsample(
              sample_shape=size
          ),
          dtype=dtype,
      )
  
file_path: ivy/ivy/functional/backends/torch/experimental/random.py
imports: from typing import Optional, Union, Sequence
  import torch
  import ivy
  from ivy.func_wrapper import with_unsupported_dtypes
  from ..None import backend_version
  from ivy.functional.ivy.random import _check_bounds_and_get_shape, _check_shapes_broadcastable
label_desc: Use image node_id 1 for calling a global function with example usage: dirichlet() and returns: torch