pymc.SymbolicRandomVariable.do_constant_folding#
- SymbolicRandomVariable.do_constant_folding(fgraph, node)#
Determine whether or not constant folding should be performed for the given node.
This allows each Op to determine if it wants to be constant folded when all its inputs are constant. This allows it to choose where it puts its memory/speed trade-off. Also, it could make things faster as constants can’t be used for in-place operations (see
*IncSubtensor
).- Parameters:
- node
Apply
The node for which the constant folding determination is made.
- node
- Returns:
- resbool