提交 5f840278 authored 作者: lucianopaz's avatar lucianopaz 提交者: Ricardo Vieira

Make test_debugprint robust to environments without blas__ldflags

上级 90d8b9f2
...@@ -272,29 +272,32 @@ def test_debugprint(): ...@@ -272,29 +272,32 @@ def test_debugprint():
print_view_map=True, print_view_map=True,
) )
s = s.getvalue() s = s.getvalue()
Gemv_op_name = "CGemv" if pytensor.config.blas__ldflags else "Gemv"
exp_res = dedent( exp_res = dedent(
r""" r"""
Composite{(i2 + (i0 - i1))} 4 Composite{(i2 + (i0 - i1))} 4
├─ ExpandDims{axis=0} v={0: [0]} 3 ├─ ExpandDims{axis=0} v={0: [0]} 3
│ └─ CGemv{inplace} d={0: [0]} 2 """
│ ├─ AllocEmpty{dtype='float64'} 1 f" │ └─ {Gemv_op_name}{{inplace}} d={{0: [0]}} 2"
│ │ └─ Shape_i{0} 0 r"""
│ │ └─ B │ ├─ AllocEmpty{dtype='float64'} 1
│ ├─ 1.0 │ │ └─ Shape_i{0} 0
│ ├─ B │ │ └─ B
│ ├─ <Vector(float64, shape=(?,))> │ ├─ 1.0
│ └─ 0.0 │ ├─ B
├─ D │ ├─ <Vector(float64, shape=(?,))>
└─ A │ └─ 0.0
├─ D
└─ A
Inner graphs: Inner graphs:
Composite{(i2 + (i0 - i1))} Composite{(i2 + (i0 - i1))}
← add 'o0' ← add 'o0'
├─ i2 ├─ i2
└─ sub └─ sub
├─ i0 ├─ i0
└─ i1 └─ i1
""" """
).lstrip() ).lstrip()
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论