class_docstr: MultiCategorical distribution for MultiDiscrete action spaces.
class_docstr_tok: ["MultiCategorical","distribution","for","MultiDiscrete","action","spaces","."]
docstr: Creates this Distribution from logits (and additional arguments).
  
  If you wish to create this distribution from logits only, please refer to
  `Distribution.get_partial_dist_cls()`.
  
  Args:
      logits: The tensor containing logits to be separated by logit_lens.
          child_distribution_cls_struct: A struct of Distribution classes that can
          be instantiated from the given logits.
      input_lens: A list of integers that indicate the length of the logits
          vectors to be passed into each child distribution.
      temperatures: A list of floats representing the temperature to use for
          each Categorical distribution. If not provided, 1.0 is used for all.
      **kwargs: Forward compatibility kwargs.
docstr_tok: ["Creates","this","Distribution","from","logits","(","and","additional","arguments",")",".","If","you","wish","to","create","this","distribution","from","logits","only",",","please","refer","to","`","Distribution.get_partial_dist_cls","(",")","`",".","Args",":","logits",":","The","tensor","containing","logits","to","be","separated","by","logit_lens",".","child_distribution_cls_struct",":","A","struct","of","Distribution","classes","that","can","be","instantiated","from","the","given","logits",".","input_lens",":","A","list","of","integers","that","indicate","the","length","of","the","logits","vectors","to","be","passed","into","each","child","distribution",".","temperatures",":","A","list","of","floats","representing","the","temperature","to","use","for","each","Categorical","distribution",".","If","not","provided",",","1.0","is","used","for","all",".","*","*","kwargs",":","Forward","compatibility","kwargs","."]
code: def from_logits(
      cls,
      logits: torch.Tensor,
      input_lens: List[int],
      temperatures: List[float] = None,
      **kwargs,
  ) -> "TorchMultiCategorical":
      """Creates this Distribution from logits (and additional arguments).
  
      If you wish to create this distribution from logits only, please refer to
      `Distribution.get_partial_dist_cls()`.
  
      Args:
          logits: The tensor containing logits to be separated by logit_lens.
              child_distribution_cls_struct: A struct of Distribution classes that can
              be instantiated from the given logits.
          input_lens: A list of integers that indicate the length of the logits
              vectors to be passed into each child distribution.
          temperatures: A list of floats representing the temperature to use for
              each Categorical distribution. If not provided, 1.0 is used for all.
          **kwargs: Forward compatibility kwargs.
      """
      if not temperatures:
          # If temperatures are not provided, use 1.0 for all actions.
          temperatures = [1.0] * len(input_lens)
  
      assert (
          sum(input_lens) == logits.shape[-1]
      ), "input_lens must sum to logits.shape[-1]"
      assert len(input_lens) == len(
          temperatures
      ), "input_lens and temperatures must be same length"
  
      categoricals = [
          TorchCategorical(logits=logits)
          for logits in torch.split(logits, input_lens, dim=-1)
      ]
  
      return TorchMultiCategorical(categoricals=categoricals)
  
imports: import gymnasium
  import numpy
  from typing import Optional, List, Mapping, Iterable, Dict
  import tree
  import abc
  from ray.rllib.models.distributions import Distribution
  from ray.rllib.utils.annotations import override, DeveloperAPI
  from ray.rllib.utils.framework import try_import_torch
  from ray.rllib.utils.typing import TensorType, Union, Tuple
label_desc: Use image node_id 8 for calling the TorchMultiCategorical obj's underlying member method code with example usage: obj.from_logits(cls, logits, input_lens, temperatures) and returns: TorchMultiCategorical