Тёмный

Normalised Correlation Explanation with Demo 

David Dorran
Подписаться 19 тыс.
Просмотров 69 тыс.
50% 1

This video discusses the reason for normalised correlation and when it is beneficial. It also presents a situation where you should not use normalised correlation.

Опубликовано:

 

24 фев 2014

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 61   
@andy.robinson
@andy.robinson 7 лет назад
Thanks! You broke the formula down to my level perfectly.
@BattleAddictGaming
@BattleAddictGaming 9 лет назад
Holy crap was this helpful. Thanks a million for explaining it so well! Its also handy having a familiar accent.
@publicenemymcmenemy
@publicenemymcmenemy 7 лет назад
Clear explanation and example. Thanks!
@khurramhameed112-fetphdees6
@khurramhameed112-fetphdees6 4 года назад
Thank you very much sir for soooooo nice way of teaching..
@sodkenij8288
@sodkenij8288 6 лет назад
Thanks !! I love ur video so much
@NIMIT88
@NIMIT88 8 лет назад
great video sir.... exactly found what i needed... there is a minor misprint in calculation of norm_dem for Y & Z... 24 is printed instead 23.. but it wont affect the result much.. thanks for the simplified explanation :)
@mahmoudnady2422
@mahmoudnady2422 8 лет назад
thank you it is interesting and useful
@NosferatuBS
@NosferatuBS 3 года назад
Thank you!
@tigrayrimey6418
@tigrayrimey6418 2 года назад
good pt.
@yuanli7626
@yuanli7626 7 лет назад
thanks a lot!
@bigumangaba7930
@bigumangaba7930 10 лет назад
enlightening
@eldany_uy
@eldany_uy 3 года назад
Thanks for sharing this!!! I'm trying to implement but I'm not getting a value between -1 and +1...should I be doing something wrong? Anyway 'seems' to work. What i do is: i have two arrays: A[a1,a2,a3,a4...] B[b1,b2,b3,b4...] first normalize both data groups from 0 to 100 ( i want to find % changes) second i put in a variable 'first_pass' : (A[a1]*B[b1])+(A[a2]*B[b2]).... third i put in a variable 'second_pass' : (A[a1]^2) + (A[a2]^2).... forth i do the same with graph B and store in 'third pass' : B([b1]^2) + (B[b2]^2).... fifth i get my results: (first_pass/(SQRT(second_pass*third_pass)) my results is always > 0 but not between -1 and +1 could you help me? :) Thanks!
@calvin19980324
@calvin19980324 9 лет назад
Hi David, can you please provide a reference text for the formula of Normalised Correlation? I try to apply it to my data but cannot even google anything like the formula, it seems many pages are dealing with Normalised crosscorrelation. Does this formula have any other name?
@jeremfer6319
@jeremfer6319 7 лет назад
what does x= [a b c d] means? is it a dicrete signal that gets value a when t=0 , b when t=1 ... d when t=3 ? and what does N means?
@sushilkulkarni2243
@sushilkulkarni2243 4 года назад
Hello David. Suppose I want to compare two audio files and want to find similarity score . How i have to do? I have one audio .wav file of 4 to 6 seconds and another audio .wav file of about 1 to 2 seconds.
@slocm3z
@slocm3z 5 лет назад
lol i don't know why i watched these. but its cool non the less. i'm sure it'll come up in the future haha
@rydude998
@rydude998 5 лет назад
If the sinusoid is already apart of the signal a and b why are you multiplying the sum of the sinusoids squared with the sum of the signals square in the denominator of your code? edit: My bad, I misunderstood what signals you were comparing in the normalized correlation. However, I don't understand why it was required to step through the matrix with a for loop previously but not now?
@pranavbhardwaj909
@pranavbhardwaj909 5 лет назад
Could someone please resolve the following issue : The correlation results 1, when compared to correlation results 2, indicate that the 2 signals in consideration are better correlated in the first case (100>50). However the same conclusion from normalized correlation results indicate otherwise (0.4364
@abhinavabhi4525
@abhinavabhi4525 7 лет назад
after watching your video we feel to dump our professors into a well.
@danielpaz349
@danielpaz349 7 лет назад
Hello, thanks for the video. I have a question, what does biased and unbiased means in the xcorr function? (roughly speaking).
@ddorran
@ddorran 7 лет назад
unbiased means that values further away from a lag of zero are general smaller since there are fewer non-zero samples to sum. You can account for this by dividing by the number of overlapping samples for each calculation.
@athens31415
@athens31415 2 года назад
This is a good explanation of what the equations represent and how to code them up, but ultimately fails to explain what it claims to do (describe when normalised correlation is beneficial to use over other methods).
@ddorran
@ddorran 2 года назад
In the first minute of the video it shows that standard correlation measures are impacted by the energy of the signals being correlated (rather than the shape) and later it shows that normalised correlation deals with this issue by scaling standard correlation appropriately. Does this not show when normalised correlation is useful? Have I misunderstood the point you are making?
@randywelt8210
@randywelt8210 8 лет назад
question: correlation coefficient. = normalized correlation ??
@Nick1Nap
@Nick1Nap 8 лет назад
Hi David, I am really enjoying the videos you posted. I have seen others using the Pearson coefficient for correlation, specifically in template matching methods in the signal processing domain. The method above and Pearson method will provide rho to range from -1 to 1. However, It seems they will give slightly different answers, regarding the produced correlation coefficient. Are you aware of any type of documentation out there that highlights these two methods and their differences? Or even a more specific name for the normalized correlation coefficient method you discussed above for to me to do literature search on ? I am aware of this method, and its heavily used in signal processing as well, for applications in DTF and match filtering. I guess I am wondering if there is an ideal time to use one or the other, and I really haven't seen anything or anyone address this..... Best, Nick
@Nick1Nap
@Nick1Nap 8 лет назад
+Nick1Nap I think found what I need... Thanks! dsp.stackexchange.com/questions/9491/normalized-square-error-vs-pearson-correlation-as-similarity-measures-of-two-sig
@ddorran
@ddorran 8 лет назад
+Nick1Nap Thanks for posting this link! I have a bad habit of using my own (and sometimes incorrect) terminology when I'm attempting to explain a concept and I have noticed this to be particularly problematic with this video.
@tetlleyplus
@tetlleyplus 6 лет назад
Isn't Normalised Correlation, just the cosine of the angle between the two vectors? (dot(x',y)/sqrt(norm(x)*norm(y))
@milorday5141
@milorday5141 2 года назад
thx
@Illumarnati
@Illumarnati 9 лет назад
Hi David, nice! Check typo at 5 min into Normalized Corr... video where your calculated energy for y is 24... & should be 23 as in the previous step.
@ddorran
@ddorran 9 лет назад
Thanks Illumarnati! I've added a comment at 4:10. Apologies for any confusion caused.
@Illumarnati
@Illumarnati 9 лет назад
David Dorran no confusion. Again, very nicely done. Thanks.
@rabiafyz9952
@rabiafyz9952 7 лет назад
Hi, i searched normalized cross correlation. which used signal - mean in equation. So i have a question, What is the difference between normalized cross correlation and normalized correlation?
@ddorran
@ddorran 7 лет назад
Here is a link to a video that might help explain ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-RO8s1TrElEw.html
@sarvariabhinav
@sarvariabhinav 7 лет назад
excellent explaination but can you tell why we have only used energy scaling factor normalisation and not some other function like say modulus scaling factor??? please reply...Thank You.
@ddorran
@ddorran 7 лет назад
The scaling factor used ensures that the correlation value returned lies between -1 and 1. I guess that other scaling factors could be used that might be more computationally efficient but they wouldn't have the property of ensuring the result lies between -1 and 1
@fukgovernment
@fukgovernment 9 лет назад
Thanks sir. But I am a bit confused some textbooks include some kind of shifting to one of the signal being correlated. Yours do not include any form of shifting?
@ddorran
@ddorran 9 лет назад
Outlaw The shifting (a.k.a. lag) is associated with cross correlation. See ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-RO8s1TrElEw.html
@asrafmohamedmoubark
@asrafmohamedmoubark 8 лет назад
hi..i have a question..in what particular situation that we have to use normalize correlation ? can you explain to me..thank you..
@ddorran
@ddorran 8 лет назад
+asraf mohamed One situation would be where you have a signal that contains a lot of high energy fluctuations and you are searching for the presence of relatively low energy waveform within the signal.
@asrafmohamedmoubark
@asrafmohamedmoubark 8 лет назад
+David Dorran it make sense..thank you so much..by the way..i like all of your videos..good jobs..carry on..cheers
@Krishnajha20101
@Krishnajha20101 5 лет назад
Hint: Think in terms of vectors. Normalized correlation is just the dot product of unit vectors.
@Hamdifollowing
@Hamdifollowing 9 лет назад
when correlation is applied is there a minimum value based on which it is decided that the waves are similar or it is proportionality between minmum corr and max corr ?
@ddorran
@ddorran 9 лет назад
it would depend on the application and would most likely be determined through experimentation
@Hamdifollowing
@Hamdifollowing 9 лет назад
David Dorran so it complicated then . i did a correlation between i think two sines and the value was 60 . in DTMF number detection .. correlating the spectrum of the recording with standard DTMF signals spectrum doesn't result 1 in the normalized formula . the peaks are of very less values but still constitute peaks compared to other correlations .
@shashidharmuniswamy2620
@shashidharmuniswamy2620 2 года назад
So, from what I understand: correlation measure is to show how strongly the signal is into the sample signal, while normalized correlation is how similar are the signals, is this right, please?
@ddorran
@ddorran 2 года назад
yes. That's how I interpret them
@shashidharmuniswamy2620
@shashidharmuniswamy2620 2 года назад
@@ddorran Thank you for your response, David. Actually, this makes sense and does have a basis I feel. While the Correlation measure shows how strongly the signal is in the sample signal by the dot product, the normalized correlation relation looks very much similar to the Pearson correlation factor (r). Thereby describing how linear or nonlinear the association of the two variables x and y, or in this case - the signals are. Can I conclude like this? It would be nice to hear your thoughts, please.
@kuncao6549
@kuncao6549 9 лет назад
why we should not use the normalised correlation here? Is the b did more similar with s1?
@ddorran
@ddorran 9 лет назад
In the second example you are trying to determine how strongly present one signal is another rather than a direct measure of similarity between signals
@kuncao6549
@kuncao6549 9 лет назад
Thank you! I think I don't get the meaning of 'strongly present', would it be used in signal conditioning? It did amplify the signal, yet introduced a larger noise.
@ddorran
@ddorran 9 лет назад
Yes - you could have a signal you are interested in buried in noise. So in this case you would have a signal added with noise - you could use correlation to see how strongly the signal was present in the noisy signal.
@Hamdifollowing
@Hamdifollowing 9 лет назад
how we can link this to the fourier series and transform ? i think in the transform we are using the standard correlation .
@ddorran
@ddorran 9 лет назад
The discrete Fourier transform is a simply correlation of a signal with a set of sinusoidal basis functions see ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-B2iUDBZzBpY.html
@Hamdifollowing
@Hamdifollowing 9 лет назад
David Dorran Nice. But what is the necessity of correlating with exponential ? Exponential contains Re cosine part and Im sine part . Why we just can not correlate with cosine or sine ? And why we do not use normalization ?
@ddorran
@ddorran 9 лет назад
hamdi f The complex exponential is a combination of a cosine and a sine so its mathematically convenient to use it rather than use separate sines and cosines. Also if the signal being analysed is complex (real and imaginary terms) then that signal isn't just made up of sinusoids (which are combinations of negative and positive frequency complex exponential pairs which are equally weighted see ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-M1bLPZdNCRA.html) its made up of a set of positive frequency complex exponentials and negative frequency complex exponentials which may not have matching weighting for positive and negative frequency pairs. If you used normalised correlation you wouldn't be able to determine how strongly present a cosine or sine was in the signal being analysed see ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-ngEC3sXeUb4.htmlm36s
@Hamdifollowing
@Hamdifollowing 9 лет назад
David Dorran Regarding the last paragraph ; if i got a x1(t)=coswt and x2(t)=10*coswt then the normalized corr formula fails though they have the same frequency and should have the same magnitude response except for the some scaling differences in magnitude plot . And if i have two different frequency waves the standard corr formula may fail and show misleading answer that they are similar ! The second point ; you said that standard corr shows how much of signal 1 is in signal 2 . But since multiplication is commutative and that means that sig1 is contained in sig2 as much as sig2 is contained in sig1 ! and i think that is not correct . Can we use at least for real signals .. a Fourier terms of cosine or sine for corr ?
@ddorran
@ddorran 9 лет назад
If you correlate two sinusoids of different frequencies (f1 and f2) you will get a result of zero (once the duration over which you correlate is an integer multiple of 1/(f1-f2)) With regard to the second point my terminology is misleading - I do say that correlation is a measure of how strongly present one signal is in another which I think is conceptually a nice way to think of it in certain situations. However saying that correlation is measure of similarity between two signals is more accurate and would fit in with your observation that the correlation process is commutative. Yes you could undertake a Fourier type analysis of real signal that correlates against only real cosines and sines.
@TheBjjninja
@TheBjjninja 4 года назад
Why not just scale the data?
@ddorran
@ddorran 4 года назад
Scaling the data would also work. It amounts to the same thing
@jasonliu2678
@jasonliu2678 3 года назад
多个逗号那么难吗,看了半天f
Далее
Correlation Explanation with Demo
10:11
Просмотров 121 тыс.
pitch period tracking using correlation
21:05
Просмотров 45 тыс.
Maybe a little TOO much gel 😂
00:12
Просмотров 11 млн
Она Может Остановить Дождь 😱
00:20
EVOLUTION OF ICE CREAM 😱 #shorts
00:11
Просмотров 3,1 млн
Cross Correlation Demo using Matlabs xcorr function
9:33
Are you Bayesian or Frequentist?
7:03
Просмотров 242 тыс.
Part 2: Convolution and Cross-Correlation - G. Jensen
15:06
3.8 - Auto correlation and cross correlation
10:33
Просмотров 66 тыс.
Discrete Fourier Transform - Simple Step by Step
10:35
Просмотров 886 тыс.