已合并
关闭torch自动加载后端组件(torch_npu等组件),修复只安装toolkit包报错找不到libhccl.so问题 #233
关闭torch自动加载后端组件(torch_npu等组件),修复只安装toolkit包报错找不到libhccl.so问题 #233
已合并
chen-shuai创建于 5月8日
15 个文件变更+37-0
MSamples/1_Features/memory_optimization/scale_cache/scripts/gen_data.py+2-0
@@ -15,6 +15,8 @@ import math
15import os15import os
16import sys16import sys
17 17 
18+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
19+ 
18import numpy as np20import numpy as np
19import torch21import torch
20from en_dtypes import float8_e8m022from en_dtypes import float8_e8m0
MSamples/1_Features/memory_optimization/scale_cache/scripts/verify_result.py+3-0
@@ -8,8 +8,11 @@
8# See LICENSE in the root of the software repository for the full text of the License.8# See LICENSE in the root of the software repository for the full text of the License.
9# ----------------------------------------------------------------------------------------------------------9# ----------------------------------------------------------------------------------------------------------
10 10 
11+import os
11import sys12import sys
12 13 
14+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
15+ 
13import numpy as np16import numpy as np
14import torch17import torch
15 18 
MSamples/2_Performance/grouped_matmul_story/grouped_matmul_recipes/examples/quant_grouped_matmul_mxfp4/scripts/gen_data.py+2-0
@@ -16,6 +16,8 @@ import os
16import sys16import sys
17from typing import List, Tuple17from typing import List, Tuple
18 18 
19+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
20+ 
19import numpy as np21import numpy as np
20import torch22import torch
21from en_dtypes import float8_e8m023from en_dtypes import float8_e8m0
MSamples/2_Performance/grouped_matmul_story/grouped_matmul_recipes/examples/quant_grouped_matmul_mxfp4/scripts/verify_result.py+3-0
@@ -8,9 +8,12 @@
8# See LICENSE in the root of the software repository for the full text of the License.8# See LICENSE in the root of the software repository for the full text of the License.
9# ----------------------------------------------------------------------------------------------------------9# ----------------------------------------------------------------------------------------------------------
10 10 
11+import os
11import sys12import sys
12from typing import List13from typing import List
13 14 
15+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
16+ 
14import numpy as np17import numpy as np
15import torch18import torch
16 19 
MSamples/2_Performance/grouped_matmul_story/grouped_matmul_recipes/examples/quant_grouped_matmul_mxfp8/scripts/gen_data.py+2-0
@@ -16,6 +16,8 @@ import os
16import sys16import sys
17from typing import List, Tuple17from typing import List, Tuple
18 18 
19+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
20+ 
19import numpy as np21import numpy as np
20import torch22import torch
21from en_dtypes import float8_e8m023from en_dtypes import float8_e8m0
MSamples/2_Performance/grouped_matmul_story/grouped_matmul_recipes/examples/quant_grouped_matmul_mxfp8/scripts/verify_result.py+3-0
@@ -8,9 +8,12 @@
8# See LICENSE in the root of the software repository for the full text of the License.8# See LICENSE in the root of the software repository for the full text of the License.
9# ----------------------------------------------------------------------------------------------------------9# ----------------------------------------------------------------------------------------------------------
10 10 
11+import os
11import sys12import sys
12from typing import List13from typing import List
13 14 
15+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
16+ 
14import numpy as np17import numpy as np
15import torch18import torch
16 19 
MSamples/2_Performance/grouped_matmul_story/grouped_matmul_recipes/examples/weight_quant_grouped_matmul_mxfp8fp4/scripts/gen_data.py+2-0
@@ -17,6 +17,8 @@ import sys
17from concurrent.futures import ThreadPoolExecutor17from concurrent.futures import ThreadPoolExecutor
18from typing import List, Tuple18from typing import List, Tuple
19 19 
20+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
21+ 
20import numpy as np22import numpy as np
21from en_dtypes import float8_e8m023from en_dtypes import float8_e8m0
22from ml_dtypes import float4_e2m1fn, float8_e4m3fn24from ml_dtypes import float4_e2m1fn, float8_e4m3fn
MSamples/2_Performance/matmul_story/matmul_recipes/examples/matmul_a16w16/scripts/gen_data.py+2-0
@@ -14,6 +14,8 @@
14import os14import os
15import sys15import sys
16 16 
17+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
18+ 
17import numpy as np19import numpy as np
18import torch20import torch
19from ml_dtypes import bfloat1621from ml_dtypes import bfloat16
MSamples/2_Performance/matmul_story/matmul_recipes/examples/matmul_a16w16/scripts/verify_result.py+3-0
@@ -8,8 +8,11 @@
8# See LICENSE in the root of the software repository for the full text of the License.8# See LICENSE in the root of the software repository for the full text of the License.
9# ----------------------------------------------------------------------------------------------------------9# ----------------------------------------------------------------------------------------------------------
10 10 
11+import os
11import sys12import sys
12 13 
14+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
15+ 
13import numpy as np16import numpy as np
14import torch17import torch
15 18 
MSamples/2_Performance/matmul_story/matmul_recipes/examples/quant_matmul_mxfp4/scripts/gen_data.py+2-0
@@ -15,6 +15,8 @@ import math
15import os15import os
16import sys16import sys
17 17 
18+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
19+ 
18import numpy as np20import numpy as np
19import torch21import torch
20from en_dtypes import float8_e8m022from en_dtypes import float8_e8m0
MSamples/2_Performance/matmul_story/matmul_recipes/examples/quant_matmul_mxfp4/scripts/verify_result.py+3-0
@@ -8,8 +8,11 @@
8# See LICENSE in the root of the software repository for the full text of the License.8# See LICENSE in the root of the software repository for the full text of the License.
9# ----------------------------------------------------------------------------------------------------------9# ----------------------------------------------------------------------------------------------------------
10 10 
11+import os
11import sys12import sys
12 13 
14+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
15+ 
13import numpy as np16import numpy as np
14import torch17import torch
15 18 
MSamples/2_Performance/matmul_story/matmul_recipes/examples/quant_matmul_mxfp8/scripts/gen_data.py+2-0
@@ -15,6 +15,8 @@ import math
15import os15import os
16import sys16import sys
17 17 
18+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
19+ 
18import numpy as np20import numpy as np
19import torch21import torch
20from en_dtypes import float8_e8m022from en_dtypes import float8_e8m0
MSamples/2_Performance/matmul_story/matmul_recipes/examples/quant_matmul_mxfp8/scripts/verify_result.py+3-0
@@ -8,8 +8,11 @@
8# See LICENSE in the root of the software repository for the full text of the License.8# See LICENSE in the root of the software repository for the full text of the License.
9# ----------------------------------------------------------------------------------------------------------9# ----------------------------------------------------------------------------------------------------------
10 10 
11+import os
11import sys12import sys
12 13 
14+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
15+ 
13import numpy as np16import numpy as np
14import torch17import torch
15 18 
MSamples/2_Performance/matmul_story/matmul_tutorials/scripts/gen_data.py+2-0
@@ -15,6 +15,8 @@ import math
15import os15import os
16import sys16import sys
17 17 
18+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
19+ 
18import numpy as np20import numpy as np
19import torch21import torch
20from en_dtypes import float8_e8m022from en_dtypes import float8_e8m0
MSamples/2_Performance/matmul_story/matmul_tutorials/scripts/verify_result.py+3-0
@@ -8,8 +8,11 @@
8# See LICENSE in the root of the software repository for the full text of the License.8# See LICENSE in the root of the software repository for the full text of the License.
9# ----------------------------------------------------------------------------------------------------------9# ----------------------------------------------------------------------------------------------------------
10 10 
11+import os
11import sys12import sys
12 13 
14+os.environ["TORCH_DEVICE_BACKEND_AUTOLOAD"] = "0"
15+ 
13import numpy as np16import numpy as np
14import torch17import torch
15 18