Labfans是一个针对大学生、工程师和科研工作者的技术社区。 论坛首页 | 联系我们(Contact Us)
MATLAB爱好者论坛-LabFans.com
返回   MATLAB爱好者论坛-LabFans.com > 其它 > 资料存档
资料存档 资料存档
回复
 
主题工具 显示模式
旧 2019-11-27, 18:11   #1
poster
高级会员
 
注册日期: 2019-11-21
帖子: 3,006
声望力: 66
poster 正向着好的方向发展
默认 FastICA实现.. Matlab

我一直在研究使用MatLab的FastICA算法实现。目前,代码无法像id一样分隔信号。我想知道是否有人可以给我一些有关解决此问题的建议?

disp('*****Importing Signals*****'); s = [1,30000]; [m1,Fs1] = audioread('OSR_us_000_0034_8k.wav', s); [f1,Fs2] = audioread('OSR_us_000_0017_8k.wav', s); ss = size(f1,1); n = 2; disp('*****Mixing Signals*****'); A = randn(n,n); %developing mixing matrix x = A*[m1';f1']; %A*x m_x = sum(x, n)/ss; %mean of x xx = x - repmat(m_x, 1, ss); %centering the matrix c = cov(x'); sq = inv(sqrtm(c)); %whitening the data x = c*xx; D = diff(tanh(x)); %setting up newtons method SD = diff(D); disp('*****Generating Weighted Matrix*****'); w = randn(n,1); %Random weight vector w = w/norm(w,2); %unit vector w0 = randn(n,1); w0 = w0/norm(w0,2); %unit vector disp('*****Unmixing Signals*****'); while abs(abs(w0'*w)-1) > size(w,1) w0 = w; w = x*D(w'*x) - sum(SD'*(w'*x))*w; %perform ICA w = w/norm(w, 2); end disp('*****Output After ICA*****'); sound(w'*x); % Supposed to be one of the original signals subplot(4,1,1);plot(m1); title('Original Male Voice'); subplot(4,1,2);plot(f1); title('Original Female Voice'); subplot(4,1,4);plot(w'*x); title('Post ICA: Estimated Signal'); %figure; %plot(z); title('Random Mixed Signal'); %figure; %plot(100*(w'*x)); title('Post ICA: Estimated Signal');

更多&回答...
poster 当前离线   回复时引用此帖
回复

主题工具
显示模式

发帖规则
不可以发表新主题
不可以发表回复
不可以上传附件
不可以编辑自己的帖子

启用 BB 代码
论坛禁用 表情符号
论坛启用 [IMG] 代码
论坛启用 HTML 代码



所有时间均为北京时间。现在的时间是 01:34


Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.