多输入多输出 | MATLAB实现CNN-LSTM-Attention卷积神经网络-长短期记忆网络结合SE注意力机制的多输入多输出预测

多输入多输出 | MATLAB实现CNN-LSTM-Attention卷积神经网络-长短期记忆网络结合SE注意力机制的多输入多输出预测

目录

    • [多输入多输出 | MATLAB实现CNN-LSTM-Attention卷积神经网络-长短期记忆网络结合SE注意力机制的多输入多输出预测](#多输入多输出 | MATLAB实现CNN-LSTM-Attention卷积神经网络-长短期记忆网络结合SE注意力机制的多输入多输出预测)

预测效果




基本介绍

CNN-LSTM-Attention多输入多输出回归预测 基于卷积神经网络-长短期记忆网络结合SE注意力机制的多输入多输出预测 注释清晰 Matlab语言

1.CNN-LSTM-Attention多输出回归预测,多输入多输出 ,LSTM也可以替换成BiLSTM、GRU, matlab需要2020b及以上版本 评价指标包括:R2、MAE、RMSE和MAPE等,效果如图所示,代码质量极高~

2.直接替换数据即可用,适合新手小白~

3.附赠案例数据,如图2所示,实际使用中3个、4个输出均可 直接运行main即可一键出图~

程序设计

  • 完整程序和数据下载方式私信博主回复:CNN-LSTM-Attention卷积神经网络-长短期记忆网络结合SE注意力机制的多输入多输出预测
clike 复制代码
miniBatchSize = 32;

options = trainingOptions("adam", ...
    MaxEpochs=3, ...
    MiniBatchSize=miniBatchSize, ...
    InitialLearnRate=0.005, ...
    LearnRateDropPeriod=2, ...
    LearnRateSchedule="piecewise", ...
    L2Regularization=5e-4, ...
    SequencePaddingDirection="left", ...
    Shuffle="every-epoch", ...
    ValidationFrequency=floor(numel(featuresTrain)/miniBatchSize), ...
    ValidationData={featuresValidation,labelsValidation}, ...
    Verbose=false, ...
    Plots="training-progress");
net = trainNetwork(featuresTrain,labelsTrain,layers,options);    
function features = extractFeatures(X,afe)

features = log(extract(afe,X) + eps);
features = permute(features, [2 3 1]);
features = {features};

end

往期精彩

MATLAB实现RBF径向基神经网络多输入多输出预测
MATLAB实现BP神经网络多输入多输出预测
MATLAB实现DNN神经网络多输入多输出预测

参考资料

1\] https://blog.csdn.net/kjm13182345320/article/details/116377961 \[2\] https://blog.csdn.net/kjm13182345320/article/details/127931217 \[3\] https://blog.csdn.net/kjm13182345320/article/details/127894261

相关推荐
bryant_meng7 天前
【NLP】《The Evolution of NLP: Understanding RNNs, Seq2Seq, and Attention》
人工智能·深度学习·自然语言处理·attention·seq2seq
Sakuraba Ema10 天前
Attention Residuals:把固定残差换成“跨层注意力”
python·llm·attention
被制作时长两年半的个人练习生2 个月前
【FlashAttention】 FA2与FA1算法区别辨析
attention·cuda
机器学习之心3 个月前
BO-CNN-LSTM贝叶斯优化卷积长短期记忆神经网络多输入多输出预测,MATLAB代码
卷积长短期记忆神经网络·贝叶斯优化·多输入多输出预测·bo-cnn-lstm
云雾J视界4 个月前
当算法试图解决一切:技术解决方案主义的诱惑与陷阱
算法·google·bert·transformer·attention·算法治理
Aspect of twilight4 个月前
各种attention的变体:MHA,GQA,MQA,MLA(DeepSeek-V2)详解
人工智能·attention
菠菠萝宝5 个月前
【AI应用探索】-7- LLaMA-Factory微调模型
人工智能·深度学习·大模型·llm·nlp·attention·llama
KIDGINBROOK5 个月前
分布式与长序列attention
attention·cuda
cyyt6 个月前
深度学习周报(9.22~9.28)
深度学习·attention·量子计算
applebomb9 个月前
没合适的组合wheel包,就自行编译flash_attn吧
python·ubuntu·attention·flash