提交 03b07d02 authored 作者: Frederic's avatar Frederic

Fix buildbot bug about set_subtensor with list of index.

James added to AdvancedIncSubtensor1 the ability to do set intead of inc. But forgot to update the optimization to pass this new information. This is a real bug introduced in the trunk but not released.
上级 45e70682
...@@ -1659,7 +1659,7 @@ compile.optdb.register('inplace_setsubtensor', TopoOptimizer(local_inplace_setsu ...@@ -1659,7 +1659,7 @@ compile.optdb.register('inplace_setsubtensor', TopoOptimizer(local_inplace_setsu
def local_inplace_incsubtensor1(node): def local_inplace_incsubtensor1(node):
""" also work for GpuAdvancedIncSubtensor1 """ """ also work for GpuAdvancedIncSubtensor1 """
if isinstance(node.op, T.AdvancedIncSubtensor1) and not node.op.inplace: if isinstance(node.op, T.AdvancedIncSubtensor1) and not node.op.inplace:
new_op = node.op.__class__(inplace=True) new_op = node.op.__class__(inplace=True, set_instead_of_inc=node.op.set_instead_of_inc)
new_node = new_op(*node.inputs) new_node = new_op(*node.inputs)
return [new_node] return [new_node]
return False return False
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论