## 3 The Proposed Model
### Design of CNN-ABLSTM-Based Predictive Model  
For the effective prediction of ECM in smart cities, the pre-processed data was passed into the CNN-ABLSTM model. The CNN had pooling, convolution, and fully connected (FC) layers. The CNN captured hidden features in the input data by implementing convolution as well as pooling functions. Afterward, the extracting features were combined and fed into the FC layer. Lastly, several activation functions were employed for introducing non-linearity to the resultant neurons. The convolutional layer was a vital part of the CNN. All the convolution layers maintained several convolution kernels that were convolved with the input data to capture hidden features and develop feature maps. The feature map endured a nonlinear activation function for generating the results of the convolution layer. The convolution layer is formulated as:  
\[c_{i}=f(w_{i}*x_{i}+b_{i}) \tag{1}\]  
where \(x_{i}\) signifies the input of the convolutional layer, \(c_{i}\) represents the \(i^{th}\) resultant feature map, \(w_{i}\) denotes the weighted matrix, \({}^{\prime}t\) implies the dot products, \(b_{i}\) represents the bias vector, and \(f(\cdot)\) stands for the activation function. The ReLU function has been widely selected as the activation function of CNNs. In the mathematical process, ReLU is determined as:  
\[c_{i}=f(h_{i})=\text{ max }(0,\,h_{i}) \tag{2}\]  
where \(h_{i}\) denotes the element of feature maps attained in the convolution functions. Max pooling is the most utilized pooling approach. It can be understood by computing the maximal value of the allocated region from the feature maps based on Equations (3) and (4):  
\[\gamma(c_{i},\,c_{i-1})=\text{ max }(c_{i},\,c_{i-1}) \tag{3}\]  
\[p_{i}=\gamma(c_{i},\,c_{i-1})+\beta_{i} \tag{4}\]  
where \(\gamma(\cdot)\) signifies the max-pooling sub-sampling function, \(\beta_{i}\) indicates the bias, and \(p_{i}\) stands for the result of the max-pooling layer. Lastly, the feature maps attained with convolution and pooling functions were fed into the FC layer; then, the layer computed the last resultant vector, as demonstrated under:  
\[y_{j}=f(t_{i}p_{i}+\delta_{i}) \tag{5}\]where \(y_{i}\) denotes the last resultant vector, \(\delta_{i}\) represents the bias, and \(r_{i}\) implies the weighted matrix. The proposed architecture is a structure of two branches. One branch used a CNN to capture the spatial properties of the data, and the other conducted the feature selections by utilizing a two-layer BiLSTM model with an attention mechanism. LSTM NNs are variants of RNNs and solve the gradient vanishing problems of RNNs. LSTM adds a memory cell structure from the neural node of the hidden state of RNNs for storing the previous data and adds a three-gate infrastructure: forget, output, and input gates, to control the utilization of the previous data. By forgetting the unused data and memorizing the original data from the cell state, LSTM transfers valuable data from the subsequent computation time [21]. The computation equation is shown in the subsequent formulae:  
\[i_{\tau}=o(W_{i}\cdot[h_{\tau-12}x_{\tau}]+b_{i}) \tag{6}\]  
\[f_{T}=o\Big{(}W_{f}\cdot[h_{\tau-12}x_{\tau}]+b_{f}\Big{)} \tag{7}\]  
\[o_{\tau}=o(W_{o}\cdot[h_{\tau-12}x_{\tau}]+b_{o}) \tag{8}\]  
\[h_{\tau}=0_{\tau}\odot tanh(c_{\tau}) \tag{9}\]  
\[c_{\tau}=f_{T}\odot c_{t-1}+i_{t}\odot\widetilde{c} \tag{10}\]  
\[c_{i}=f(h_{i})=\text{ max }(0,\,h_{i}) \tag{2}\]0  
\[c_{i}=f(h_{i})=\text{ max }(0,\,h_{i}) \tag{2}\]1  
\[c_{i}=f(h_{i})=\text{ max }(0,\,h_{i}) \tag{2}\]2  
where \(\widetilde{c_{t}}\) refers to the temporary state and \(c_{t}\) denotes the present state. \(i_{t}\), \(f_{t}\), and \(0_{t}\) signify output, input, and forget gates, respectively, \(x_{\tau}\) signifies the present input, and \(h_{\tau-1}\) denotes the hidden state of the earlier time. \(W_{i}\), \(W_{f}\), and \(W_{o}\) characterize the connection weight of the three gates, \(b\) specifies the offset, and \(\sigma\) and \(\tan\) h symbolize the activation functions.