code: def multinomial(
      input, num_samples, replacement=False, *, generator=None, out=None
  ):
      seed = generator.initial_seed() if generator is not None else None
      return ivy.multinomial(
          num_samples
          + 1,  # doesn't matter because `probs` is provided, but should be
          # greater than the number of samples
          num_samples,
          probs=input,
          replace=replacement,
          seed=seed,
          out=out,
      )
  
file_path: ivy/ivy/functional/frontends/torch/random_sampling.py
imports: import ivy
  from ivy.func_wrapper import with_supported_dtypes
  from ivy.functional.frontends.torch.func_wrapper import to_ivy_arrays_and_back
label_desc: Use image node_id 3 for calling a global function with example usage: multinomial(input, num_samples, replacement) and returns: ivy