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
2
votes
1 answer

Convolutional Neural Network - Visualizing weights

Main Problem I cannot understand the Plot of the weights of a specific layer. I used a method from no-learn : plot_conv_weights(layer, figsize=(6, 6)) Im using lasagne as my neural-network library. The plot comes out fine, but I dont know how i…
KenobiBastila
  • 539
  • 4
  • 16
  • 52
2
votes
1 answer

Why can't I use dropout in the last layer of a lasagne regression model?

A toy regression example. With dropout=0.0 this works fine and the cost decreases. With dropout=0.5 I get the error: ValueError: Got num_leading_axes=1 for a 1-dimensional input, leaving no trailing axes for the dot product. Any thoughts? import…
daknowles
  • 1,426
  • 15
  • 19
2
votes
1 answer

Lasagne/Theano, problems loading pickled model

I think I'm losing my mind at this point. I'm using Lasagne for a small convolutional neural network. It trains perfectly, I can compute the error on training and validation set as well, but I cannot save the trained model on the disk. Better, I…
2
votes
1 answer

Converting a deep learning model from GPU powered framework, such as Theano, to a common, easily handled one, such as Numpy

I have been playing around with building some deep learning models in Python and now I have a couple of outcomes I would like to be able to show friends and family. Unfortunately(?), most of my friends and family aren't really up to the task of…
mirari
  • 349
  • 1
  • 3
  • 8
2
votes
1 answer

Theano falls back to CPU

I am training a model in Theano 0.9 and Lasagne 0.1 and want to run it on GPU. I've set THEANO_FLAGS as follows: THEANO_FLAGS=device=gpu0,force_device=True,floatX=float64 Theano prints it is using GPU Using gpu device 0: GeForce GTX 980 Ti (CNMeM…
yazfield
  • 1,233
  • 11
  • 18
2
votes
1 answer

How to properly add and use BatchNormLayer?

Introduction According to the lasagne docs : "This layer should be inserted between a linear transformation (such as a DenseLayer, or Conv2DLayer) and its nonlinearity. The convenience function batch_norm() modifies an existing layer to insert batch…
KenobiBastila
  • 539
  • 4
  • 16
  • 52
2
votes
0 answers

Artificial neural network not learning lower values of the training sample

I am trying to train an ANN but until now it is not learning the lower values of the training sample. I have tried using different python libraries to train ANN. The aim is to predict solar radiation from other weather parameters (regression…
Muhammad
  • 305
  • 2
  • 6
  • 20
2
votes
0 answers

Working with Theano and Lasagne AttributeError

Now i'm working with then and lasagne. I have .csv input file with named emotions, and coordinates of them on photo. I'n trying to teach neural net to understand emotion by coordinates. When i'm parsing .csv file to then variables, and giving it to…
2
votes
0 answers

Resizing image using CV2 freezes Lasagne/theano on prediction calculation

I trained a CNN using my own custom dataset, where Resizing the dataset images was done with the PIL library. Now When I try to predict the label of the input images in the dataset it works fine. My predict function within the CNN class is as…
Laende
  • 167
  • 2
  • 13
2
votes
0 answers

Full CNN - Is it possible to implement in (nolearn) Lasagne?

I am currently working with a very simple CNN and I am trying to figure out a way to make it into a Full CNN. By Full I mean not having any Dense layer and instead implement a deconvnet. The deconvnet part will be used as a localization part of the…
2
votes
1 answer

How to keep the weight value to zero in a particular location using theano or lasagne?

I'm a theano and lasagne user. I have a problem dealing with the variable length of the input matrix. i.e) x1 = [0, 1, 3] x2 = [1, 2] matrix_embedding = [ [ 0.1, 0.2, 0.3], [ 0.4, 0.5, 0.6], [ 0.2, 0.3,…
이경호
  • 97
  • 9
2
votes
1 answer

Data type incompatibility issue in Theano

I've got a dense dropout ANN with a softmax output layer. Here is the training method: def train(network, input_var, epochs, train_input, val_input, batchsize, update_fn, loss_fn, verbose=True, deterministic=False, **kwargs): """ …
Eli Korvigo
  • 10,265
  • 6
  • 47
  • 73
2
votes
2 answers

How to make Lasagne layers nontrainable

I want to use a pretrained neural network and just fine-tune it to my specific needs. I wanted to use Python and the Lasagne framework for this. …
Lars Aurdal
  • 103
  • 1
  • 5
2
votes
0 answers

Unset trainable attributes for parameters in lasagne / nolearn neural networks

I'm implementing a convolutional neural network using lasagne nolearn. I'd like to fix some parameters that prelearned. How can I set some layers untrainable? Actually, though I removed 'trainable' attribute of some layers, the number shown in the…
Naoaki ONO
  • 91
  • 1
  • 3
2
votes
2 answers

get_all_param_values() how to read lasagne.layer

I am running Lasagne and Theano to create my Convolutional Neural Network. I currently consist of l_shape = lasagne.layers.ReshapeLayer(l_in, (-1, 3,130, 130)) l_conv1 = lasagne.layers.Conv2DLayer(l_shape, num_filters=32, filter_size=3,…