mirror of
https://github.com/saymrwulf/pytorch.git
synced 2026-05-15 21:00:47 +00:00
Fixes #105157 Bug source: `from __future__ import annotations` converts type annotation to strings to make forwards references easier. However, existing custom ops do not consider strings to be valid types. Fix: We check if the argument and return type annotation is string type. If so, we try to use `eval` to convert it to a type. Pull Request resolved: https://github.com/pytorch/pytorch/pull/128809 Approved by: https://github.com/zou3519 |
||
|---|---|---|
| .. | ||
| CMakeLists.txt | ||
| model.py | ||
| my_custom_ops.py | ||
| my_custom_ops2.py | ||
| op.cpp | ||
| op.h | ||
| pointwise.py | ||
| test_custom_ops.cpp | ||
| test_custom_ops.py | ||
| test_infer_schema_annotation.py | ||