diff --git a/python/paddle/distributed/auto_parallel/tuner/rule_based_tuner.py b/python/paddle/distributed/auto_parallel/tuner/rule_based_tuner.py index 1e94adc8de0d34..f1508f793a92e6 100644 --- a/python/paddle/distributed/auto_parallel/tuner/rule_based_tuner.py +++ b/python/paddle/distributed/auto_parallel/tuner/rule_based_tuner.py @@ -13,8 +13,8 @@ # limitations under the License. import math - from abc import abstractmethod + from ..graph import Graph _PATTERNS = {} diff --git a/python/paddle/fluid/tests/unittests/test_device_guard.py b/python/paddle/fluid/tests/unittests/test_device_guard.py index 13122c2794eb18..7fd596f59fe7ac 100644 --- a/python/paddle/fluid/tests/unittests/test_device_guard.py +++ b/python/paddle/fluid/tests/unittests/test_device_guard.py @@ -16,7 +16,6 @@ import warnings import paddle -import paddle.fluid as fluid import paddle.fluid.core as core paddle.enable_static() diff --git a/python/paddle/fluid/tests/unittests/xpu/test_device_guard_xpu.py b/python/paddle/fluid/tests/unittests/xpu/test_device_guard_xpu.py index 081074dcab8a2a..903c1115b08868 100644 --- a/python/paddle/fluid/tests/unittests/xpu/test_device_guard_xpu.py +++ b/python/paddle/fluid/tests/unittests/xpu/test_device_guard_xpu.py @@ -20,7 +20,6 @@ import warnings import paddle -import paddle.fluid as fluid import paddle.fluid.core as core paddle.enable_static() diff --git a/python/paddle/utils/inplace_utils.py b/python/paddle/utils/inplace_utils.py index 2ee809facab4fe..48a40847708ce8 100644 --- a/python/paddle/utils/inplace_utils.py +++ b/python/paddle/utils/inplace_utils.py @@ -13,8 +13,8 @@ # limitations under the License. import warnings -import paddle -from paddle import _C_ops, _legacy_C_ops + +import paddle # noqa: F401 from paddle.fluid.framework import _non_static_mode from paddle.fluid.wrapped_decorator import wrap_decorator