class_docstr: Skellam distribution.
  
  The Skellam distribution is parameterized by two rate parameters,
  `rate1` and `rate2`. Its samples are defined as:
  
  ```
  x ~ Poisson(rate1)
  y ~ Poisson(rate2)
  z = x - y
  z ~ Skellam(rate1, rate2)
  ```
  where the samples `x` and `y` are assumed to be independent.
  
  #### Mathematical Details
  
  The probability mass function (pmf) is,
  
  ```none
  pmf(k; l1, l2) = (l1 / l2) ** (k / 2) * I_k(2 * sqrt(l1 * l2)) / Z
  Z = exp(l1 + l2).
  ```
  
  where `rate1 = l1`, `rate2 = l2`,  `Z` is the normalizing constant
  and `I_k` is the modified bessel function of the first kind.
docstr: Initialize a batch of Skellam distributions.
  
  Args:
    rate1: Floating point tensor, the first rate parameter. `rate1` must be
      positive. Must specify exactly one of `rate1` and `log_rate1`
    rate2: Floating point tensor, the second rate parameter. `rate` must be
      positive.  Must specify exactly one of `rate2` and `log_rate2`.
    log_rate1: Floating point tensor, the log of the first rate parameter.
      Must specify exactly one of `rate1` and `log_rate1`.
    log_rate2: Floating point tensor, the log of the second rate parameter.
      Must specify exactly one of `rate2` and `log_rate2`.
    force_probs_to_zero_outside_support: Python `bool`. When `True`,
      `log_prob` returns `-inf` (and `prob` returns `0`) for non-integer
      inputs. When `False`, `log_prob` evaluates the Skellam pmf as a
      continuous function (note that this function is not itself
      a normalized probability log-density).
      Default value: `False`.
    validate_args: Python `bool`. When `True` distribution
      parameters are checked for validity despite possibly degrading runtime
      performance. When `False` invalid inputs may silently render incorrect
      outputs.
      Default value: `False`.
    allow_nan_stats: Python `bool`. When `True`, statistics
      (e.g., mean, mode, variance) use the value "`NaN`" to indicate the
      result is undefined. When `False`, an exception is raised if one or
      more of the statistic's batch members are undefined.
      Default value: `True`.
    name: Python `str` name prefixed to Ops created by this class.
  
  Raises:
    ValueError: if none or both of `rate1`, `log_rate1` are specified.
    ValueError: if none or both of `rate2`, `log_rate2` are specified.
docstr_tok: ["Initialize","a","batch","of","Skellam","distributions",".","Args",":","rate1",":","Floating","point","tensor",",","the","first","rate","parameter",".","`","rate1","`","must","be","positive",".","Must","specify","exactly","one","of","`","rate1","`","and","`","log_rate1","`","rate2",":","Floating","point","tensor",",","the","second","rate","parameter",".","`","rate","`","must","be","positive",".","Must","specify","exactly","one","of","`","rate2","`","and","`","log_rate2","`",".","log_rate1",":","Floating","point","tensor",",","the","log","of","the","first","rate","parameter",".","Must","specify","exactly","one","of","`","rate1","`","and","`","log_rate1","`",".","log_rate2",":","Floating","point","tensor",",","the","log","of","the","second","rate","parameter",".","Must","specify","exactly","one","of","`","rate2","`","and","`","log_rate2","`",".","force_probs_to_zero_outside_support",":","Python","`","bool","`",".","When","`","True","`",",","`","log_prob","`","returns","`","-inf","`","(","and","`","prob","`","returns","`","0","`",")","for","non-integer","inputs",".","When","`","False","`",",","`","log_prob","`","evaluates","the","Skellam","pmf","as","a","continuous","function","(","note","that","this","function","is","not","itself","a","normalized","probability","log-density",")",".","Default","value",":","`","False","`",".","validate_args",":","Python","`","bool","`",".","When","`","True","`","distribution","parameters","are","checked","for","validity","despite","possibly","degrading","runtime","performance",".","When","`","False","`","invalid","inputs","may","silently","render","incorrect","outputs",".","Default","value",":","`","False","`",".","allow_nan_stats",":","Python","`","bool","`",".","When","`","True","`",",","statistics","(","e.g.",",","mean",",","mode",",","variance",")","use","the","value","``","`","NaN","`","``","to","indicate","the","result","is","undefined",".","When","`","False","`",",","an","exception","is","raised","if","one","or","more","of","the","statistic","'s","batch","members","are","undefined",".","Default","value",":","`","True","`",".","name",":","Python","`","str","`","name","prefixed","to","Ops","created","by","this","class",".","Raises",":","ValueError",":","if","none","or","both","of","`","rate1","`",",","`","log_rate1","`","are","specified",".","ValueError",":","if","none","or","both","of","`","rate2","`",",","`","log_rate2","`","are","specified","."]
code: def __init__(
      self,
      rate1=None,
      rate2=None,
      log_rate1=None,
      log_rate2=None,
      force_probs_to_zero_outside_support=False,
      validate_args=False,
      allow_nan_stats=True,
      name="Skellam",
  ):
      """Initialize a batch of Skellam distributions.
  
      Args:
        rate1: Floating point tensor, the first rate parameter. `rate1` must be
          positive. Must specify exactly one of `rate1` and `log_rate1`
        rate2: Floating point tensor, the second rate parameter. `rate` must be
          positive.  Must specify exactly one of `rate2` and `log_rate2`.
        log_rate1: Floating point tensor, the log of the first rate parameter.
          Must specify exactly one of `rate1` and `log_rate1`.
        log_rate2: Floating point tensor, the log of the second rate parameter.
          Must specify exactly one of `rate2` and `log_rate2`.
        force_probs_to_zero_outside_support: Python `bool`. When `True`,
          `log_prob` returns `-inf` (and `prob` returns `0`) for non-integer
          inputs. When `False`, `log_prob` evaluates the Skellam pmf as a
          continuous function (note that this function is not itself
          a normalized probability log-density).
          Default value: `False`.
        validate_args: Python `bool`. When `True` distribution
          parameters are checked for validity despite possibly degrading runtime
          performance. When `False` invalid inputs may silently render incorrect
          outputs.
          Default value: `False`.
        allow_nan_stats: Python `bool`. When `True`, statistics
          (e.g., mean, mode, variance) use the value "`NaN`" to indicate the
          result is undefined. When `False`, an exception is raised if one or
          more of the statistic's batch members are undefined.
          Default value: `True`.
        name: Python `str` name prefixed to Ops created by this class.
  
      Raises:
        ValueError: if none or both of `rate1`, `log_rate1` are specified.
        ValueError: if none or both of `rate2`, `log_rate2` are specified.
      """
      parameters = dict(locals())
      if (rate1 is None) == (log_rate1 is None):
          raise ValueError(
              "Must specify exactly one of `rate1` and `log_rate1`."
          )
      if (rate2 is None) == (log_rate2 is None):
          raise ValueError(
              "Must specify exactly one of `rate2` and `log_rate2`."
          )
      with tf.name_scope(name) as name:
          dtype = dtype_util.common_dtype(
              [rate1, rate2, log_rate1, log_rate2],
              dtype_hint=tf.float32,
          )
          self._rate1 = tensor_util.convert_nonref_to_tensor(
              rate1, name="rate1", dtype=dtype
          )
          self._log_rate1 = tensor_util.convert_nonref_to_tensor(
              log_rate1, name="log_rate1", dtype=dtype
          )
  
          self._rate2 = tensor_util.convert_nonref_to_tensor(
              rate2, name="rate2", dtype=dtype
          )
          self._log_rate2 = tensor_util.convert_nonref_to_tensor(
              log_rate2, name="log_rate2", dtype=dtype
          )
  
          self._force_probs_to_zero_outside_support = (
              force_probs_to_zero_outside_support
          )
          super(Skellam, self).__init__(
              dtype=dtype,
              reparameterization_type=reparameterization.NOT_REPARAMETERIZED,
              validate_args=validate_args,
              allow_nan_stats=allow_nan_stats,
              parameters=parameters,
              name=name,
          )
  
imports: import numpy
  import tensorflow.compat.v2
  from tensorflow_probability.python.bijectors import softplus
  from tensorflow_probability.python.distributions import distribution
  from tensorflow_probability.python.distributions import poisson
  from tensorflow_probability.python.internal import assert_util
  from tensorflow_probability.python.internal import distribution_util
  from tensorflow_probability.python.internal import dtype_util
  from tensorflow_probability.python.internal import parameter_properties
  from tensorflow_probability.python.internal import prefer_static
  from tensorflow_probability.python.internal import reparameterization
  from tensorflow_probability.python.internal import samplers
  from tensorflow_probability.python.internal import tensor_util
  from tensorflow_probability.python.math import bessel
label_desc: Use image node_id 1 to create a new Skellam object from inherited base classes: distribution, distribution with example: obj = Skellam(rate1, rate2, log_rate1, log_rate2, force_probs_to_zero_outside_support, validate_args, allow_nan_stats, name)