提交 477bf93b authored 作者: Frederic's avatar Frederic

Added a comment about possible optimization.

上级 0781ba11
...@@ -4908,6 +4908,8 @@ class AdvancedSubtensor1(Op): ...@@ -4908,6 +4908,8 @@ class AdvancedSubtensor1(Op):
o = out[0] o = out[0]
else: else:
o = None o = None
# I have read that using clip or wrap mode make it a lot faster when the output is provided
out[0] = x.take(i, axis=0, out=o) out[0] = x.take(i, axis=0, out=o)
def grad(self, inputs, grads): def grad(self, inputs, grads):
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论