As @vdumoulin suggested, it would be better to use either a small dataset randomly generated on the fly.
This could also be done only as a fallback, for instance:
``` Python
from pylearn2.datasets import exc
try:
    dataset = MNIST(which_set='train')
    test_set = MNIST(which_set='test')
except (exc.NoDataPathError, exc.NotInstalledError):
    from pylearn2.testing.datasets import random_one_hot_topological_dense_design_matrix\
        as rand_1h_topo_ddm
    rng = np.random.RandomState(987654321)
    dataset = rand_1h_topo_ddm(rng=rng, num_examples=5000, shape=(28, 28), channels=1,
                               axes=('b', 0, 1, 'c'), num_classes=10)
    test_set = rand_1h_topo_ddm(rng=rng, num_examples=100, shape=(28, 28), channels=1,
                                axes=('b', 0, 1, 'c'), num_classes=10)
```