From 9bd6405cc90a821f529fea05bf31cceabbec9ad0 Mon Sep 17 00:00:00 2001 From: BenjaminBossan Date: Tue, 6 Oct 2015 22:34:24 +0200 Subject: [PATCH] Added a test that will currently fail, not sure how to fix it yet. --- nolearn/lasagne/tests/test_base.py | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/nolearn/lasagne/tests/test_base.py b/nolearn/lasagne/tests/test_base.py index 8d642eb..163d728 100644 --- a/nolearn/lasagne/tests/test_base.py +++ b/nolearn/lasagne/tests/test_base.py @@ -193,6 +193,24 @@ def fit(self, X, y): ) +def test_lasagne_functional_grid_search_architecture(mnist): + from nolearn.lasagne import NeuralNet + from lasagne import layers + + X, y = mnist + + l_in = layers.InputLayer(shape=(None, X.shape[1])) + l_out0 = layers.DenseLayer(l_in, num_units=10) + l_out1 = layers.DenseLayer(l_in, num_units=10) + + nn = NeuralNet(l_out0) + + param_grid = {'layers': [l_out0, l_out1]} + + gs = GridSearchCV(nn, param_grid, cv=2, refit=False, verbose=4) + gs.fit(X[:1000], y[:1000]) + + def test_clone(): from nolearn.lasagne import NeuralNet from nolearn.lasagne import BatchIterator