Machine Learning
Currency (FX) prediction using RNN [In the previous article, I tried to predict the stock price, so I will try to predict the forex market. As with stock prices, there are a variety of factors that can cause fluctuations, so it will be difficult to make a prediction using only a neural network model, but I’ll try it as an exercise in Keras.
github The file in jupyter notebook format is here google colaboratory If you want to run it in google colaboratory here Author’s environment The author’s OS is macOS, and the options are different from Linux and Unix commands.
…
Stock prediction using RNN, LSTM RNN and LSTM are used for forecasting time series data. There are many kinds of time series data, such as temperature of a certain place, number of visitors, price of a product, etc. However, I would like to use RNN and LSTM to predict the stock price, which is the easiest data to obtain.
However, neural nets can only make predictions within the scope of the data obtained, and the model is almost useless when the situation is unexpected.
…
keras and sequnece to sequence In the previous article, we implemented the LSTM model, and now we will implement the sequence to sequence model. Nowadays, the sequnece to sequence and attention-based models are often used in natural language processing such as machine translation, and BERT is also based on the attention model.
In this section, we will review and implement the basic sequnece to sequence. We will build a model that translates $y=\sin x$ to $y=\cos x$.
…
Basics of keras and GRU, Comparison with LSTM GRU is a model designed to compensate for the high number of parameters in LSTM, i.e., its high computational cost. It combines the operations of memory updating and memory forgetting into a single operation, thereby reducing the computational cost. I’ll spare you the details, as you can find plenty of them by searching. Here is a comparison between GRU and LSTM.
github The file in jupyter notebook format is here google colaboratory If you want to run it in google colaboratory here Author’s environment The author’s OS is macOS, and the options are different from Linux and Unix commands.
…
Basics of keras and LSTM, Comparison with RNN LSTM stands for Long Short Term Memory, and is said to be able to learn long-term dependencies. LSTM is a type of RNN, and the basic idea is the same. I’m not going to go into the details, because you can find plenty of them by searching.
Also, here is a comparison between LSTM and RNN.
github The file in jupyter notebook format is here google colaboratory If you want to run it in google colaboratory here Author’s environment The author’s OS is macOS, and the options are different from Linux and Unix commands.
…
Basics of keras and RNN As a review, I will try to implement a Recurrent Neural Network (RNN) using keras. I think anything is fine, but I’ll prepare a damped oscillation curve as time series data, and try to train it using RNN.
github The file in jupyter notebook format is here google colaboratory If you want to run it in google colaboratory here Author’s environment The author’s OS is macOS, and the options are different from Linux and Unix commands.
…