0

How to divide an image into overlapping sub-blocks by sliding window?

Suever
  • 64,497
  • 14
  • 82
  • 101
rashi
  • 1
  • 2
  • `im2col(im, [M N], 'sliding')` or `blockproc` – Suever Jun 04 '16 at 16:01
  • Respected Sir, Thank you for your suggestion. I am trying to use: I3 = blockproc(I,[100 100],fun); but not able to know what code should i write for "fun" so as to divide the image into overlapping blocks. Please suggest me. With Regards Rashi – rashi Jun 04 '16 at 19:42
  • Sir, I had also tried using: I2=blockproc(a, [1 1], @(bs)disp(bs.data),'BorderSize', [1 1 ]); Taking "a" as in matrix form or I2=blockproc(I, [1 1], @(bs)disp(bs.data),'BorderSize', [1 1 ]); (simply by reading an image using "imread"; and then writing the below code) figure; imshow(a); figure; imshow(I2); In both cases, results are visible in command window but images are not coming? What to do next. Also, how to vary size of sliding window?Please suggest. Thank you. – rashi Jun 04 '16 at 20:47

0 Answers0