Skip to content

Fix Minimize Ops type strictness#2279

Open
ricardoV94 wants to merge 2 commits into
pymc-devs:mainfrom
ricardoV94:less_strict_minimize
Open

Fix Minimize Ops type strictness#2279
ricardoV94 wants to merge 2 commits into
pymc-devs:mainfrom
ricardoV94:less_strict_minimize

Conversation

@ricardoV94

@ricardoV94 ricardoV94 commented Jul 8, 2026

Copy link
Copy Markdown
Member

Fixes two issues we found on the pymc-extras CI.

  • Allow more specialized input types in MinimizeOp

This is actually present in jaxified_graph helper in PyMC, because Mode(...).optimizer did not propagate the _compile_mode to the fgraph so the inner graph rewriters can see it. Moved it one level down which covers both paths.

  • Move _compile_mode responsibility to mode.optimizer

In Composite, only try to rebuild graph if types are not
"filter"-compatible
@ricardoV94 ricardoV94 force-pushed the less_strict_minimize branch from 5263c14 to d744ddd Compare July 8, 2026 20:52
@ricardoV94 ricardoV94 requested a review from jessegrabowski July 9, 2026 11:32
@ricardoV94 ricardoV94 added bug Something isn't working Op implementation labels Jul 9, 2026
@ricardoV94 ricardoV94 force-pushed the less_strict_minimize branch from d744ddd to edfb52e Compare July 9, 2026 11:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working Op implementation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant