matlab filter: max variable size allowed by function, error

조회 수: 5 (최근 30일)
GG
GG 2015년 8월 6일
댓글: GG 2015년 8월 6일
The following code,
Hm = mfilt.firinterp(interp, hh);
Hm.Numerator = interp*Hm.Numerator;
set(Hm,'arithmetic','single');
out = filter(Hm, data);
where interp=4 (integer), hh is 1x97 double, and data is 1x1048994399 single.
results in the following error:
Error using sfirinterpfilter
Maximum variable size allowed by the function is exceeded.
Error in dfilt.singlefilterquantizer/firinterpfilter (line 11)
[y,z,tapidx] = sfirinterpfilter(p,L,x,uint32(ny),z,tapidx);
Error in mfilt.firinterp/secfilter (line 20)
[y,z,tapidx] = firinterpfilter(Hm.filterquantizer, ...
Error in dfilt.abstractfilter/super_filter (line 61)
[y,zf] = secfilter(Hd,[xi;x(1:end-rs,:)],zi);
Error in dfilt.abstractfilter/filter (line 12)
y = super_filter(varargin{:});
Error in r_sc1 (line 612)
out = filter(Hm, data);
Anyone know the limit for filter in this case? And/or how to workaround this error (e.g. is it possible to split the filtering into two operations, etc.)?

답변 (1개)

Walter Roberson
Walter Roberson 2015년 8월 6일
With regards to breaking it up into runs: see http://www.mathworks.com/help/dsp/ref/mfilt.firinterp.html PersistentMemory and States .
You have a Finite Impulse Response filter so it is only necessary for the filter to remember length(hh) values to be able to stop filtering and pick up again later at the next sample.
  댓글 수: 1
GG
GG 2015년 8월 6일
Thanks for the hint Walter. It seems the PersistentMemory setting enables the States functionality. I found the following link that provides an example: http://www.mathworks.com/help/dsp/ref/filter.html

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

카테고리

Help CenterFile Exchange에서 Applications에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by