-
Notifications
You must be signed in to change notification settings - Fork 364
Cross compile guard #3486
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Cross compile guard #3486
Conversation
|
||
def check_cross_compile_trt_win_lib(): | ||
if sys.platform.startswith("linux"): | ||
LINUX_PATHS = ["/usr/local/cuda-12.8/lib64", "/usr/lib", "/usr/lib64"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I dont think this works generically, there needs to be a way to see of the library has been loaded aready
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I took this code snippet from
py/torch_tensorrt/__init__.py
where we check the tensorrt libs while importing torch_tensorrt. Since this is included in features I am putting this code snippet in _utils, where it checks if the _win*.so is present or not to be loaded via ctypes.CDLL ( can use ctypes.cdll.LoadLibrary() too). What is your thoughts on how to do this
9a4f681
to
ed8d559
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are some changes that do not conform to Python style guidelines:
The PR addresses the following-