- class pymc.SymbolicRandomVariable(*args, ndim_supp, **kwargs)[source]#
Symbolic Random Variable
This is a subclasse of OpFromGraph which is used to encapsulate the symbolic random graph of complex distributions which are built on top of pure `RandomVariable`s.
These graphs may vary structurally based on the inputs (e.g., their dimensionality), and usually require that random inputs have specific shapes for correct outputs (e.g., avoiding broadcasting of random inputs). Due to this, most distributions that return SymbolicRandomVariable create their these graphs at runtime via the classmethod cls.rv_op, taking care to clone and resize random inputs, if needed.
SymbolicRandomVariable.L_op(inputs, outputs, ...)
Construct a graph for the L-operator.
Construct a graph for the R-operator.
Add tag.trace to a node or variable.
Clone the Op and its inner-graph.
Return connection pattern of subfgraph defined by inputs and outputs.
Determine whether or not constant folding should be performed for the given node.
Try to get parameters for the Op when
Op.params_typeis set to a ParamsType.
Construct a graph for the gradient with respect to each input variable.
Construct an Apply node that represent the application of this operation to the given inputs.
Make a Python thunk.
Create a thunk.
SymbolicRandomVariable.perform(node, inputs, ...)
Calculate the function on the inputs and put the variables in the output storage.
Make any special modifications that the Op needs before doing
Set gradient overrides.
Set L_op overrides This will completely remove any previously set L_op/gradient overrides
Set R_op overrides This will completely remove any previously set R_op overrides
Symbolic update expression for input random state variables
intthat specifies which output
dictthat maps output indices to the input indices upon which they operate in-place.
Lazily compile the inner function graph.
Specifies whether the logprob function is derived automatically by introspection of the inner graph.
The inner function's inputs.
The inner function's outputs.
Number of support dimensions as in RandomVariables (0 for scalar, 1 for vector, ...)
dictthat maps output indices to the input indices of which they are a view.