Questions tagged [theano]

Theano is a numerical computation library for Python. Computations are expressed using a Numpy-like syntax and compiled to run efficiently on either CPU or GPU architectures. Theano uses a mathematical computational graph and optimized the graph to speed up the computations using optimized C code. As of release 1.0, Theano will no longer be actively developed.

Theano is a Python library for performing tensor calculations with a -like syntax. Theano can be used to define, optimize, and evaluate mathematical expressions involving tensors (also see ). Some of the principal features of Theano that set it apart from other libraries have become commonplace in neural network and tensor math libraries:

  • Integrates with Numpy and provides Numpy-like syntax to express models using mathematical syntax
  • Represents calculations as computation graphs and optimizes graphs for better performance and memory utilization
  • Utilizes GPU hardware for data-intensive calculations
  • Performs high-order differentiation automatically (symbolically)
  • Compiles computation graphs into C code for faster execution

Theano enables rapid building of large-scale computational codes with less cognitive overhead and more expressive syntax. However, it is easy enough to learn that it is used in several deep learning courses (including at the University of Montreal, where it was originally developed).

Several projects build on top of Theano, including and .

As of Theano 1.0, Theano will no longer be under active development. See announcement on mailing list.

Resources

Trivia

Theano is named after a high priestess of Athena in the city of Troy, from Homer's Iliad.

2447 questions
1
vote
1 answer

Error when importing theano using GPU

I am trying to use theano for python 2.7 installed through anaconda on a CentOS 5.6. I am able to import theano if only using cpu, but when I try to run it using gpu I get hte error: >>> import theano Using gpu device 0: Tesla K20m Traceback (most…
Leonardo Neves
  • 133
  • 1
  • 10
1
vote
1 answer

Bayesian Lifetime estimates using pymc3/theano

I am trying to estimate the following model where I provide uniform priors and I code the likelihood . The latter comes from this paper and goes as follows: In the theano/pymc3 implementation I am computing the first and second term on the rhs…
cadama
  • 359
  • 4
  • 13
1
vote
1 answer

Trying to install Theano but don't have an Nvidia card

I am following: http://deeplearning.net/software/theano/install_windows.html#install-windows to install theano. I just want to play with the code, I don't need to use a GPU to improve my speed. I don't have an Nvidia card and when I try to install…
Jacob Rael
  • 23
  • 5
1
vote
1 answer

How to get a theano function to return the an array of the same length as another tensor variable

I am really new to Theano, and I am just trying to figure out some basic functionality. I have a tensor variable x, and i would like the functio to return a tensor variable y of the same shape, but filled with value 0.2. I am not sure how to define…
RKM
  • 3,151
  • 9
  • 37
  • 50
1
vote
2 answers

Theano on a GPU: configuration on 64-bit Windows 7

I'm running Python 2.7 (Anaconda distribution) on a 64-bit Windows 7 workstation, and I'm trying to get Theano (v0.7.0) to run on an NVIDIA Quadro 2000 GPU for a machine learning application. Here's where I'm up to: I've installed CUDA v6.5 and…
SWS
  • 115
  • 1
  • 9
1
vote
1 answer

Is there an error in the way the params are updated in the following Theano method?

I was going through a tutorial online for momentum based learning and came across this method in Theano def gradient_updates_momentum(cost, params, learning_rate, momentum): ''' Compute updates for gradient descent with momentum :parameters: …
London guy
  • 27,522
  • 44
  • 121
  • 179
1
vote
1 answer

Scanning without sequences in theano? (emulating range())

Theano newbie here. I am doing some experiments in order to generate variable length sequences. I started with the simplest thing coming to my mind: emulating range(). Here is the simple code I wrote: from theano import scan from theano import…
petrux
  • 1,743
  • 1
  • 17
  • 30
1
vote
1 answer

RNN with dynamic inputs at each time step in Theano

I was wondering if it was possible to implement a recurrent network in Theano in the case where inputs are not known initially. Specifically, I have in mind the 'Recurrent Models of Visual Attention' paper (http://arxiv.org/abs/1406.6247) and the…
1
vote
1 answer

Extraction of neural network activation values from Python Theano+Keras

Say I have simple MLP network for 2 class problem: model = Sequential() model.add(Dense(2, 10, init='uniform')) model.add(Activation('tanh')) model.add(Dense(10, 10, init='uniform')) model.add(Activation('tanh')) model.add(Dense(10, 2,…
1
vote
0 answers

Cannot find -lInclude on server side

After I installed the Theano and genesim by pip install xxx --user on server side, I tried to import them in python code, but I had this error: Exception: Compilation failed (return status=1): /usr/bin/ld: cannot find -lInclude. collect2: ld…
Kun
  • 581
  • 1
  • 5
  • 27
1
vote
1 answer

Clip parts of a tensor

I have a theano tensor and I would like to clip its values, but each index to a different range. For example, if I have a vector [a,b,c] , I want to clip a to [0,1] , clip b to [2,3] and c to [3,5]. How can I do that efficiently? Thanks!
Ran
  • 4,117
  • 4
  • 44
  • 70
1
vote
1 answer

Python theano: how does the R-operation work?

I am executing the following on theano: >>> import theano >>> import theano.tensor as T >>> x = T.dvector('x') >>> y = T.dvector('y') >>> f = T.dot(x,y) >>> Jy= T.Rop(f,x,y) >>> fun = theano.function([x,y],Jy) >>>…
Cantfindname
  • 2,008
  • 1
  • 17
  • 30
1
vote
1 answer

Can pylearn2 and Theano run on AMD GPU based platform?

I'd like to use pylearn2, theano and scikit-neuralnetwork to build neural network models. But my friend told me that all this module can only run on NVIDIA GPU based platform (because they would import the pycuda module). But I only have an AMD…
peter
  • 71
  • 1
  • 12
1
vote
1 answer

Convolutional Net With Lasange - image resizing

I've been training some neural and convolutional nets with Lasagne and was doing most of my data/image preprocessing using Python. However I would like to incorporate some of this into my Lasagne layers to make my code more flexible. Is there a…
mjacuse
  • 79
  • 1
  • 5
1
vote
1 answer

Is it normal that memory usage is fluctuating in Theano?

I started to use Theano library, because I am seek of compile & debugging with C++ with caffe ( though, it was a really great library :) ) Anyway, I made deep network(almost like CNN), with lasagne, and I started learning my network. However, my…
nine
  • 75
  • 2
  • 6
1 2 3
99
100