Gas concentration prediction model based on SSA-LSTM
-
摘要: 为了更好地捕捉瓦斯浓度的时变规律及有效信息,实现对采煤工作面瓦斯浓度的精准预测,采用麻雀搜索算法(SSA)优化长短期记忆 (LSTM) 网络,提出了一种基于SSA−LSTM的瓦斯浓度预测模型。采用均值替换法对原始瓦斯浓度时序数据中的缺失数据及异常数据进行处理,再进行归一化和小波阈值降噪;对比测试了SSA与灰狼优化 (GWO) 算法、粒子群优化(PSO)算法的性能差异,验证了SSA在寻优精度、收敛速度和适应能力等方面的优势;利用SSA的自适应性依次对LSTM的学习率、隐藏层节点个数、正则化参数等超参数进行寻优,以此来提高全局寻优能力,避免预测模型陷入局部最优;将得到的最佳超参数组合代入LSTM网络模型中,输出预测结果。将SSA−LSTM与LSTM、GWO−LSTM、PSO−LSTM瓦斯浓度预测模型进行比较,实验结果表明:基于SSA−LSTM的瓦斯浓度预测模型的均方根误差(RMSE)较LSTM,PSO−LSTM,GWO−LSTM分别减少了77.8%,58.9%,69.7%;平均绝对误差(MAE)分别减少了83.9%,37.8%,70%,采用SSA优化的LSTM预测模型相较于传统LSTM模型具有更高的预测精度和鲁棒性。Abstract: In order to better capture the time-varying patterns and effective information of gas concentration, and achieve precise prediction of gas concentration in coal working faces, a gas concentration prediction model based on SSA-LSTM is proposed by optimizing the long short term memory (LSTM) network using sparrow search algorithm (SSA). The model uses the mean replacement method to process missing and abnormal data in the original gas concentration time series data, followed by normalization and wavelet threshold denoising. The performance differences between SSA and grey wolf optimization (GWO) and particle swarm optimization (PSO) algorithms are compared and tested. The result verifies the advantages of SSA in terms of optimization precision, convergence speed, and adaptability. By utilizing the adaptability of SSA, the hyperparameters of LSTM, such as learning rate, number of hidden layer nodes, and regularization parameters, are sequentially optimized to improve the global optimization capability and avoid the prediction model falling into local optimum. The obtained optimal hyperparameter combination is substituted into the LSTM network model and the prediction results are output. Comparing SSA-LSTM with LSTM, GWO-LSTM, and PSO-LSTM gas concentration prediction models, the experimental results show that the root mean square error (RMSE) of the gas concentration prediction model based on SSA-LSTM is reduced by 77.8%, 58.9%, and 69.7% compared to LSTM, PSO-LSTM, and GWO-LSTM, respectively. The mean absolute error (MAE) decreases by 83.9%, 37.8%, and 70%, respectively. The LSTM prediction model optimized by SSA has higher prediction precision and robustness compared to traditional LSTM models.
-
表 1 不同预测模型超参数选择
Table 1. Selection of hyperparameters for different prediction models
模型 学习率 隐藏层节点个数 正则化参数 SSA−LSTM 0.06 40 0.038 3 PSO−LSTM 0.03 60 0.051 2 GWO−LSTM 0.05 80 0.041 6 表 2 不同模型预测结果评价
Table 2. Evaluation of prediction results of different models
模型 MAE RMSE $ {R}^{2} $ 运行时间/s LSTM 0.011 35 0.011 7 0.577 6 45 PSO−LSTM 0.002 93 0.004 8 0.908 9 50 SSA−LSTM 0.001 82 0.002 6 0.962 5 47 GWO−LSTM 0.006 15 0.008 6 0.780 3 49 -
[1] 王双明. 对我国煤炭主体能源地位与绿色开采的思考[J]. 中国煤炭,2020,46(2):11-16.WANG Shuangming. Thoughts about the main energy status of coal and green mining in China[J]. China Coal,2020,46(2):11-16. [2] 付华,代巍. 基于ACPSO的PSR−MK−LSSVM瓦斯浓度动态预测方法[J]. 传感技术学报,2016,29(6):903-908. doi: 10.3969/j.issn.1004-1699.2016.06.019FU Hua,DAI Wei. Gas concentration dynamic prediction method of mixtures kernels LSSVM based on ACPSO and PSR[J]. Chinese Journal of Sensors and Actuators,2016,29(6):903-908. doi: 10.3969/j.issn.1004-1699.2016.06.019 [3] 钱建生,邱春荣,李紫阳,等. 深度学习耦合粒子群优化SVM的瓦斯浓度预测[J]. 煤矿安全,2016,47(11):173-176.QIAN Jiansheng,QIU Chunrong,LI Ziyang,et al. Gas emission quantity prediction based on particle swarm optimization of SVM and deep learning network[J]. Safety in Coal Mines,2016,47(11):173-176. [4] 吴海波,施式亮,念其锋. 基于Isomap+SVR的瓦斯浓度预测方法[J]. 矿业工程研究,2019,34(2):51-54.WU Haibo,SHI Shiliang,NIAN Qifeng. Prediction of gas concentration based on Isomap and SVR[J]. Mineral Engineering Research,2019,34(2):51-54. [5] 李欢,贾佳,杨秀宇,等. 煤矿综采工作面瓦斯浓度预测模型[J]. 工矿自动化,2018,44(12):48-53.LI Huan,JIA Jia,YANG Xiuyu,et al. Gas concentration prediction model for fully mechanized coal mining face[J]. Industry and Mine Automation,2018,44(12):48-53. [6] 王鹏,伍永平,王栓林,等. 矿井瓦斯浓度Lagrange−ARIMA实时预测模型研究[J]. 煤炭科学技术,2019,47(4):141-146.WANG Peng,WU Yongping,WANG Shuanlin,et al. Study on Lagrange-ARIMA real-time prediction model of mine gas concentration[J]. Coal Science and Technology,2019,47(4):141-146. [7] 张震,朱权洁,李青松,等. 基于Python的瓦斯浓度ARIMA预测模型构建及其应用[J]. 华北科技学院学报,2020,17(2):23-28,49. doi: 10.3969/j.issn.1672-7169.2020.02.004ZHANG Zhen,ZHU Quanjie,LI Qingsong,et al. Construction and application of ARIMA prediction model of gas concentration based on Python[J]. Journal of North China Institute of Science and Technology,2020,17(2):23-28,49. doi: 10.3969/j.issn.1672-7169.2020.02.004 [8] 王怀远,张保会,杨松浩,等. 电力系统暂态稳定切机控制策略表的快速整定方法[J]. 电力系统自动化,2016,40(11):68-72,79. doi: 10.7500/AEPS20150921009WANG Huaiyuan,ZHANG Baohui,YANG Songhao,et al. Fast setting method of generator tripping strategy tables in transient stability control of power systems[J]. Automation of Electric Power Systems,2016,40(11):68-72,79. doi: 10.7500/AEPS20150921009 [9] 郭星燃,李娟莉,苗栋,等. 基于LSTM−Adam的矿井提升机故障预警模型[J]. 机电工程,2024,41(1):175-182.GUO Xingran,LI Juanli,MIAO Dong,et al. A fault early warning model of mine hoist based on LSTM-Adam[J]. Journal of Mechanical & Electrical Engineering,2024,41(1):175-182. [10] 周浩杰,杨建卫,王尊,等. 基于LSTM光伏发电功率超短期预测模型研究[J]. 电源技术,2023,47(6):785-789. doi: 10.3969/j.issn.1002-087X.2023.06.021ZHOU Haojie,YANG Jianwei,WANG Zun,et al. Research on ultra-short term prediction model of photovoltaic power generation based on LSTM[J]. Chinese Journal of Power Sources,2023,47(6):785-789. doi: 10.3969/j.issn.1002-087X.2023.06.021 [11] 余琼芳,王联港,杨艺. 基于LSTM−TCN的综采工作面顶板压力预测[J]. 煤炭技术,2023,42(6):5-9.YU Qiongfang,WANG Liangang,YANG Yi. Pressure prediction of top plate of comprehensive mining working face based on LSTM-TCN[J]. Coal Technology,2023,42(6):5-9. [12] 谭美芳,匡锐,张清勇,等. 基于改进灰狼算法优化LSTM的断面交通流预测[J]. 武汉理工大学学报,2023,45(5):132-139. doi: 10.3963/j.issn.1671-4431.2023.05.019TAN Meifang,KUANG Rui,ZHANG Qingyong,et al. LSTM for cross-sectional traffic flow prediction based on improved grey wolf optimizer algorithm[J]. Journal of Wuhan University of Technology,2023,45(5):132-139. doi: 10.3963/j.issn.1671-4431.2023.05.019 [13] 吴家葆,曾国辉,张振华,等. 基于K−means分层聚类的TCN−GRU和LSTM动态组合光伏短期功率预测[J]. 可再生能源,2023,41(8):1015-1022. doi: 10.3969/j.issn.1671-5292.2023.08.004WU Jiabao,ZENG Guohui,ZHANG Zhenhua,et al. Dynamic combination of TCN−GRU and LSTM photovoltaic short-term power prediction based on K-means hierarchical clustering[J]. Renewable Energy Resources,2023,41(8):1015-1022. doi: 10.3969/j.issn.1671-5292.2023.08.004 [14] 杨雨佳,肖庆来,陈健,等. 融合空间和统计特征的CNN−GRU臭氧浓度预测模型研究[J]. 南京大学学报(自然科学),2023,59(2):322-332.YANG Yujia,XIAO Qinglai,CHEN Jian,et al. Research on CNN-GRU ozone prediction considering spatial features and statistical features[J]. Journal of Nanjing University(Natural Science),2023,59(2):322-332. [15] 王雨虹,王淑月,王志中,等. 基于改进蝗虫算法优化长短时记忆神经网络的多参数瓦斯浓度预测模型研究[J]. 传感技术学报,2021,34(9):1196-1203. doi: 10.3969/j.issn.1004-1699.2021.09.009WANG Yuhong,WANG Shuyue,WANG Zhizhong,et al. Multi-parameter gas concentration prediction model based on improved locust algorithm to optimize long and short time memory neural network[J]. Chinese Journal of Sensors and Actuators,2021,34(9):1196-1203. doi: 10.3969/j.issn.1004-1699.2021.09.009 [16] 王德忠,朱国宏,王禹,等. 基于GA−LSTM的综采面瓦斯浓度预测模型[J]. 煤炭技术,2023,42(1):219-221.WANG Dezhong,ZHU Guohong,WANG Yu,et al. Prediction model of gas concentration in fully mechanized mining face based on GA-LSTM[J]. Coal Technology,2023,42(1):219-221. [17] 郝可青,吕志刚,邸若海,等. 基于鲸鱼算法优化长短时记忆神经网络的锂电池剩余寿命预测[J]. 科学技术与工程,2022,22(29):12900-12908. doi: 10.3969/j.issn.1671-1815.2022.29.025HAO Keqing,LYU Zhigang,DI Ruohai,et al. Remaining useful life prediction of lithium battery based on long short-term memory optimized by whale optimization algorithm[J]. Science Technology and Engineering,2022,22(29):12900-12908. doi: 10.3969/j.issn.1671-1815.2022.29.025 [18] 王冰,尚亚强,严一踔,等. 基于麻雀搜索算法的橡胶复合挤出机温度压力解耦控制[J]. 大众科技,2022,24(7):9-13. doi: 10.3969/j.issn.1008-1151.2022.07.003WANG Bing,SHANG Yaqiang,YAN Yichuo,et al. Temperature and pressure decoupling control of rubber composite extruder based on sparrow search algorithm[J]. Popular Science & Technology,2022,24(7):9-13. doi: 10.3969/j.issn.1008-1151.2022.07.003 [19] 祖林禄,柳平增,赵妍平,等. 基于SSA−LSTM的日光温室环境预测模型研究[J]. 农业机械学报,2023,54(2):351-358. doi: 10.6041/j.issn.1000-1298.2023.02.036ZU Linlu,LIU Pingzeng,ZHAO Yanping,et al. Solar greenhouse environment prediction model based on SSA-LSTM[J]. Transactions of the Chinese Society for Agricultural Machinery,2023,54(2):351-358. doi: 10.6041/j.issn.1000-1298.2023.02.036 [20] 冷丽英,付建哲,宁波. 基于SSA−LSTM模型的IGBT时间序列预测研究[J]. 半导体技术,2023,48(1):66-72.LENG Liying,FU Jianzhe,NING Bo. Research on IGBT sequentially prediction based on SSA-LSTM model[J]. Semiconductor Technology,2023,48(1):66-72. [21] 刘栋,梅雪松,冯斌,等. 基于Symlets小波滤波的滚珠丝杠伺服进给系统频响特性辨识[J]. 机械工程学报,2011,47(13):153-159. doi: 10.3901/JME.2011.13.153LIU Dong,MEI Xuesong,FENG Bin,et al. Frequency response identification for ballscrew servo driven system based on Symlets wavelet[J]. Journal of Mechanical Engineering,2011,47(13):153-159. doi: 10.3901/JME.2011.13.153 [22] 张会峰,张德正,程卫健,等. 基于小波滤波和SVPWM的矿用APF研究[J]. 煤矿机械,2023,44(9):198-200.ZHANG Huifeng,ZHANG Dezheng,CHENG Weijian,et al. Research on mining APF based on wavelet filtering and SVPWM[J]. Coal Mine Machinery,2023,44(9):198-200. [23] 陈俊,余雷. 基于小波分解切换规则的交互系统切换滤波方法[J]. 电工技术,2022(13):31-34,97.CHEN Jun,YU Lei. A switching filtering method for interactive systems based on wavelet decomposition switching rules[J]. Electric Engineering,2022(13):31-34,97. -