👨🎓个人主页
💥💥💞💞欢迎来到本博客❤️❤️💥💥
🏆博主优势:🌞🌞🌞博客内容尽量做到思维缜密,逻辑清晰,为了方便读者。
⛳️座右铭:行百里者,半于九十。
本文包括以下5个部分
编辑
模型构建:
编辑
训练出模型,然后就可以预测任意一天的96个时刻点的负荷。
短期负荷预测(STLF)指预测未来数小时至数周的电力需求,是电力系统调度、经济运行与安全控制的核心基础。精准预测可降低备用容量成本(文献显示误差减少1%可节省上亿元成本),支撑新能源消纳与多能源协调。
| 类型 | 代表模型 | 特点与局限 |
|---|---|---|
| 传统统计模型 | ||
| 机器学习模型 | ||
| 深度学习模型 | LSTM/GRU | |
| 混合优化模型 |
| 数据类型 | 具体内容 | 来源 |
|---|---|---|
VMD-SHO-LSTM模型(某市级电网)
联邦学习多区域预测(省级电网)
改进BP神经网络(夏季高峰场景)
| 因素 | 挑战 | 解决策略 |
|---|---|---|
| 负荷波动性 | ||
| 数据质量 | ||
| 多能源耦合 | ||
| 特殊事件 |
结论:短期负荷预测正向深度学习主导、多技术融合、隐私保护强化方向发展。混合模型(如VMD优化LSTM)和联邦学习成为解决数据波动性与隐私矛盾的有效路径,而气象敏感性特征工程与评估指标标准化是提升工业应用可靠性的关键。随着新型电力系统建设,高精度预测将成为支撑"双碳"目标的核心技术引擎。
编辑
编辑
编辑
编辑
编辑 预测日:
编辑
部分代码:
max_tempe = df_weather.loc[(df_weather[0] == predict_date) & (df_weather[1] == '最高温度'), [2]].values / 20 min_tempe = df_weather.loc[(df_weather[0] == predict_date) & (df_weather[1] == '最低温度'), [2]].values / 20 avg_tempe = df_weather.loc[(df_weather[0] == predict_date) & (df_weather[1] == '平均温度'), [2]].values / 20 humidity = df_weather.loc[(df_weather[0] == predict_date) & (df_weather[1] == '湿度'), [2]].values / 100 weather_data = np.concatenate([max_tempe, min_tempe, avg_tempe, humidity]).reshape((1, -1)) type_of_day = np.eye(7)[date.dayofweek] holiday = np.eye(2)[int(is_holiday(date))] time_data = np.concatenate([type_of_day, holiday]).reshape((1, -1)) features = np.concatenate([load_data, weather_data, time_data], axis=1).reshape(1, 685) features = Tensor(features) print('Loading model...') net = load('./model.pt', map_location='cpu') print('Start predicting...') net.eval() labels = net(features).detach().numpy() * 7000 print('=========预测==============')max_tempe = df_weather.loc[(df_weather[0] == predict_date) & (df_weather[1] == '最高温度'), [2]].values / 20 min_tempe = df_weather.loc[(df_weather[0] == predict_date) & (df_weather[1] == '最低温度'), [2]].values / 20 avg_tempe = df_weather.loc[(df_weather[0] == predict_date) & (df_weather[1] == '平均温度'), [2]].values / 20 humidity = df_weather.loc[(df_weather[0] == predict_date) & (df_weather[1] == '湿度'), [2]].values / 100 weather_data = np.concatenate([max_tempe, min_tempe, avg_tempe, humidity]).reshape((1, -1)) type_of_day = np.eye(7)[date.dayofweek] holiday = np.eye(2)[int(is_holiday(date))] time_data = np.concatenate([type_of_day, holiday]).reshape((1, -1)) features = np.concatenate([load_data, weather_data, time_data], axis=1).reshape(1, 685) features = Tensor(features) print('Loading model...') net = load('./model.pt', map_location='cpu') print('Start predicting...') net.eval() labels = net(features).detach().numpy() * 7000 print('=========预测==============')部分理论来源于网络,如有侵权请联系删除。
[1]陆继翔,张琪培,杨志宏,涂孟夫,陆进军,彭晖.基于CNN-LSTM混合神经网络模型的短期负荷预测方法[J].电力系统自动化,2019,43(08):131-137.
[2]罗澍忻,陆秋瑜,靳冰洁,麻敏华.考虑相关因素的长短时记忆网络短期负荷预测方法[J].机电工程技术,2019,48(12):126-129.
[3]王增平,赵兵,纪维佳,高欣,李晓兵.基于GRU-NN模型的短期负荷预测方法[J].电力系统自动化,2019,43(05):53-62.
[4] 牛腾腾.电力系统短期负荷预测 2017,01104
公众号后台回复:程序下载