changeset 16:41a5a3c26961

(none)
author idamnjanovic
date Thu, 25 Mar 2010 14:05:46 +0000
parents 51b76c31c93d
children ec86452113ed
files Problems/private/countcover.m Problems/private/make.m Problems/private/sampgrid.m
diffstat 3 files changed, 9 insertions(+), 28 deletions(-) [+]
line wrap: on
line diff
--- a/Problems/private/countcover.m	Thu Mar 25 14:05:27 2010 +0000
+++ b/Problems/private/countcover.m	Thu Mar 25 14:05:46 2010 +0000
@@ -6,6 +6,8 @@
 %  and are shifted between them by steps of size STEPSIZE=[S1 S2 ... Sp].
 %  COUNTCOVER returns a matrix the same size as the signal, containing in
 %  each entry the number of blocks covering that sample.
+%
+%  See also IM2COLSTEP, COL2IMSTEP, IM2COL.
 
 
 %  Ron Rubinstein
--- a/Problems/private/make.m	Thu Mar 25 14:05:27 2010 +0000
+++ b/Problems/private/make.m	Thu Mar 25 14:05:46 2010 +0000
@@ -13,7 +13,7 @@
 %  Technion, Haifa 32000 Israel
 %  ronrubin@cs
 %
-%  April 2009
+%  August 2009
 
 
 % detect platform 
@@ -32,9 +32,9 @@
 
 % Compile files %
 
-sourcefiles = {'addtocols.c','collincomb.c','rowlincomb.c'};
+sourcefiles = {{'addtocols.c'}, {'collincomb.c'}, {'rowlincomb.c'}, {'sprow.c','mexutils.c'}, {'im2colstep.c'}, {'col2imstep.c'}};
 
 for i = 1:length(sourcefiles)
-  printf('Compiling %s...', sourcefiles{i});
-  mex(sourcefiles{i},compile_params{:});
+  printf('Compiling %s...', sourcefiles{i}{1});
+  mex(sourcefiles{i}{:},compile_params{:});
 end
--- a/Problems/private/sampgrid.m	Thu Mar 25 14:05:27 2010 +0000
+++ b/Problems/private/sampgrid.m	Thu Mar 25 14:05:46 2010 +0000
@@ -26,6 +26,9 @@
 
 
 p = ndims(x);
+if (p==2 && any(size(x)==1) && length(blocksize)==1)
+  p = 1;
+end
 
 if (numel(blocksize)==1)
   blocksize = ones(1,p)*blocksize;
@@ -67,27 +70,3 @@
   end
 end
 
-
-% 
-% p = ndims(x);
-% 
-% n = zeros(1,p);
-% for i = 1:p
-%   n(i) = length(varargin{i});
-% end
-% 
-% nsamps = prod(n);
-% 
-% % create y of the same class as x
-% y = zeros(prod(blocksize),nsamps,class(x));
-% 
-% id = cell(p,1);
-% for k = 1:nsamps
-%   [id{:}] = ind2sub(n,k);
-%   for j = 1:p
-%     id{j} = varargin{j}(id{j}) : varargin{j}(id{j})+blocksize(j)-1;
-%   end
-%   block = x(id{:});
-%   y(:,k) = block(:);
-% end
-