August 2024
Intermediate to advanced
374 pages
8h 44m
English
Recall from Chapter 9, Understand Text, the reason recurrent neural networks are so powerful with text is they model temporal dependencies. The same assumptions built into RNNs that make them good for text also make them good for time-series data. In a time-series dataset, inputs at time t - 1 obviously have an impact on inputs at time t. Recurrent neural networks are quite good at capturing what the relationship is between timesteps.
You should have some familiarity with implementing recurrent neural networks in Axon from the previous chapter. You can start by creating a new recurrent model, like this:
| | rnn_model = |
| | Axon.input("stock_prices") |
| | |> Axon.lstm(32) |
| | |> elem(0) |
| | |> Axon.nx(& &1[[0..-1//1, ... |
Read now
Unlock full access