提交 c6ec15bd authored 作者: Frederic's avatar Frederic

fix test in floatX=float32

上级 e46d6fa4
...@@ -174,8 +174,8 @@ class TestPushOutScanOutputDot(object): ...@@ -174,8 +174,8 @@ class TestPushOutScanOutputDot(object):
# Ensure that the function compiled with the optimization produces # Ensure that the function compiled with the optimization produces
# the same results as the function compiled without # the same results as the function compiled without
v_value = numpy.random.random((4)) v_value = numpy.random.random((4)).astype(config.floatX)
m_value = numpy.random.random((4, 5)) m_value = numpy.random.random((4, 5)).astype(config.floatX)
output_opt = f_opt(v_value, m_value) output_opt = f_opt(v_value, m_value)
output_no_opt = f_no_opt(v_value, m_value) output_no_opt = f_no_opt(v_value, m_value)
...@@ -218,8 +218,8 @@ class TestPushOutScanOutputDot(object): ...@@ -218,8 +218,8 @@ class TestPushOutScanOutputDot(object):
# Ensure that the function compiled with the optimization produces # Ensure that the function compiled with the optimization produces
# the same results as the function compiled without # the same results as the function compiled without
a_value = numpy.random.random((3, 4)) a_value = numpy.random.random((3, 4)).astype(config.floatX)
b_value = numpy.random.random((4, 5)) b_value = numpy.random.random((4, 5)).astype(config.floatX)
output_opt = f_opt(a_value, b_value) output_opt = f_opt(a_value, b_value)
output_no_opt = f_no_opt(a_value, b_value) output_no_opt = f_no_opt(a_value, b_value)
...@@ -264,8 +264,8 @@ class TestPushOutScanOutputDot(object): ...@@ -264,8 +264,8 @@ class TestPushOutScanOutputDot(object):
# Ensure that the function compiled with the optimization produces # Ensure that the function compiled with the optimization produces
# the same results as the function compiled without # the same results as the function compiled without
a_value = numpy.random.random((3, 4)) a_value = numpy.random.random((3, 4)).astype(config.floatX)
b_value = numpy.random.random((4, 5)) b_value = numpy.random.random((4, 5)).astype(config.floatX)
output_opt = f_opt(a_value, b_value) output_opt = f_opt(a_value, b_value)
output_no_opt = f_no_opt(a_value, b_value) output_no_opt = f_no_opt(a_value, b_value)
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论