提交 8a5b3599 编写于 作者: W wjj19950828

fixed pad op

上级 367a2b07
......@@ -630,12 +630,11 @@ class OpSet9():
layer_attrs["pad"] = paddings
paddle_op = "custom_layer:PadAllDim4WithOneInput"
else:
pad_data = pads
pad_data1 = pad_data[0::2]
pad_data_temp = pads[0::2]
pad_data_all = []
for i in range(len(pad_data1)):
pad_data_all.append(pad_data[i])
pad_data_all.append(pad_data[len(pad_data1) + i])
for i in range(len(pad_data_temp)):
pad_data_all.append(pads[i])
pad_data_all.append(pads[len(pad_data_temp) + i])
layer_attrs["pad"] = pad_data_all
self.paddle_graph.add_layer(
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册