Professional Documents
Culture Documents
Figure 1 below shows the input and output image which is its minimum bounded
box skeleton image and the x-y coordinates of boundary points.
Hint: a matlab code of the created algorithm is presented in appendix 1 below.
Figure 1. a. represents the original input image and b. represents the output image.
V. Conclusion and future work
In this report, a number of tactics that may be used when dealing with
very large data files for machine learning. An algorithm of progressively
loading image files is created with different steps of matlab code. Most
of the matlab program codes are based on the built-in matlab functions.
This report shows that using the built-in functions of matlab may save
time and facilitate the complexity of the proposed program. For the future
work, It is to develop a very robust and high-performance parallel cluster
on the cloud (this can also be used on a local machine for performance
enhancement).
Reference
[1] Shu N.C., Housel B.C., Taylor R.W., Ghosh S.P., and Lum V.Y. EXPRESS,” a
data extraction, processing, and restructuring system. ACM Trans. Database Syst”,
Vol, 2(2), pp 134–174, 1977.
[2] Roth M.T. and Schwarz P.M,” Don’t scrap it, wrap it! A wrapper architecture for
legacy data sources” In Proc. 23th Int. Conf. on Very Large Data Bases, . 266–275,
1997.
[3] Labio. W, Wiener J.L., Garcia-Molina H., and Gorelik V.,”Efficient resumption
of interrupted warehouse loads”, In Proc. ACM SIGMOD Int. Conf. on
Management of Data, pp. 46–57, 2000.
[4] Michael J. Denney (MA) a, Dustin M. Long (PhD) b, Matthew G. Armistead
(BS) a, Jamie L. Anderson (RHITCHTS-IM) c, Baqiyyah N. Conway (PhD),
“Validating the extract, transform, load process used to populate a large clinical
research database”, Vol 94, pp 271-274, 2016.
[5] Guillaume Lavoue, Laurent Chevalier, and Florent Dupon,” Streaming
Compressed 3D Data on the Web using JavaScript and WebGL” Proceedings of the
18th International Conference on 3D Web Technology” 1-9, 2015.
Appendix 1
function [bounded_skel_image, boundary_x, boundary_y] = preprocimg(input_image)
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% This function takes a gray scale image and return its minimum
% bounded box skeleton image and the x-y coordinates of boundary points
% here boundary_x and boundary_y are coordinates with reference to lower
% left hand side of image, i.e. analogous to geometric (cartesian)
% coordinate system
% size_image=size(input_image);
input_image_inv=255.-input_image;
input_image_bin1=im2bw(input_image_inv);
% to compute the bounding box
[label_input_image_bin1 num]=bwlabel(input_image_bin1,8);
Iprops = regionprops(label_input_image_bin1);
Ibox = [Iprops.BoundingBox];
Ibox = reshape(Ibox,[4 num]);
% to extract bounded image
[~, ind]=sort(Ibox(3:4,:),2,'descend');
Iboxfinal=Ibox(:,ind(1));
bounded_image=input_image_bin1(round(Iboxfinal(2)):round(Iboxfinal(2))+Iboxfinal(4)-
1,round(Iboxfinal(1)):round(Iboxfinal(1))+Iboxfinal(3)-1);
bounded_image_scale=bwmorph(bounded_image,'dilate',2);
figure,imshow(bounded_image_scale) % FIGURE 2
% % create an edge image
%input_image_bin2 = edge(bounded_image_scale);
%figure; imshow(input_image_bin2,[]);
% create a skeleton image
skel_image = bwmorph(bounded_image_scale,'thin',Inf);
% figure;imshow(~skel_image,[]) % FIGURE 3
% compute the bounding box of a skeleton image
[label_input_image_bin1 num]=bwlabel(skel_image,8);
Iprops = regionprops(label_input_image_bin1);
Ibox = [Iprops.BoundingBox];
Ibox = reshape(Ibox,[4 num]);
% to extract bounded image
[~, ind]=sort(Ibox(3:4,:),2,'descend');
Iboxfinal=Ibox(:,ind(1));
bounded_skel_image=skel_image(round(Iboxfinal(2)):round(Iboxfinal(2))+Iboxfinal(4)-
1,round(Iboxfinal(1)):round(Iboxfinal(1))+Iboxfinal(3)-1);
%figure,imshow(~bounded_skel_image)
[B,L]=bwboundaries(bounded_skel_image);
boundary=B{1};
boundary=unique(boundary,'rows');
boundary_x=boundary(:,2);
boundary_y=size(L,1)-boundary(:,1)+1;
%%% alternate finding of boundary pixels
%%% here col_edge is x coordinate and row_edge is y
[row_edge ,col_edge]=find(bounded_skel_image==1);
hold on, plot(boundary_x,boundary(:,1),'r.'); hold off