From cc01d4b8836241e6637ebafedbbf46b0672ef565 Mon Sep 17 00:00:00 2001 From: Jingyan Wang Date: Thu, 25 Jan 2024 22:34:47 +0000 Subject: [PATCH 1/3] Give a triton library missing warning instead of silent fail --- orttraining/orttraining/python/training/ortmodule/options.py | 1 + 1 file changed, 1 insertion(+) diff --git a/orttraining/orttraining/python/training/ortmodule/options.py b/orttraining/orttraining/python/training/ortmodule/options.py index df3b078788d16..b9b962acd189b 100644 --- a/orttraining/orttraining/python/training/ortmodule/options.py +++ b/orttraining/orttraining/python/training/ortmodule/options.py @@ -379,6 +379,7 @@ def _override_from_env_vars(self): import triton # noqa: F401 except ImportError: pass + self._logger.warning("triton is not found. Please install triton with `pip install triton`") else: self.enable_triton = True From 023d00844393d60021d51479024569ea74ad38a0 Mon Sep 17 00:00:00 2001 From: Jingyan Wang Date: Thu, 25 Jan 2024 22:38:05 +0000 Subject: [PATCH 2/3] Give a triton library missing warning instead of silent fail --- orttraining/orttraining/python/training/ortmodule/options.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/orttraining/orttraining/python/training/ortmodule/options.py b/orttraining/orttraining/python/training/ortmodule/options.py index b9b962acd189b..e6c1d19139a3a 100644 --- a/orttraining/orttraining/python/training/ortmodule/options.py +++ b/orttraining/orttraining/python/training/ortmodule/options.py @@ -379,7 +379,7 @@ def _override_from_env_vars(self): import triton # noqa: F401 except ImportError: pass - self._logger.warning("triton is not found. Please install triton with `pip install triton`") + self._logger.warning("triton library missing. Please install triton with `pip install triton`. Triton feature will be off.") else: self.enable_triton = True From 93d179c912317ed2587fe6f55c2df7b6e8d1d868 Mon Sep 17 00:00:00 2001 From: Jingyan Wang Date: Thu, 1 Feb 2024 00:08:57 +0000 Subject: [PATCH 3/3] apply lintrunner --- orttraining/orttraining/python/training/ortmodule/options.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/orttraining/orttraining/python/training/ortmodule/options.py b/orttraining/orttraining/python/training/ortmodule/options.py index e6c1d19139a3a..539859a0d58a6 100644 --- a/orttraining/orttraining/python/training/ortmodule/options.py +++ b/orttraining/orttraining/python/training/ortmodule/options.py @@ -379,7 +379,9 @@ def _override_from_env_vars(self): import triton # noqa: F401 except ImportError: pass - self._logger.warning("triton library missing. Please install triton with `pip install triton`. Triton feature will be off.") + self._logger.warning( + "triton library missing. Please install triton with `pip install triton`. Triton feature will be off." + ) else: self.enable_triton = True