O'Reilly logo

Deep Learning with PyTorch by Vishnu Subramanian

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Understanding how RNN works with an example 

Let's start with an assumption that we have an RNN model already built, and try to understand what functionality it provides. Once we understand what an RNN does, then let's explore what happens inside an RNN.

Let's consider the Thor review as input to the RNN model. The example text we are looking at is the action scenes were top notch in this movie.... . We first start by passing the first word, the, to our model; the model generates two different things, a State Vector and an Output vector. The state vector is passed to the model when it processes the next word in the review, and a new state vector is generated. We just consider the Output of the model generated during the last sequence. The ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required