annotate Code/Descriptors/yin/private/src/rdiff_inplace.m @ 4:92ca03a8fa99
tip
Update to ICASSP 2013 benchmark
author |
Dawn Black |
date |
Wed, 13 Feb 2013 11:02:39 +0000 |
parents |
ea0c737c6323 |
children |
|
rev |
line source |
dawn@0
|
1 % rdiff_inplace(x,y,d,lags,n) - in place running cross-difference function
|
dawn@0
|
2 %
|
dawn@0
|
3 % x: column vector
|
dawn@0
|
4 % y: column vector
|
dawn@0
|
5 % r: result matrix (time X lag)
|
dawn@0
|
6 % lags: 2-column matrix of lags
|
dawn@0
|
7 % n: (samples) frame-rate & window size (default=1)
|
dawn@0
|
8 %
|
dawn@0
|
9 % Vectors x and y are each delayed by amounts specified by lags and subtracted
|
dawn@0
|
10 % sample to sample. The difference is squared and added over a time window
|
dawn@0
|
11 % of n samples. This processing is repeated every n samples, as many times
|
dawn@0
|
12 % as there are columns in r.
|
dawn@0
|
13 %
|
dawn@0
|
14 % A positive lag applied to x causes it to be delayed with respect to y.
|
dawn@0
|
15 % A positive lag applied to y causes it to be delayed with respect to x.
|
dawn@0
|
16 % The number of rows of r must match that of lags.
|
dawn@0
|
17 %
|
dawn@0
|
18 % Mex function.
|
dawn@0
|
19 % Beware: input arguments are assigned to. This is not matlab-kosher!
|