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 1e94adc8de0d34b6c58c4a33b7249f94b02f4751..f1508f793a92e66d36c1aa92f3836c18d2303ed3 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 13122c2794eb186279f90b703d70c289ccbd0fa9..7fd596f59fe7acf7a1e9f2ce095c284c72f1a337 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 unittest 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 081074dcab8a2a992a7529f26e19e9aae99c27a0..903c1115b08868cda9bfd3b663b8fcd238631dd8 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 @@ sys.path.append("..") 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 2ee809facab4feb1107d69bb298367c5706444be..48a40847708ce8dfba422a9dc8c7aa157db32f77 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