I need average pixel value of centre most blob in the image?
I am trying to develop auto calibration plugin for reflectance measurement, for which I need average pixel value value of centre blob in the image. As of now I am converting this image to binary, and able to identify different blobs in image. But, I want that central blob getting identified some how. Maybe we can take help of surrounding 6 small blobs.
I = imread('BLOB.TIF');
Ibw = ~im2bw(I, 0.75);
Ifill = imfill(Ibw,'holes');
Iarea = bwareaopen(Ifill, 500);
stat = regionprops(Ifinal,'boundingbox');
imshow(I); hold on;
for cnt = 1 : numel(stat)
bb = stat(cnt).BoundingBox;
I used to work in the Automatic Identification and Data Capture (AIDC) lab at Ohio University--basically, RFID tags and bar codes.
One of the tasks was to capture the then-relatively-new QR code values, and test phone cameras on capabilities. The layout of the badge has the six symbols arranged around it (all in a white field), so my best guess is that you can use QR code processing (or a modified version of it) to detect the calibration region, and then process it from there.
The best open-source project that I'm aware of (there may be others) is Zebra Crossing (zxing)--this is a library/app built for android devices and it provides all sorts of bar code processing capabilities. The project is on Github, and I've already forked the project to try and look deeper to help.
My bet is that, somewhere in the specs for the badge, is a description (or possibly even a link to an implementation) of the badge symbology and scanning specs. If you can find that, you'll probably be on the right track even if someone has to code it from scratch straight from the specs.
The general problem of "recognizing" an object or region in an image is one of those supremely hard computer vision tasks that has no simple answer. On the other hand, bar code and QR code techniques are simple, reliable, and quite efficient.
Can you give some details on this badge (manufacturer, model #, etc)? I'd like to take a crack at helping you with this, if possible.
Is this a question? Click here to post it to the Questions page.
Poor phrasing on my part--it's not that you can "use QR code processing", but I believe that similar techniques will help identify the region of interest. Small change in wording, but more clear on the intent...
Reply to this comment...
Log in to comment