提交 8761c77a authored 作者: Brandon T. Willard's avatar Brandon T. Willard 提交者: Brandon T. Willard

Replace use of broadcastable with shape in aesara.sparse.rewriting

上级 7d72236a
......@@ -677,7 +677,7 @@ class UsmmCscDense(_NoPythonCOp):
assert x_ind.dtype == "int32"
assert x_ptr.dtype == "int32"
assert x_nrows.dtype == "int32"
assert alpha.ndim == 2 and alpha.type.broadcastable == (True, True)
assert alpha.ndim == 2 and alpha.type.shape == (1, 1)
assert x_val.ndim == 1
assert y.ndim == 2
assert z.ndim == 2
......@@ -905,7 +905,7 @@ local_usmm = PatternNodeRewriter(
{
"pattern": "alpha",
"constraint": lambda expr: (
all(expr.type.broadcastable) and config.blas__ldflags
all(s == 1 for s in expr.type.shape) and config.blas__ldflags
),
},
(sparse._dot, "x", "y"),
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论