From 9267b9b4e2789dc4fc8e4631937dbd87569ae5c3 Mon Sep 17 00:00:00 2001 From: Seunghoon Lee Date: Tue, 21 May 2024 10:58:42 +0900 Subject: [PATCH] zluda minor fixes --- cli/zluda-python.py | 7 +++++-- modules/zluda.py | 1 + 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/cli/zluda-python.py b/cli/zluda-python.py index 958f2121c..31ee96362 100644 --- a/cli/zluda-python.py +++ b/cli/zluda-python.py @@ -26,8 +26,11 @@ class Interpreter: if __name__ == '__main__': sys.path.append(os.getcwd()) - from modules.zluda_installer import find, load - load(find()) + from modules import zluda_installer + zluda_path = zluda_installer.get_path() + zluda_installer.install(zluda_path) + zluda_installer.make_copy(zluda_path) + zluda_installer.load(zluda_path) import torch interpreter = Interpreter({ diff --git a/modules/zluda.py b/modules/zluda.py index b181f60a4..55f83ff30 100644 --- a/modules/zluda.py +++ b/modules/zluda.py @@ -20,6 +20,7 @@ def test(device: DeviceLikeType) -> Union[Exception, None]: ten2 = torch.randn((4, 8,), device=device) out = torch.mm(ten1, ten2) assert out.sum().is_nonzero() + return None except Exception as e: return e