提交 752d5028 authored 作者: abergeron's avatar abergeron

Merge pull request #3961 from nouiz/test

Fix a test on GPU with mode=FAST_COMPILE
......@@ -35,7 +35,7 @@ install:
env:
- PART="theano/sandbox theano/sparse theano/scalar theano/tensor/nnet theano/scan_module"
- PART="theano/tensor/tests/test_basic.py theano/tensor/signal theano/compile theano/gof theano/misc theano/tests theano/compat"
- PART="-e test_basic.py theano/tensor/tests"
- PART="-e test_basic.py theano/tensor/tests theano/d3viz"
matrix:
fast_finish: true
......
......@@ -77,7 +77,7 @@ def d3viz(fct, outfile, copy_deps=True, *args, **kwargs):
# Create DOT graph
formatter = PyDotFormatter(*args, **kwargs)
graph = formatter(fct)
dot_graph = escape_quotes(graph.create_dot()).replace('\n', '').replace('\r', '')
dot_graph = escape_quotes(str(graph.create_dot())).replace('\n', '').replace('\r', '')
# Create output directory if not existing
outdir = os.path.dirname(outfile)
......
......@@ -45,6 +45,7 @@ def my_rand(*shape):
class TestBatchedDot(unittest_tools.InferShapeTester):
mode = mode_with_gpu
def test_batched_dot_correctness(self):
......
......@@ -55,7 +55,7 @@ def test_pydotprint_return_image():
x = tensor.dvector()
ret = theano.printing.pydotprint(x * 2, return_image=True)
assert isinstance(ret, str)
assert isinstance(ret, (str, bytes))
def test_pydotprint_variables():
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论