tf.contrib.distributions.Distribution.get_batch_shape()

tf.contrib.distributions.Distribution.get_batch_shape() Shape of a single sample from a single event index as a TensorShape. Same meaning as batch_shape. May be only partially defined. Returns: batch_shape: TensorShape, possibly unknown.

tf.contrib.distributions.Distribution.event_shape()

tf.contrib.distributions.Distribution.event_shape(name='event_shape') Shape of a single sample from a single batch as a 1-D int32 Tensor. Args: name: name to give to the op Returns: event_shape: Tensor.

tf.contrib.distributions.Distribution.entropy()

tf.contrib.distributions.Distribution.entropy(name='entropy') Shanon entropy in nats.

tf.contrib.distributions.Distribution.dtype

tf.contrib.distributions.Distribution.dtype The DType of Tensors handled by this Distribution.

tf.contrib.distributions.Distribution.cdf()

tf.contrib.distributions.Distribution.cdf(value, name='cdf') Cumulative distribution function. Given random variable X, the cumulative distribution function cdf is: cdf(x) := P[X <= x] Args: value: float or double Tensor. name: The name to give this op. Returns: cdf: a Tensor of shape sample_shape(x) + self.batch_shape with values of type self.dtype.

tf.contrib.distributions.Distribution.batch_shape()

tf.contrib.distributions.Distribution.batch_shape(name='batch_shape') Shape of a single sample from a single event index as a 1-D Tensor. The product of the dimensions of the batch_shape is the number of independent distributions of this kind the instance represents. Args: name: name to give to the op Returns: batch_shape: Tensor.

tf.contrib.distributions.Distribution.allow_nan_stats

tf.contrib.distributions.Distribution.allow_nan_stats Python boolean describing behavior when a stat is undefined. Stats return +/- infinity when it makes sense. E.g., the variance of a Cauchy distribution is infinity. However, sometimes the statistic is undefined, e.g., if a distribution's pdf does not achieve a maximum within the support of the distribution, the mode is undefined. If the mean is undefined, then by definition the variance is undefined. E.g. the mean for Student's T for df = 1

tf.contrib.distributions.Distribution

class tf.contrib.distributions.Distribution A generic probability distribution base class. Distribution is a base class for constructing and organizing properties (e.g., mean, variance) of random variables (e.g, Bernoulli, Gaussian).

tf.contrib.distributions.DirichletMultinomial.__init__()

tf.contrib.distributions.DirichletMultinomial.__init__(n, alpha, validate_args=False, allow_nan_stats=True, name='DirichletMultinomial') Initialize a batch of DirichletMultinomial distributions. Args: n: Non-negative floating point tensor, whose dtype is the same as alpha. The shape is broadcastable to [N1,..., Nm] with m >= 0. Defines this as a batch of N1 x ... x Nm different Dirichlet multinomial distributions. Its components should be equal to integer values. alpha: Positive floating

tf.contrib.distributions.DirichletMultinomial.variance()

tf.contrib.distributions.DirichletMultinomial.variance(name='variance') Variance. Additional documentation from DirichletMultinomial: The variance for each batch member is defined as the following: Var(X_j) = n * alpha_j / alpha_0 * (1 - alpha_j / alpha_0) * (n + alpha_0) / (1 + alpha_0) where alpha_0 = sum_j alpha_j. The covariance between elements in a batch is defined as: Cov(X_i, X_j) = -n * alpha_i * alpha_j / alpha_0 ** 2 * (n + alpha_0) / (1 + alpha_0)