Questions tagged [lasagne]

Lasagne provides a high-level API for creating neural networks using Theano on the backend. Questions about lasagne do not need to also utilize the "theano" tag, unless the question is specifically about Lasagne-Theano integration or the Theano backend.

Lasagne is a Python package build around expressions for neural networks training. was designed as a high-level API on top of , with the intention of making rapid prototyping of neural network architectures easier. It is similar in spirit to , which is built as a high-level API on top of //, although the main difference is that Lasagne implements only one backend, allowing it to integrate more deeply with Theano features.

Resources

Resources and Teaching

Implementations of Network Architectures

204 questions
0
votes
2 answers

Learning Rate Decay in Lasagne

I am using nesterov momentum for updating the weights of a Convolutional Neural Network. I am using Lasagne for building a CNN. How to implement learning rate decay for every epoch? prediction = lasagne.layers.get_output(network) loss =…
0
votes
1 answer

Saving theano/lasagne output parameters for future classification

I am trying to save my output parameters so I can continue training/ classifying at a later date. I am currently using: np.savez('model.npz', *lasagne.layers.get_all_param_values(network)) with np.load('model.npz') as f: param_values =…
JP1
  • 731
  • 1
  • 10
  • 27
0
votes
1 answer

Custom loss function for lasagne/ theano

I am trying to create a custom loss function for use in lasagne. I would like to use Sorensen-dice coefficient which I have written with numpy, and use for evaluation like so: np.sum(np.logical_and(preds == num_labs, labels == num_labs)))*2/…
JP1
  • 731
  • 1
  • 10
  • 27
0
votes
1 answer

Binary-CrossEntropy - Works on Keras But Not on Lasagne?

Im using the same convolutional neural network structure on Keras and Lasagne. Right now, i just changed to a simple network to see if it changed anything, but it didnt. On Keras it works fine, it outputs values between 0 and 1 with a good…
KenobiBastila
  • 539
  • 4
  • 16
  • 52
0
votes
0 answers

How to Tune neural network parameters and cross-validate NN's performance [Lasagne]?

Is there a way to programmatically tune neural network's (NN) parameters (e.g. Gridsearch in scikitlearn) or I have to tune them experimentally (changing one at a time) in Lasagne? I know there are different rules of thumb to select NN's parameters…
Muhammad
  • 305
  • 2
  • 6
  • 20
0
votes
1 answer

Train convolutional neural network with theano/lasagne

I'm trying to implement a CNN using theano/lasagne. I've made a neural network but can't figure out how to train it with the current state. This is how I'm trying to get the output of the network with the current_states as input. train =…
0
votes
1 answer

add all my python path to pycharm

I'm using PyCharm in Ubuntu 14.04. So when I use iPython I can see the libraries that I am using by: $ import sys $ print sys.path results: ['', '/home/alireza/anaconda2/bin',…
Alex
  • 1,194
  • 1
  • 12
  • 20
0
votes
2 answers

Simple Lasange Neural Network not working

I'm using the Lasagne package to build a simple 3 layer neural network, and I'm testing it on a very simple dataset (just 4 examples). X = np.array([[0,0,1], [0,1,1], [1,0,1], [1,1,1]]) y =…
Ricky Jones
  • 131
  • 3
  • 8
0
votes
1 answer

Bad argument to theano function, Wrong number of dimensions

I am predicting 20 numbers for a regression tasks from a VGG, using lasagne and theano. For an example script I wrote, number of images are 100. I think I am doing something stupid, but am stuck. Looking online, for people who use nolearn, it can…
madratman
  • 127
  • 2
  • 8
0
votes
1 answer

Theano dimensionality error - target dimensions

I am using lasagne's Conv3DDNNLayer, and have input dimensions of (N x 1 x 9 x 9 x 9), where each 9x9x9 cube is my sample to be classified. Therefore I have a target dimension of (N x 1), with each entry corresponding to a cube. This is raising the…
JP1
  • 731
  • 1
  • 10
  • 27
0
votes
1 answer

ReLu with a threshold in Lasagne

I am building a simple convolutional network using the Lasagne package and wanted to add a ReLu layer with a simple threshold [max(0,x-threshold)] but could only find rectifiers without a trainable parameter (lasagne.layers.NonlinearityLayer) or…
0
votes
1 answer

How to get the output target values for the test data in the following MLP of Lasagne

http://lasagne.readthedocs.org/en/latest/user/tutorial.html#id2 I have tried the following network_output = lasagne.layers.get_output(network) f = theano.function([input_var], network_output[:,-1]) y_hat = f(X_train) however I get NAN for all the…
a'-
  • 251
  • 5
  • 14
0
votes
0 answers

Lasagne basic example not working?

I went through the install steps for lasagne, straight from the lasagne docs. And now I am running the following example: https://github.com/Lasagne/Lasagne/blob/master/examples/mnist.py The output expected is shown on the tutorial page of the…
0
votes
1 answer

Max pooling indices

I am trying to find the indices 2d max pooling in lasagne network = batch_norm(Conv2DLayer( network, num_filters=filter_size, filter_size=(kernel, kernel),pad=pad, nonlinearity=lasagne.nonlinearities.rectify, …
Pradyumna
  • 167
  • 2
  • 12
0
votes
1 answer

Weird gradient results with recurrent layers

I've been experimenting with very basic recurrent networks and have seen really strange behaviors. I've spent quite a bit of time trying to narrow down where it goes wrong and I ended up finding that the gradients computed by theano and by finite…
Julien
  • 13,986
  • 5
  • 29
  • 53
1 2 3
13
14