diff --git a/x2paddle/op_mapper/pytorch2paddle/pytorch_op_mapper.py b/x2paddle/op_mapper/pytorch2paddle/pytorch_op_mapper.py index 6284e191464ced218170c63abbcf89dc6cf81fdf..4889fae99f865086ab848bee174108862ecca8b5 100644 --- a/x2paddle/op_mapper/pytorch2paddle/pytorch_op_mapper.py +++ b/x2paddle/op_mapper/pytorch2paddle/pytorch_op_mapper.py @@ -16,7 +16,7 @@ import torch import numpy as np from x2paddle.core.op_mapper import OpMapper from x2paddle.core.util import * -from x2paddle.core.paddle_graph import PaddleGraph +from x2paddle.core.program import PaddleGraph from x2paddle.op_mapper.pytorch2paddle import prim from x2paddle.op_mapper.pytorch2paddle import aten diff --git a/x2paddle/optimizer/linear_pass.py b/x2paddle/optimizer/linear_pass.py index 6af48192465530b9bf9c5a669076a16e8cf8efa0..e0267f92b86128685d84f33ce2d4f8500da69ac3 100644 --- a/x2paddle/optimizer/linear_pass.py +++ b/x2paddle/optimizer/linear_pass.py @@ -14,7 +14,7 @@ import numpy as np from x2paddle.core.util import * -from x2paddle.core.paddle_graph import PaddleLayer, PaddleGraph +from x2paddle.core.program import PaddleLayer, PaddleGraph from x2paddle.optimizer.passes import Pass, Matcher, PyTorchMatcher diff --git a/x2paddle/optimizer/optimizer.py b/x2paddle/optimizer/optimizer.py index c03b9e926b8fbe64cb51b362fbdd01baaa6511f0..5b06e54fe185627a3408d5b325d5d1488f7b939d 100644 --- a/x2paddle/optimizer/optimizer.py +++ b/x2paddle/optimizer/optimizer.py @@ -45,5 +45,5 @@ class GraphOptimizer(object): self.current_pass = _pass self.current_matcher = matcher graph, _ = self.run(graph) - print("{} done!".format(pa.__class__.__name__)) + print("{} done!".format(_pass.__class__.__name__)) return graph diff --git a/x2paddle/optimizer/passes.py b/x2paddle/optimizer/passes.py index 028a21198e3b6d54c5a94afd8f79ba8ec5a25113..8b80d8a09f36f56aa3bcecf45f036c47029b879d 100644 --- a/x2paddle/optimizer/passes.py +++ b/x2paddle/optimizer/passes.py @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -from x2paddle.core.paddle_graph import PaddleGraph +from x2paddle.core.program import PaddleGraph class Pass(object):