Mercurial > hg > camir-aes2014
diff toolboxes/MIRtoolbox1.3.2/MIRToolbox/mirchunklim.m @ 0:e9a9cd732c1e tip
first hg version after svn
author | wolffd |
---|---|
date | Tue, 10 Feb 2015 15:05:51 +0000 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/toolboxes/MIRtoolbox1.3.2/MIRToolbox/mirchunklim.m Tue Feb 10 15:05:51 2015 +0000 @@ -0,0 +1,24 @@ +function cl = mirchunklim(lim) +% c = mirchunklim returns the maximal chunk size. +% If the size of a long audio files exceeds that size, it will be +% decomposed into chunks of that size, before being analyzed in the +% different functions on the toolbox. +% mirchunklim(c) specifies a new maximal chunk size. +% If MIRtoolbox tends to use more memory than what is available in the +% RAM of your computer, you should decrease the maximal chunk size. +% mirchunklim(Inf) toggles off the automated chunk decomposition. + +persistent chunklim + +if nargin + if not(isnumeric(lim)) + error('ERROR IN MIRCHUNKLIM: The argument should be a number.') + end + chunklim = lim; +else + if isempty(chunklim) + chunklim = 5e5; + end +end + +cl = chunklim; \ No newline at end of file