提交 b2291ff3 authored 作者: Razvan Pascanu's avatar Razvan Pascanu

deal wiwth the case when destroy_map is not defined

上级 30170732
......@@ -538,8 +538,12 @@ class Scan(PureOp):
dtype='int32')
cython_vector_outs = numpy.asarray(self.vector_outs,
dtype='int32')
cython_destroy_map = [x in self.destroy_map
if hasattr(self, 'destroy_map'):
cython_destroy_map = [x in self.destroy_map
for x in xrange(len(node.outputs))]
else:
cython_destroy_map = [0 for x in xrange(len(node.outputs))]
cython_destroy_map = numpy.asarray(cython_destroy_map,
dtype='int32')
import scan_perform_ext
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论