GeezerVison is showing github.com — Add rnnrbm as a speed test. · zencoding/DeepLearningTutorials@ea3096f
File treeExpand file treeCollapse file tree Open diff view settings Expand file treeCollapse file tree Open diff view settings Collapse file Copy file name to clipboardExpand all lines: code/test.py +5-4Lines changed: 5 additions & 4 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -59,7 +59,7 @@ def speed(): | 59 | 59 | """ | 60 | 60 |
| 61 | 61 | algo = ['logistic_sgd', 'logistic_cg', 'mlp', 'convolutional_mlp', | 62 | | - 'dA', 'SdA', 'DBN', 'rbm'] | | 62 | + 'dA', 'SdA', 'DBN', 'rbm', 'rnnrbm'] | 63 | 63 | to_exec = [True] * len(algo) | 64 | 64 | # to_exec=[False]*len(algo) | 65 | 65 | # to_exec[-1]=True | @@ -73,9 +73,9 @@ def speed(): | 73 | 73 | # and an GeForce GTX 285 for the GPU. | 74 | 74 |
| 75 | 75 | expected_times_64 = numpy.asarray([10.3, 23.7, 78.1, 73.7, 116.4, | 76 | | - 346.9, 381.9, 558.1]) | | 76 | + 346.9, 381.9, 558.1, 186.3]) | 77 | 77 | expected_times_32 = numpy.asarray([11.6, 29.6, 47.2, 66.5, 71, | 78 | | - 191.2, 226.8, 432.8]) | | 78 | + 191.2, 226.8, 432.8, 176.2]) | 79 | 79 |
| 80 | 80 | # Number with just 1 decimal are new value that are faster with | 81 | 81 | # the Theano version 0.5rc2 Other number are older. They are not | @@ -95,7 +95,7 @@ def speed(): | 95 | 95 | # 1.35324519 1.7356905 1.12937868] | 96 | 96 | expected_times_gpu = numpy.asarray([3.07663488, 7.55523491, 18.99226785, | 97 | 97 | 9.6, 24.13007045, | 98 | | - 20.4, 56, 302.6]) | | 98 | + 20.4, 56, 302.6, 315.4]) | 99 | 99 | expected_times_64 = [s for idx, s in enumerate(expected_times_64) | 100 | 100 | if to_exec[idx]] | 101 | 101 | expected_times_32 = [s for idx, s in enumerate(expected_times_32) | @@ -133,6 +133,7 @@ def do_tests(): | 133 | 133 | training_epochs=2, batch_size=300) | 134 | 134 | time_test(m, l, 7, rbm.test_rbm, training_epochs=1, batch_size=300, | 135 | 135 | n_chains=1, n_samples=1, output_folder='tmp_rbm_plots') | | 136 | + time_test(m, l, 8, rnnrbm.test_rnnrbm, num_epochs=1) | 136 | 137 | return numpy.asarray(l) | 137 | 138 |
| 138 | 139 | #test in float64 in FAST_RUN mode on the cpu | |
|