核心内容摘要
3分钟让PPT在网页重生:献给设计师的转换神器
✅作者简介热爱科研的Matlab仿真开发者擅长毕业设计辅导、数学建模、数据处理、建模仿真、程序设计、完整代码获取、论文复现及科研仿真。
往期回顾关注个人主页Matlab科研工作室 关注我领取海量matlab电子书和数学建模资料个人信条格物致知,完整Matlab代码获取及仿真咨询内容私信。
内容介绍
DWVD介绍DWVD离散韦格纳分布英文全称为Discrete Wigner-Ville Distribution简称DWVD作为轴承故障诊断领域中一种基于信号能量分布的先进时频分析方法展现出独特的优势。
它通过深入计算信号自身时频相干性能够巧妙地生成一张能量高度聚集的时频分布图。
对于轴承局部损伤例如点蚀、裂纹等所激发的瞬态冲击响应DWVD具备非凡的表现能力该方法不仅能凭借极高的时频分辨率精准定位每一个故障冲击的发生时刻与持续时间还能清晰揭示冲击能量集中的共振频带及其调制边带结构在时频面上形成连续、尖锐的时频脊线。
这种优异的时频凝聚特性让DWVD对微弱故障极为敏感能够有效凸显被强噪声所掩盖的早期故障特征。
此外由于DWVD采用无窗设计避免了短时傅里叶变换中时间分辨率与频率分辨率的权衡限制从而提供了更为真实和细致的信号能量演化视图。
这些显著特点使得DWVD非常适用于复杂工况下的轴承故障精密诊断不仅能有效识别外圈、内圈、滚动体等元件的特征故障频率还能进一步深入揭示调制现象中的频率成分以及冲击信号的传播特性为故障类型的判定、损伤程度的评估以及故障演化趋势的预测提供丰富、可靠的时频特征依据。
本期中展示的是使用DWVD变换对凯斯西储大学轴承故障数据CWRU进行分析诊断的成果相关图示如下。
版本及示范数据本次分析所使用的软件版本为matlab2024a及以上本代码采用的是24a版本示范数据选取的是CWRU凯斯西储大学的10种轴承故障数据这些数据为故障诊断研究提供了丰富且具有代表性的样本。
重磅发布先用先发提出一种创新的改进多尺度卷积神经网络模型DVMBiGRU即DWVD-MCNN-BiGRU时频变换改进多尺度卷积网络是当下发文热点。
该模型融合了“离散韦格纳分布(Discrete Wigner-Ville DistributionDWVD)、多尺度卷积神经网络MCNN以及双向门控循环网络BiGRU”的优势形成一种全新的轴承故障诊断方法。
其中多尺度卷积神经网络MCNN作为CNN的变体拥有比传统CNN更加强大的特征提取能力能够更好地捕捉数据中的复杂特征。
当前网络模型DVMBiGRU即DWVD-MCNN-BiGRU结合了时频变换与改进多尺度深卷积神经网络见知网查询截图目前暂无人使用率先应用将占据先发优势
模型简介该模型首先采用时频方法将数据序列转换为二维图有效增强故障特征使故障信息更加直观地呈现出来并选用“交叉熵”损失函数作为网络训练的依据确保训练过程的方向性和准确性。
然后合理划分训练集、验证集、测试集在网络训练过程中采用验证集不断降低损失从而避免过拟合现象保证模型的泛化能力同时采用T-SNE方法可视化网络识别前后的效果便于直观地观察模型对故障特征的识别和分类能力。
⛳️ 运行结果 部分代码function [Metrics]polygonareametric(ActualLabel, PredictedLabel,isPlot)%%%%% WARNING %%%%%%%%NUMERICALLY LARGER CLASS WILL BE AUTOMATICALLY ASSIGNED AS PositiveClass%THIS IS BECAUSE OF THE FUNCTION OF perfcurve. IT REQUIRES LARGER CLASS AS PositiveClass.% INTRODUCTION:% This study proposes a stable and profound knowledge criterion that allows the performance of a classifier% to be evaluated with only a single metric called as polygon area metric (PAM). This function is not only% calculates PAM value, but also gives Classification Accuracy (CA), Sensitivity (SE), Specificity (SP),% Kappa (K) and F measure metrics.%% CITATION INFORMATION:% Please cite the following paper for the usage of PAM value:% Aydemir O., A New Performance Evaluation Metric for Classifiers: Polygon Area Metric, Journal of Classification, (
. https://doi.org/
1
1007/s
%% USAGE OF THE FUNCTION:% INPUTS;% -ActualLabel: Actual label of the trials (samples), 1xN dimension binary labels% -PredictedLabel: Predicted (estimated) label of the trials (samples), 1xN dimension binary labels% -isPlot: A logical value indicating whether the resultant figure will be drawn. Default is true%% OUTPUT;% -Metrics: This struct gives 7 evaluation metrics which are Polygon Area...% (PA), Classification_Accuracy (CA), Sensitivity (SE), Specificity...% (SP), AUC (AUC), Kappa (K), F_measure (F_M), respectively.% AUC: Area under curve value, which should be obtained by Receiver operating characteristic (ROC), 0AUC1%% EXAMPLE;% -ActualLabel[1 1 1 1 1 0 0 0 0];% -PredictedLabel[1 1 1 0 0 0 0 0 1];% -[Metrics]polygonareametric(ActualLabel,PredictedLabel)%Code introductionif nargin2error(You have to supply all required input paremeters, which are ActualLabel, PredictedLabel)endif nargin 3isPlot true;end%plotting the widest polygonA11;A21;A31;A41;A51;A61;a[-A1 -A2/2 A3/2 A4 A5/2 -A6/2 -A1];b[0 -(A2*sqrt(
)/2 -(A3*sqrt(
)/2 0 (A5*sqrt(
)/2 (A6*sqrt(
)/2 0];if isPlotfigureplot(a, b, --bo,LineWidth,
1.
axis([-
5
5 -
5
5]);set(gca,FontName,Times New Roman,FontSize,
;hold on%gridend% Calculating the True positive (TP), False Negative (FN), False Positive...% (FP),True Negative (TN), Classification Accuracy (CA), Sensitivity (SE), Specificity (SP),...% Kappa (K) and F measure (F_M) metricsPositiveClassmax(ActualLabel);NegativeClassmin(ActualLabel);cpclassperf(ActualLabel,PredictedLabel,Positive,PositiveClass,Negative,NegativeClass);CMcp.DiagnosticTable;TPCM(1,
;FNCM(2,
;FPCM(1,
;TNCM(2,
;CAcp.CorrectRate;SEcp.Sensitivity; %TP/(TPFN)SPcp.Specificity; %TN/(TNFP)PrTP/(TPFP);ReTP/(TPFN);F_M2*Pr*Re/(PrRe);FPRFP/(TNFP);TPRTP/(TPFN);KTP/(TPFPFN);[X1,Y1,T1,AUC] perfcurve(ActualLabel,PredictedLabel,PositiveClass);%ActualLabel(
means that the first class is assigned as positive class%plotting the calculated CA, SE, SP, AUC, K and F_M on polygonx[-CA -SE/2 SP/2 AUC K/2 -F_M/2 -CA];y[0 -(SE*sqrt(
)/2 -(SP*sqrt(
)/2 0 (K*sqrt(
)/2 (F_M*sqrt(
)/2 0];if isPlotplot(x, y, -ko,LineWidth,
set(gca,FontName,Times New Roman,FontSize,
;% shadowFill(x,y,pi/4,
fill(x, y,[
8706
9216
9804])end%calculating the PAM value% Get the number of verticesn length(x);% Initialize the areap_area 0;% Apply the formulafor i 1 : n-1p_area p_area (x(i) x(i
) * (y(i) - y(i
);endp_area abs(p_area)/2;%Normalization of the polygon area to one.PAp_area/
59807;if isPlot%Plotting the Polygonplot(0,0,r)plot([0 -A1],[0 0] ,--ko)text(-A1-
3, 0,CA,FontWeight,bold,FontName,Times New Roman)plot([0 -A2/2],[0 -(A2*sqrt(
)/2] ,--ko)text(-
59,-
05,SE,FontWeight,bold,FontName,Times New Roman)plot([0 A3/2],[0 -(A3*sqrt(
)/2] ,--ko)text(
5, -
05,SP,FontWeight,bold,FontName,Times New Roman)plot([0 A4],[0 0] ,--ko)text(A
4