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
1
vote
1 answer

Lasagne use image inputs as the initial hidden state of a LSTMLayer

I am doing a project on image captioning. I want to set a batch of image features with shape=(batch_size, 512) as the initial hidden state of a LSTMLayer in Lasagne (theano). The sequence input to the LSTMLayer is a batch of text sequence with…
Jun
  • 35
  • 7
1
vote
0 answers

Error in theano-lasange function_module dimension mismatch during training

I am trying to integrate a part of the code (configuration/convroll4.py) from the link: https://github.com/benanne/kaggle-ndsb There is a dimension-mismatch issue at the first layer (cyclic slice layer) of convroll4.py. The line of code is: l0 =…
1
vote
0 answers

Lasgne performs much worse than Keras?

I'm doing a comparison between Keras (with Theano) and Lasagne on a toy regression problem in order to choose one of the two for my final application. As a result of this comparison, I see that Lasagne is performing so much worse than Keras that I'm…
1
vote
1 answer

lasagne.layers.DenseLayer: "__init__() takes at least 3 arguments"

I'm using Lasagne+Theano to create a ResNet and am struggling with the use of DenseLayer. If i use the example on http://lasagne.readthedocs.io/en/latest/modules/layers/dense.html it works. l_in = InputLayer((100, 20)) l1 = DenseLayer(l_in,…
TobSta
  • 766
  • 2
  • 10
  • 29
1
vote
1 answer

Depth Estimation using Keras

I'm trying to design a Convolutional Net to estimate the Depth of images using Keras. I have RGB Input images with the shape of 3x120x160 and have the Grayscale Output Depth Maps with the shape of 1x120x160. I tried using a VGG like architecture…
Cypher
  • 2,374
  • 4
  • 24
  • 36
1
vote
1 answer

Neural network: "InverseLayer"

I play around with neural networks. I understand how convolutional layers, fully connected layers and many other things work. I also know what a gradient is and how such a network is trained. The framework lasagne contains a layer called…
Kevin Meier
  • 2,339
  • 3
  • 25
  • 52
1
vote
1 answer

Python, Theano - ValueError: Input dimension mis-match

I have built a DNN in Theano based on the mnist.py example in Lasagne. I am trying to train a neural network made by a single hidden layer first, defined as def build_first_auto(input_var=None): l_input=lasagne.layers.InputLayer(shape=(None, 1,…
Phys
  • 508
  • 3
  • 11
  • 22
1
vote
1 answer

Approximating a simple sin() function with lasagne

I'm trying lasagne and the nolearn NeuralNet function to approximate a simple sin function. After all, neural nets are proven to be universal approximators, so I wanted to try lasagne on a simple non-linear function to show that fact experimentally.…
Jorge del Val
  • 111
  • 1
  • 3
1
vote
0 answers

Python program unexpectidely dies

I am training an LSTM network using lasagne, but my program dies without any error during the training. If I use a much smaller dataset ( only 13 data points) the entire code runs. I was initially using my GPU and thought that the memory was running…
1
vote
1 answer

Theano/Lasagne basic neural network with regression won't overfit dataset of size one

I'm using a basic neural network in Theano/Lasagne to try to identify facial keypoints in images, and am currently trying to get it to learn a single image (I've just taken the first image from my training set). The images are 96x96 pixels, and…
LomaxOnTheRun
  • 592
  • 1
  • 8
  • 21
1
vote
2 answers

CNN for recognizing five different faces

I have a project for face recognition of five people that I want my CNN to detect, and I was wondering if people could have a look at my model to see if this is a step in the right direction def model(): model= Sequential() # sort out the…
entercaspa
  • 674
  • 2
  • 7
  • 19
1
vote
1 answer

theano - evaluate the output of a neural network

I am trying to visualize the output of a neural network built with lasagne. In particular I have modified the code about the mnist example: https://github.com/Lasagne/Lasagne/blob/master/examples/mnist.py at line 299 I have inserted the following…
1
vote
1 answer

Increasing training data doesn't reduce overfitting in CNN

I am working on a CNN classification problem: Using CNN to classify audio emotions into 6 classes (anger, disgust, fear, happy, sad, neutral). I am using the EMODB dataset, and the input features are Fourier transforms [256*36]. And my CNN network…
1
vote
1 answer

Target value shape in Lasagne

I am trying to train a Siamese Lasagne model in batches of 100. The inputs are X1 (100x3x100x100) and X2 (same size) and Y(100x1) and my last layer is a Dense layer of one output dimension as I am expecting a value of 0 or 1 as a target value.…
jyoti
  • 65
  • 9
1
vote
1 answer

How to get values of neurons on layer? Python-nolearn

I have neural network created with using nolearn library. net = NeuralNet( layers=[ ('input', layers.InputLayer), ('conv1', layers.Conv2DLayer), ('pool1', layers.MaxPool2DLayer), ('dropout1', layers.DropoutLayer), ('conv2',…