function resizeThumbs(sti,str)
wb = waitbar(0, 'Skaber Mosaic Thumbnails...');
filer = dir([sti '\*.jpg']);

num_filer = length(filer);
thumbs = cell(num_filer,1);
RGB_val = cell(num_filer,1);
for idx = 1:num_filer
    im = imread([sti '\' filer(idx).name]);
    res_im = uint8(imresize(im, [str str]));
    thumbs{idx} = res_im;
    RGB_val{idx} = mean(reshape(res_im, [], 3), 1);
    waitbar(idx/num_filer, wb);
end
tiles.str = str;
tiles.thumbs = thumbs;
tiles.RGB_val = RGB_val;
save([sti '_' num2str(str) '.mat'],'tiles');
close(wb);