提交 388829e2 authored 作者: Razvan Pascanu's avatar Razvan Pascanu

Make speed test to only use CVM, and edited the names of each case.

上级 e3ff93df
...@@ -2467,7 +2467,7 @@ def test_speed(): ...@@ -2467,7 +2467,7 @@ def test_speed():
t2 = time.time() t2 = time.time()
f(r) f(r)
t3 = time.time() t3 = time.time()
print 'theano1', t3 - t2 print 'theano (scan)', t3 - t2
if 1: if 1:
r = numpy.arange(10000).astype(theano.config.floatX).reshape(-1,10) r = numpy.arange(10000).astype(theano.config.floatX).reshape(-1,10)
...@@ -2480,7 +2480,8 @@ def test_speed(): ...@@ -2480,7 +2480,8 @@ def test_speed():
updates={ updates={
s_i: s_i+1, s_i: s_i+1,
shared_r: s_rinc, shared_r: s_rinc,
}) },
mode = theano.Mode(linker='cvm'))
f._check_for_aliased_inputs = False f._check_for_aliased_inputs = False
t2 = time.time() t2 = time.time()
f_fn = f.fn f_fn = f.fn
...@@ -2488,7 +2489,7 @@ def test_speed(): ...@@ -2488,7 +2489,7 @@ def test_speed():
f_fn() f_fn()
f() #999 to update the profiling timers f() #999 to update the profiling timers
t3 = time.time() t3 = time.time()
print 'theano2', t3 - t2 print 'theano (updates)', t3 - t2
print shared_r.get_value() print shared_r.get_value()
def test_speed_rnn(): def test_speed_rnn():
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论