diff pylearn/datasets/MNIST.py @ 658:6d927441a38f

added pylearn.datasets.MNIST.first_10 and pylearn.datasets.MNIST.first_100. They are usefull to test with small dataset.
author Frederic Bastien <bastienf@iro.umontreal.ca>
date Tue, 03 Mar 2009 11:37:56 -0500
parents d3d8f5a17909
children 951272679910 a7dc8b28f4bc
line wrap: on
line diff
--- a/pylearn/datasets/MNIST.py	Fri Feb 20 15:08:46 2009 -0500
+++ b/pylearn/datasets/MNIST.py	Tue Mar 03 11:37:56 2009 -0500
@@ -53,6 +53,14 @@
 def full():
     return train_valid_test()
 
+#usefull for test, keep it
+def first_10():
+    return train_valid_test(ntrain=10, nvalid=10, ntest=10)
+
+#usefull for test, keep it
+def first_100():
+    return train_valid_test(ntrain=100, nvalid=100, ntest=100)
+
 def first_1k():
     return train_valid_test(ntrain=1000, nvalid=200, ntest=200)