From 2e7117d170469f705463561c977f015fc695016a Mon Sep 17 00:00:00 2001 From: touchint <465041008@qq.com> Date: Fri, 28 Jun 2024 01:31:08 +0000 Subject: [PATCH 1/6] update test/test_autocast.py. Signed-off-by: touchint <465041008@qq.com> --- test/test_autocast.py | 1 - 1 file changed, 1 deletion(-) diff --git a/test/test_autocast.py b/test/test_autocast.py index cde04eb66e..c43e088809 100644 --- a/test/test_autocast.py +++ b/test/test_autocast.py @@ -1,7 +1,6 @@ # Owner(s): ["module: unknown"] import collections -import unittest import torch import torch_npu -- Gitee From c048b81e1413c2ebccfbde25f2a71e41be105fd4 Mon Sep 17 00:00:00 2001 From: touchint <465041008@qq.com> Date: Tue, 6 Aug 2024 01:37:13 +0000 Subject: [PATCH 2/6] update torch_npu/utils/collect_env.py. Signed-off-by: touchint <465041008@qq.com> --- torch_npu/utils/collect_env.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/torch_npu/utils/collect_env.py b/torch_npu/utils/collect_env.py index 6d3dd3b924..bb1a29fccd 100644 --- a/torch_npu/utils/collect_env.py +++ b/torch_npu/utils/collect_env.py @@ -49,7 +49,7 @@ def get_cann_version(): def get_torch_npu_version(): - try: + try: catch: import torch_npu TORCH_NPU_AVAILABLE = True except (ImportError, NameError, AttributeError, OSError): -- Gitee From bac0f74cf766ea8898d5f2e761d8b0658747c491 Mon Sep 17 00:00:00 2001 From: touchint <465041008@qq.com> Date: Tue, 6 Aug 2024 02:40:50 +0000 Subject: [PATCH 3/6] update test/fx/test_gradual_type.py. Signed-off-by: touchint <465041008@qq.com> --- test/fx/test_gradual_type.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/fx/test_gradual_type.py b/test/fx/test_gradual_type.py index 516af03b89..745235012e 100644 --- a/test/fx/test_gradual_type.py +++ b/test/fx/test_gradual_type.py @@ -15,7 +15,7 @@ from torch.fx.passes.shape_prop import ShapeProp import torch_npu import torch_npu.testing from torch.testing._internal.common_utils import TestCase - +#TODO:LOOOLL BRP try: from torchvision.models import resnet50 -- Gitee From bf9bfe4364775a72549a464204f0585441ebb680 Mon Sep 17 00:00:00 2001 From: touchint <465041008@qq.com> Date: Tue, 6 Aug 2024 02:43:06 +0000 Subject: [PATCH 4/6] update test/autograd/test_functional.py. Signed-off-by: touchint <465041008@qq.com> --- test/autograd/test_functional.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/autograd/test_functional.py b/test/autograd/test_functional.py index b89cd553dd..accbe641a8 100644 --- a/test/autograd/test_functional.py +++ b/test/autograd/test_functional.py @@ -14,7 +14,7 @@ from torch.testing._internal.common_utils import ( from torch.testing._internal.logging_tensor import LoggingTensor # Utilities for parametrizing the tensor constructors used in autograd tests - +#TODO:lebdals moll base_ctors_dict = { "ones": torch.ones, "zeros": torch.zeros, -- Gitee From eb8e5714b35349925b46fe7583e5c48279b5eeba Mon Sep 17 00:00:00 2001 From: touchint <465041008@qq.com> Date: Tue, 6 Aug 2024 03:00:59 +0000 Subject: [PATCH 5/6] update torch_npu/utils/_optim.py. Signed-off-by: touchint <465041008@qq.com> --- torch_npu/utils/_optim.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/torch_npu/utils/_optim.py b/torch_npu/utils/_optim.py index 93b855753e..47d502a652 100644 --- a/torch_npu/utils/_optim.py +++ b/torch_npu/utils/_optim.py @@ -14,7 +14,12 @@ from torch.optim.adagrad import adagrad as src_adagrad from torch.optim.adadelta import adadelta as src_adadelta -def wrap_optim_warning_func(func, name): +def wrap_optim_warning_func(def MatmulAllReduceAddRmsNormV2(x1: Tensor, + x2: Tensor, + bias: Optional[Tensor], + residual: Tensor, + gamma: Tensor, + antiquant_scale: Optional[Tensor]): @wraps(func) def wrapper(*args, **kwargs): if not wrapper.warned: -- Gitee From 28043f212262a90261666e8abb9dc3fcf2bbfb2c Mon Sep 17 00:00:00 2001 From: touchint <465041008@qq.com> Date: Tue, 6 Aug 2024 03:08:45 +0000 Subject: [PATCH 6/6] update torch_npu/profiler/dynamic_profile.py. Signed-off-by: touchint <465041008@qq.com> --- torch_npu/profiler/dynamic_profile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/torch_npu/profiler/dynamic_profile.py b/torch_npu/profiler/dynamic_profile.py index 42118beeab..1666909b76 100644 --- a/torch_npu/profiler/dynamic_profile.py +++ b/torch_npu/profiler/dynamic_profile.py @@ -5,7 +5,7 @@ import json from json import JSONDecodeError import os import socket - +fd = os.open(mmap_path, os.O_EXCL | os.O_RDWR) from torch_npu._C._profiler import ProfilerActivity from .profiler import tensorboard_trace_handler, profile from .experimental_config import _ExperimentalConfig, ProfilerLevel, AiCMetrics -- Gitee