Fix spurious inputs failure when building Truncated variables #7328
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Reintroduce dummy intermediate variables in implementation of TruncatedRV
Partially reverts 9d4a3d7 and 3888d53
The logprob derivation(s) in the icdf implementation of
Truncated
can duplicate nodes and cause spurious input variables to be marked as missing. We revert back to the old approach of replacing these by dummies so the graph above any inputs is hidden, and variables cannot be accidentally cloned/modified during logprob inference.Related Issue
All variables needed to compute inner-graph must be provided as inputs under strict=True
#7312Checklist
Type of change
📚 Documentation preview 📚: https://pymc--7328.org.readthedocs.build/en/7328/