pymc-devs / pymc-devs/pytensor
Static shapes
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 644
- Forks
- 208
- Avg merge
- 2d 14h
- Merged PRs (30d)
- 16
Description
Description
From this discussion on pymc discourse, "static shapes are quite recent and we are still updating Ops to reflect them when possible." -@ricardoV94
Is help still needed with ensuring static shape output from Ops where possible? If so - here's a quick (obviously incomplete!) start on listing out ops to work on.
No static shape output (todo):
-
Eye - conv ops (#150)
No static shape output (and perhaps to remain as such):
Subtensor(indexation)
Could fail earlier:
Dot: outputs correct static shape if the input shapes align, but outputs incorrect static shape if input shapes are wrong. Error at eval timeSpecifyShape: similar to Dot.ptt.specify_shape(np.ones((2,3)), shape=(3,3)).type # tensortype shape (2,3)
Recently addressed:
-
Join#164 -
MaxAndArgmax#206
Hopefully this is the right place to start the discussion. If help is wanted, I would appreciate some guidance on how to go about this in a more principled way -- where/how to look, what a fix might look like, etc -- and of course any other suggestion on Ops that don't yet support static shape output.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the linked PyMC Discourse discussion and the listed Ops: Eye, conv ops, Subtensor, Dot, and SpecifyShape; compare them with the recently addressed Join and MaxAndArgmax issues (#150, #164, and #206). The issue needs a decision on which gaps are actionable and what correct static-shape behavior means before implementation can be considered done.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100