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
0 answers

How to traverse model layers as a tree in theano/lasagne?

I need to traverse the model's layers by tree levels, such that getting the ancestor(input) and predecessor(output) layers and the adjacent layers in the same level. here's a model as an example: import lasagne def toy_model(): l_input =…
0
votes
1 answer

How to override gradient for the nonlinearity functions in lasagne?

I have a model, for which i need to compute the gradients of output w.r.t the model's input. But I want to apply some custom gradients for some of the nonlinearity functions applied on some of the model's layers. So i tried the idea explained here,…
0
votes
1 answer

Cannot import anything from lasagne-0.1

I have just installed both Theano and Lasagne using conda for Theano and pip for Lasagne. Both reside in subdirectories under " C:\Users\chets\anaconda3\envs\tensorflow\Lib\site-packages". The following code works: import theano The following code…
cseligman
  • 1
  • 3
0
votes
1 answer

ImportError: cannot import name 'downsample' while importing lasagne in python 3.6

I am getting the above error with the following import statements on Google Colab GPU: import argparse #import cPickle import _pickle as cPickle import time import os import numpy as np import theano as th import theano.tensor as T from…
python_noob
  • 266
  • 3
  • 14
0
votes
2 answers

NN Digit recognizition - Memory error, any ideas?

im trying to make a trained OCR for digits, but i keep getting a memory allocation error and cant seem to figure out whats going wrong, worked just fine in start, but after 2 runs it suddenly started spiting these errors out, tried deleting zips and…
user12111780
0
votes
1 answer

buiding a network using lasagne and theano

I am trying to build a network but I am getting the following error this is the building and training code The network was built by this following video code The data I created using this repository githup repository The train contains 24 class of…
xxzozoxx1
  • 82
  • 8
0
votes
2 answers

Lasagne package issue

In Conda prompt it shows resolving metadata and then in the solving environment it takes lots of time & shows error saying it couldn't perform by frozen method so tries for dynamic pan but still not executed. How can I install the lasagne package in…
0
votes
1 answer

How to convert this loss function written in Lasagne to Keras?

I've been working on converting a CNN written in Lasagne to Keras (link to the Lasagne version: https://github.com/MTG/DeepConvSep/blob/master/examples/dsd100/trainCNN.py) I believe I've got most of it down, however, the loss function is the part…
0
votes
1 answer

Is there any method in tensorflow like get_output in lasagne

I found that it is easy to use lasagne to make a graph like this. import lasagne.layers as L class A: def __init__(self): self.x = L.InputLayer(shape=(None, 3), name='x') self.y = x + 1 def get_y_sym(self, x_var, **kwargs): y =…
Huanyu Liao
  • 137
  • 1
  • 3
0
votes
1 answer

Converting between Keras and Lasagne

I am trying to combine a Keras model with a Lasagne layer. I am calling this function in the Lasagne layer: def get_output_for(self, inputs, deterministic=False): self.p = self.nonlinearity(T.dot(inputs[1], self.pi)) self.mask =…
Alk
  • 5,215
  • 8
  • 47
  • 116
0
votes
1 answer

Is it constant for self.scale variables defined in constructor function?

I don't know the the operating mechanism of lasagne functions. for the code below. class WScaleLayer(lasagne.layers.Layer): def __init__(self, incoming, **kwargs): super(WScaleLayer, self).__init__(incoming, **kwargs) W =…
zhangqianhui
  • 114
  • 1
  • 1
  • 12
0
votes
0 answers

Python randomly crashes when using theano

I am new to python and try to use lasagne and theano to enhance performance of machine learning by computing it on GPU (installed numpy+mlk). I call NeuralNet.fit(X, y) which sometimes proceeds successfully, but sometimes (and more often) crashes…
fairtrax
  • 416
  • 2
  • 8
0
votes
1 answer

How can I print the output of a hidden layer in Lasagne

I am trying to use lasgne to train a simple neural network, and to use my own C++ code to do inference. I use the weights generated by lasgne, but I am not able to get good results. Is there a way I can print the output of a hidden layer and/or the…
amanusk
  • 232
  • 2
  • 5
0
votes
0 answers

Q-Learning Neural Network in Lasagne

I'm just beginning to experiment with neural networks and was hoping to create a neural network capable of learning to play the game Gomoku via q-learning. After reading through some of the Lasagne tutorials and API, I unsure how to proceed with my…
0
votes
1 answer

Translate lasagne neural network in deeplearning4j

I am working on translating a lasagne neural network into deeplearning4j code. So far I've managed to get the layers in place but I am not sure if the other configurations are okay. I am not an expert in neural networks and cannot easily find the…