# Internal Flow Prediction in Arbitrary Shaped Channel Using Stream-Wise Bidirectional LSTM
## 5 Conclusions  
This study was designed to determine whether the encoder-decoder or the U-Net structure, used for flow prediction, provides fast and acceptable results in learning internal flows compared to the existing CFD under various conditions. To this end, instead of generating arbitrary shapes between unchanged parallel walls, as in the existing method, we experimented with shapes created by simply joining serial pipes and CFD data corresponding to these shapes.  
The existing neural networks exhibit problems in predicting flows from various patterns of shapes with different flow rates generated through the above method. To solve this problem, we proposed adding a module to the existing bottleneck part, to increase the learning capability through a spatial recurrent neural network that goes beyond the receptive field of the existing structure to capture information in the surrounding area, thereby solving the problems of the existing network, such as discontinuity in predicted values. When calculating the mean relative error in the region of interest, there was a decrease of at least 2.7% in the x-component of velocity, 4.7% in the y-component of velocity, and 15% in pressure, both in the overall area and the vortex corner region. Similarly, when comparing the computational time with the CFD method and the baseline model, this method was effective in terms of computational time.  
During this research, the following shortcomings were discovered. In addition to evaluating the x-velocity and y-velocity used in the experiment as independent indicators, monitoring was also conducted on the direction created by both features. However, the directional plot did not align smoothly along the streamline; rather, it slightly jumped out like noise compared to the actual data flow. As a result, it seems necessary to conduct further research to force the interdependence between velocity fields, in addition to independently adjusting each data value.  
Regarding follow-up studies, the dataset used in this work had a constant to fixed boundary condition. Therefore, follow-up flow prediction studies can add boundary condition information to the initial state of LSTM to study the effect of various boundary conditions. Additionally, flow prediction studies can be conducted for pipe shapes with a non-fixed domain size, taking advantage of the strengths of LSTM in language modeling.  
Conceptualization, J.K. and W.C.; methodology, J.K. and W.C.; software, J.K. and W.C.; validation, J.K. and W.C.; formal analysis, J.K. and W.C.; investigation, J.K. and W.C.; resources, J.K. and W.C.; data curation, J.K. and W.C.; writing--original draft preparation, J.K. and W.C.; writing--review and editing, J.K., W.C. and S.L.; visualization, J.K. and W.C.; supervision, S.L.; project administration, S.L. All authors have read and agreed to the published version of the manuscript.  
This research received no external funding.  
Not applicable.  
This section demonstrates that the SB-LSTM module does not interfere with the characteristics of existing models. To visualize the differences in the results of models with SB-LSTM attached, the same procedure as in Section 4.2 was used to plot the two models,with the ground truth as a reference. The absolute error is also plotted below to visually confirm the points where there are differences.  
Figure 14: Qualitative results of four different methods. From top to bottom: \(u\), \(v\), \(P\). From left to right: (**a**) ED with SB-LSTM, (**b**) U-Net with SB-LSTM, (**c**) ground truth, (**d**) absolute error of ED with SB-LSTM, (**e**) absolute error of U-Net with SB-LSTM.  
We comprehensively evaluated the error plots of the cases visualized above, and we observed that the overall error value was lower in models with skip connections, and the errors occurring at the channel boundaries also decreased. This is the same as the difference shown in learning between the U-Net structure and the ED structure in [27].