From 01f4bcb57ee99a9d5c2d52cbc7cbce4c4a0454c8 Mon Sep 17 00:00:00 2001 From: typhoonzero Date: Sun, 11 Feb 2018 16:54:01 +0800 Subject: [PATCH] remove inputs/outputs from Operator --- python/paddle/v2/fluid/distribute_transpiler.py | 2 +- python/paddle/v2/fluid/framework.py | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/python/paddle/v2/fluid/distribute_transpiler.py b/python/paddle/v2/fluid/distribute_transpiler.py index ff84e609e2..f84481adf7 100644 --- a/python/paddle/v2/fluid/distribute_transpiler.py +++ b/python/paddle/v2/fluid/distribute_transpiler.py @@ -424,7 +424,7 @@ class DistributeTranspiler: # change output's ParamOut variable outputs = self._get_output_map_from_op(self.program.global_block().vars, opt_op) - opt_op.outputs["ParamOut"] = new_inputs["Param"] + outputs["ParamOut"] = new_inputs["Param"] optimize_block.append_op( type=opt_op.type, diff --git a/python/paddle/v2/fluid/framework.py b/python/paddle/v2/fluid/framework.py index a517db68c5..35d3df785b 100644 --- a/python/paddle/v2/fluid/framework.py +++ b/python/paddle/v2/fluid/framework.py @@ -400,9 +400,6 @@ class Operator(object): """ self.block = block self.desc = desc - # for clone a new operator - self.inputs = inputs - self.outputs = outputs self.attrs = attrs if len(self.desc.type()) != 0: return -- GitLab