Splitting an image into smaller regions
19 views (last 30 days)
Show older comments
hasan alhussaini on 26 Feb 2018
Commented: hasan alhussaini on 17 Mar 2018
I'm working on a code that creates an RGB descriptor for visual search. i've managed to implement the rgb descriptor on the whole image. but i wanted to experiment by splitting the same image up into smaller areas and rerun the experiment by calculating the rgb descriptor on smaller parts of the image.
the reason behind this, is because i'm using a query image against a dataset in order to find visually similar results. but if i split up my image into smaller pieces, i got a feeling it will be more accurate.
my question is, is there a function or piece of code that could help me with this?
Image Analyst on 26 Feb 2018
See the FAQ for 2 different ways, depending on how you want to do it.
More Answers (2)
jonas on 26 Feb 2018
Edited: jonas on 26 Feb 2018
%Load 256x256 grayscale image and divide in 4x4 equally sized subimages
I = imread('cameraman.tif');
repeat for each RGB channel
Find more on Neighborhood and Block Processing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!