class_docstr: Base class for parameterized probability distributions.
  
  Distributions in Pyro are stochastic function objects with :meth:`sample` and
  :meth:`log_prob` methods. Distribution are stochastic functions with fixed
  parameters::
  
    d = dist.Bernoulli(param)
    x = d()                                # Draws a random sample.
    p = d.log_prob(x)                      # Evaluates log probability of x.
  
  **Implementing New Distributions**:
  
  Derived classes must implement the methods: :meth:`sample`,
  :meth:`log_prob`.
  
  **Examples**:
  
  Take a look at the `examples <http://pyro.ai/examples>`_ to see how they interact
  with inference algorithms.
class_docstr_tok: ["Base","class","for","parameterized","probability","distributions",".","Distributions","in","Pyro","are","stochastic","function","objects","with",":","meth",":","`","sample","`","and",":","meth",":","`","log_prob","`","methods",".","Distribution","are","stochastic","functions","with","fixed","parameters",":",":","d","=","dist.Bernoulli","(","param",")","x","=","d","(",")","#","Draws","a","random","sample",".","p","=","d.log_prob","(","x",")","#","Evaluates","log","probability","of","x",".","*","*","Implementing","New","Distributions","*","*",":","Derived","classes","must","implement","the","methods",":",":","meth",":","`","sample","`",",",":","meth",":","`","log_prob","`",".","*","*","Examples","*","*",":","Take","a","look","at","the","`","examples","<","http",":","\/\/pyro.ai\/examples",">","`","_","to","see","how","they","interact","with","inference","algorithms","."]
docstr: Evaluates log probability densities for each of a batch of samples.
  
  :param torch.Tensor x: A single value or a batch of values
      batched along axis 0.
  :return: log probability densities as a one-dimensional
      :class:`~torch.Tensor` with same batch size as value and
      params. The shape of the result should be ``self.batch_size``.
  :rtype: torch.Tensor
docstr_tok: ["Evaluates","log","probability","densities","for","each","of","a","batch","of","samples",".",":","param","torch.Tensor","x",":","A","single","value","or","a","batch","of","values","batched","along","axis","0.",":","return",":","log","probability","densities","as","a","one-dimensional",":","class",":","`","~torch.Tensor","`","with","same","batch","size","as","value","and","params",".","The","shape","of","the","result","should","be","``","self.batch_size","``",".",":","rtype",":","torch.Tensor"]
code: def log_prob(self, x, *args, **kwargs):
      """
      Evaluates log probability densities for each of a batch of samples.
  
      :param torch.Tensor x: A single value or a batch of values
          batched along axis 0.
      :return: log probability densities as a one-dimensional
          :class:`~torch.Tensor` with same batch size as value and
          params. The shape of the result should be ``self.batch_size``.
      :rtype: torch.Tensor
      """
      raise NotImplementedError
  
file_path: pyro/pyro/distributions/distribution.py
imports: import functools
  import inspect
  from abc import ABCMeta, abstractmethod
  import torch
  from pyro.distributions.score_parts import ScoreParts
label_desc: Use image node_id 3 for calling the Distribution obj's underlying member method code with example usage: obj.log_prob(x) without return types