提交 9b3cccf0 authored 作者: Frederic Bastien's avatar Frederic Bastien

Fixed return type that was a numpy scalar and not an ndarray

This bug was found by the buildbot in debug mode.
上级 1c9db81d
......@@ -79,7 +79,7 @@ class SpSum(Op):
def perform(self,node, (x,), (z,)):
if self.axis is None:
z[0] = x.sum()
z[0] = numpy.asarray(x.sum())
if self.axis == 0:
z[0] = numpy.asarray(x.sum(axis=0)).reshape((x.shape[1],))
if self.axis == 1:
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论