필터 지우기
필터 지우기

Segmenting, windowing, framing with 50%-75% overlap

조회 수: 17 (최근 30일)
Mona
Mona 2014년 11월 15일
댓글: Mona 2014년 11월 17일
Hi everyone,
I am very new to matlab so please be patient with me if I sound dumb!!!
I have a project where I am suppose to read a noisy speech and filter it, and I am stuck in the first part. I was able to read the speech and plot it using the following
[x, fs, nbits]= wavread('noisy.wav'); sound(x, fs); timex=(1: length(x))/fs; plot(timex, x); xlabel ('Seconds') ; ylabel ('Amplitude');
where fs = 16000 and length(x) = 159999
Now, I am suppose to do Segmentation , windowing, and framing with a 50%~ 75% overlap in order to take STFT, but I am not able to find a matlab function that will section my matrix x into overlapped frames?!! Can someone help me please!!!!
Thanks

채택된 답변

Star Strider
Star Strider 2014년 11월 15일
If you have the Signal Processing Toolbox, use the spectrogram function. It will do what you want.

추가 답변 (1개)

Mona
Mona 2014년 11월 15일
편집: Star Strider 2014년 11월 15일
Thank you Star Strider,
I've used the spectrogram function as follows:
flength=256;
foverlap=flength/2;
fftlength=flength;
wnd=hamming(flength,'periodic');
[S, F, T, P] = spectrogram (yf, wnd,foverlap, fftlength, fs);
But I still have questions about its return. It returns four things S, F, T, and P . Is S a matrix of rows and columns where the number of columns matches the number of frames? For example, my original yf is 159999 and I took the overlap to be 50% and my fs is 16000. I am not sure how to figure out the length of S and number of frames?
Please help
Thanks
  댓글 수: 2
Star Strider
Star Strider 2014년 11월 15일
My pleasure!
The ‘S’ matrix according to the documentation:
  • Each column of S contains an estimate of the short-term, time-localized frequency content of x. Time increases across the columns of S and frequency increases down the rows.
It is difficult to answer in any detail. You probably need to plot ‘S’ to see what your spectrogram looks like. That may tell you everything you need to know.
In the ‘Examples’ section of the documentation (about the power spectral densities of chirps) is a reasonably detailed discussion of the various variables the spectrogram function returns and how to plot and interpret them.
Mona
Mona 2014년 11월 17일
Thanks Star,
I am reading the document now and starting to figure out the numbers :)

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Time-Frequency Analysis에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by