mirror of
https://github.com/zebrajr/pytorch.git
synced 2025-12-07 12:21:27 +01:00
Changes: Enable inductor backend for dynamo on Windows. Pull Request resolved: https://github.com/pytorch/pytorch/pull/133921 Approved by: https://github.com/jgong5, https://github.com/jansel
13 lines
291 B
Python
13 lines
291 B
Python
# mypy: ignore-errors
|
|
|
|
|
|
from torch._dynamo import register_backend
|
|
|
|
|
|
@register_backend
|
|
def inductor(*args, **kwargs):
|
|
# do import here to avoid loading inductor into memory when it is not used
|
|
from torch._inductor.compile_fx import compile_fx
|
|
|
|
return compile_fx(*args, **kwargs)
|