class_docstr: Create a one-hot categorical distribution object.
  
  Parameters
  ----------
  num_events : Int
      Number of events.
  prob : Tensor
      Probabilities of each event.
  logit : Tensor
      The log-odds of each event
class_docstr_tok: ["Create","a","one-hot","categorical","distribution","object",".","Parameters","--","--","--","--","--","num_events",":","Int","Number","of","events",".","prob",":","Tensor","Probabilities","of","each","event",".","logit",":","Tensor","The","log-odds","of","each","event"]
code: def __init__(
      self, num_events, prob=None, logit=None, validate_args=None
  ):
      if num_events > 0:
          num_events = int(num_events)
          self.num_events = num_events
      else:
          raise ValueError(
              "`num_events` should be greater than zero. "
              + "Received num_events={}".format(num_events)
          )
      self._categorical = Categorical(
          num_events, prob, logit, validate_args
      )
      super(OneHotCategorical, self).__init__(
          event_dim=1, validate_args=validate_args
      )
  
file_path: mxnet/python/mxnet/gluon/probability/distributions/one_hot_categorical.py
imports: from .distribution import Distribution
  from .categorical import Categorical
  from .utils import cached_property
  from .constraint import Simplex, Real
  from ....None import npx
label_desc: Use image node_id 1 to create a new OneHotCategorical object from inherited base classes: Distribution with example: obj = OneHotCategorical(num_events, prob, logit, validate_args)