提交 665937e3 编写于 作者: J jiangjiajun

cast dtype for onnx2paddle: Tile

上级 3a818e82
......@@ -1336,6 +1336,12 @@ class OpSet9():
if repeats is None:
repeats = val_repeats.layer_name
if val_repeats.dtype != 'int32':
attr = {"dtype": string("int32")}
node.fluid_code.add_layer(
"cast", inputs=repeats, output="{}.tmp".format(repeats), param_attr=attr)
repeats = "{}.tmp".format(repeats)
elif isinstance(repeats, int):
repeats = [repeats]
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册