## Materials and Methods
### Prediction Model Based on LSTM  
Recurrent Neural Network (RNN) methods are a special type of neural network designed for sequence problems. They have been used to create sequential information data for deep learning applications such as object tracking [38], image classification [39], speech recognition [40], and language translation [41]. One of the RNN types is LSTM. LSTM overcomes the limitations of RNN with the lack of full information on how to train the network with backpropagation. It also enables to stop gradients from vanishing or exploding during training. A common LSTM unit shown in Figure 5 is composed of a cell, an input gate, forget gate, and an output gate. The cell remembers values over arbitrary time intervals. The three gates regulate the flow of information into and out of the cell. Figure 4: The proposed framework for data acquisitions and prediction mechanism. The LSTM cell as shown in Figure 6 is composed of inputs, outputs, vector operators, and nonlinearities are responsible for keeping track of the dependencies between the elements in the input sequence. The input gate denoted by it controls the extent to which a new value flows into the cell. The forget gate controls the extent to which a value remains in the cell. The output gate denoted by \(\mathsf{O}_{\text{t}}\) controls the extent to which the value in the cell is used to compute the output activation of the LSTM unit. The candidate gate denoted by \(\tilde{C}_{\text{t}}\) controls what data to write to the cell state. The inputs are of three types. The first is \(\mathsf{C}_{\text{t}-1}\) that indicates memory from the previous/last LSTM unit. The second is \(\mathsf{h}_{\text{t}-1}\) that indicates the output state of the previous/last LSTM unit. The third is \(\mathsf{X}_{\text{t}}\) indicating the current input. The outputs are of two types. The first is \(\mathsf{C}_{\text{t}}\) that indicates new updated memory. The second is \(\mathsf{h}_{\text{t}}\) that indicates the current output state. The vector operations are of two types. The first is \(\mathsf{x}\) indicates the scaling of information while the second \(+\) indicates adding information. The nonlinearities are of two-three types. The first one is the sigmoid layer denoted by \(\sigma\). The second is \(\tanh\) layer is denoted by \(\tanh\). The third is the bias denoted by bi. The activation function of the LSTM gates is often a logistic sigmoid function denoted by \(\sigma\). There are connections into and out of the LSTM gates, a few of which are recurrent. The weights of these connections that need to be learned during the training of the model determine how the four gates inter-operate. Figure 5: Common LSTM unit without details. Figure 6: LSTM cell gate complexity. The first step in LSTM is to decide the information that needs to be discarded away from the cell state. This decision is made by a sigmoid layer called the forget gate layer. It takes h\({}_{t-1}\) and X\({}_{t}\), and outputs a number between 0 and 1 for each number in the cell state C\({}_{t-1}\). Here, 1 represents to keep it while 0 represents to discard it. The next step is to decide the new information to be stored in the cell state. This has two parts. First, a sigmoid layer called the input gate layer decides the values to be updated. Next, a tanh layer creates a vector of new candidate values, C\({}_{t}\), which could be added to the state. The next step is to combine it and C\({}_{t}\) to create an update to the state. The next step is to update the old cell state, C\({}_{t-1}\), into the new cell state C\({}_{t}\). In order to obtain a new cell state C\({}_{t}\), the old state is multiplied by ft, forgetting the things decided to be forgotten earlier. Then add it \(*\) C\({}_{t}\). These are the new candidate values, scaled to update each state value. This output will be based on the cell state but will be a filtered version. The sigmoid layer decides the parts of the cell state to output.