MCPcopy Create free account
hub / github.com/apache/tvm / find_libtvm_runtime

Function find_libtvm_runtime

python/tvm/libinfo.py:59–77  ·  view source on GitHub ↗

Return the path to the ``libtvm_runtime`` shared library. Returns ------- path : str The resolved path to the TVM runtime shared library. Raises ------ RuntimeError If the runtime library cannot be found.

()

Source from the content-addressed store, hash-verified

57
58
59def find_libtvm_runtime() -> str:
60 """Return the path to the ``libtvm_runtime`` shared library.
61
62 Returns
63 -------
64 path : str
65 The resolved path to the TVM runtime shared library.
66
67 Raises
68 ------
69 RuntimeError
70 If the runtime library cannot be found.
71 """
72 candidate = tvm_ffi_libinfo._find_library_by_basename(
73 "tvm", "tvm_runtime", extra_lib_paths=package_lib_paths()
74 )
75 if ret := tvm_ffi_libinfo._resolve_and_validate([candidate], cond=lambda _: True):
76 return ret
77 raise RuntimeError("Cannot find libtvm_runtime")
78
79
80def find_include_path() -> str:

Callers

nothing calls this directly

Calls 1

package_lib_pathsFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…