Unverified Commit a839642c authored by Nicolas Hug's avatar Nicolas Hug Committed by GitHub
Browse files

Load _C ops before registering meta implementations (#8470)

parent bcf6cda1
...@@ -3,9 +3,11 @@ import warnings ...@@ -3,9 +3,11 @@ import warnings
from modulefinder import Module from modulefinder import Module
import torch import torch
from torchvision import _meta_registrations, datasets, io, models, ops, transforms, utils
from .extension import _HAS_OPS # Don't re-order these, we need to load the _C extension (done when importing
# .extensions) before entering _meta_registrations.
from .extension import _HAS_OPS # usort:skip
from torchvision import _meta_registrations, datasets, io, models, ops, transforms, utils # usort:skip
try: try:
from .version import __version__ # noqa: F401 from .version import __version__ # noqa: F401
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment