capture = imread('Captura.PNG');
my_image = imresize(capture, 3);
figure
imshow(my_image)
BW = imbinarize(rgb2gray(my_image));
BW1 = imdilate(BW,strel('disk',6));
s = regionprops(BW1,'BoundingBox');
bboxes = vertcat(s(:).BoundingBox);
[~,ord] = sort(bboxes(:,2));
bboxes = bboxes(ord,:);
BW = imdilate(BW,strel('disk',1));
ocrResults = ocr(BW,bboxes,'CharacterSet','.0123456789','TextLayout','word');
words = {ocrResults(:).Text}';
words = deblank(words)
0 Comments
Sign in to comment.