tfp.experimental.distributions.marginal_fns.ps.tensorshape_util.num_elements

Returns the total number of elements, or None for incomplete shapes.

For more details, see help(tf.TensorShape.num_elements).

x object representing a shape; convertible to tf.TensorShape.

num_elements int representing the total number of elements implied by shape x.