Giter VIP home page Giter VIP logo

Comments (5)

ScottMackay2 avatar ScottMackay2 commented on July 22, 2024 2

As far as I can see, he choose for 100 hidden cells because that is the double of the randomly chosen 50 input cells.

Choosing the amount of hidden cells could be a bit of a guessing game. Trying different numbers to see what works best. This is the case for most neural networks (as far as I know of, all of them)

There are tricks that makes the guessing simpler. Like, making the hidden layer use twice as much cells as input cells (as in this example). Or choosing the average of the input + output cells. I for example tested it with 26 ((50inputs + 1output) / 2) hidden cells. And that resulted in about the same loss.

But there are also networks that try to find the amount of hidden cells for them self. More explanation can be found in this thread: http://stackoverflow.com/questions/3345079/estimating-the-number-of-neurons-and-number-of-layers-of-an-artificial-neural-ne

About LSTM nodes. They seem to me that their only use is to remember the input at a certain time step and couple that with the states of all cells of the LstmState object. This way the back propagation could work. (you need the input values times the difference to find the error of the weights). Summary in the program: LstmNode is used to couple self.state (all the values in all the cells) with self.xc (the input).

from lstm.

xiaohu2015 avatar xiaohu2015 commented on July 22, 2024

In fact, the project only uses one memory cell, which has big difference from LSTM node. The memory cell in this work really means the hidden size of the cell.

from lstm.

zackchase avatar zackchase commented on July 22, 2024

from lstm.

xiaohu2015 avatar xiaohu2015 commented on July 22, 2024

I think the notation in the literature is not consistent. I refer to https://arxiv.org/abs/1506.00019

from lstm.

jsbhat avatar jsbhat commented on July 22, 2024

@zackchase As far I understood, the terminology can be confusing.
However, what @ScottMackay2 writes makes sense to me from the code and implementation point of view of unrolling the LSTM network.

In lstm.py, LSTM nodes refer to the repeating (same weight parameters, varying cell states) hidden layer of memory cells in the unrolled network. In example_0, the number of nodes is set programmatically to the maximum number (n=4) of time steps of the random 50 dimensional input sequence.

from lstm.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.