Commit eb19da6
committed
Fix BC break: ShapeEnv.size_hint renamed to guarding_hint_or_throw
PyTorch renamed ShapeEnv.size_hint() to guarding_hint_or_throw().
Use hasattr to support both old and new PyTorch versions.
This diff was authored with Claude.1 parent 4035db9 commit eb19da6
1 file changed
Lines changed: 4 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
29 | 32 | | |
30 | 33 | | |
31 | 34 | | |
| |||
0 commit comments