Skip to content

Commit

Permalink
improved usability of TVM EP
Browse files Browse the repository at this point in the history
  • Loading branch information
KJlaccHoeUM9l committed Jan 11, 2022
1 parent ce103ac commit 816658d
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions onnxruntime/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,15 @@
except ImportError:
pass

try:
# Working between the C++ and Python parts in TVM EP is done using the PackedFunc and Registry classes.
# In order to use a Python function in C++ code, it must be registered in the global table of functions.
# Registration is carried out through the JIT interface, so it is necessary to call
# special functions for registration. To do this, we need to make the following import.
import onnxruntime.providers.stvm
except ImportError:
pass

from onnxruntime.capi.onnxruntime_validation import package_name, version, cuda_version
if version:
__version__ = version
Expand Down

0 comments on commit 816658d

Please sign in to comment.