Documentos de Académico
Documentos de Profesional
Documentos de Cultura
where: D = minimum distance at which two points can be resolved (nm)
= wavelength of light used
NACondenser and NAObjective = numerical aperture of the lens
Numerical aperture is a measure of a lens's ability to "capture" light coming
from the specimen and use it to make the image. As with magnification, it is marked
on the lens. Using immersion oil between the specimen and the objective lens
increases its numerical aperture and in turn, makes its limit of resolution smaller. The
result is better resolution (Leboffe & Pierce, 2011).
3.4 Image Processing
The researchers will undertake image processing that aims to determine the cell
concentration of white blood cells and red blood cells. The scale of image processing of
the study will be implemented using Open Source Computer Vision Library (Open CV).
This part of the study will show the basic concepts of image processing of the object image
27
that will undergo different processes such as elimination of image noise, threshold
segmentation, color reversion and circle detection and count.
3.4.1 Median Filter
Figure 3.4 a sample object image
Median filter is a nonlinear signal processing method. Median filter was
proposed and applied in one-dimensional signal. And then it was used in two-
dimensional image signal processing. Median filter can overcome the image detail
illegibility of linear filter such as minimum square root filter, mean filter and so on,
under certain extent. It is very efficient for filtering impulse interfere and image scan
noise. Median filter is convenient to be used because of no use for image statistic
character in practical operation course (Hudai et al., 2009).
Figure 3.5 Result of Median Filter (Hudai et al., 2009)
28
(3)
(4)
3.4.2 Threshold Segmentation and Color Reversion
The basic concepts of this approach are these: Using edge measurement, the
initial threshold can be obtained. Also, the gray-scale i of different pixels in the
image contribute dissimilarly to the optimal threshold. The more | i |, the less
weight. We regard the reciprocal of | i | as a weighting factor to calculate the
thresholds of the whole binary image (Hudai et al., 2009). Normalization coefficient
and weight coefficient of each pixel can be calculated using the following formulas
= 1/|i |
=0
= /|i |
Where i = pixel value of different edge spot
m = maximum grey value
The optimal threshold will be obtained under application of the statistic
speciality, after disposing of different pixels according to weighted measures. We
consider it as the optimal likelihood threshold for processing the object image into
a binary one (Hudai et al., 2009). Fig. 3.6 illustrates the results.
Figure 3.6 Result of Threshold Segmentation (Hudai et al., 2009)
29
(6)
(7)
(5)
Figure 3.7 Result of Color Reversion (Hudai et al., 2009)
3.4.3 Power Law Transformation
Power Law Transformation or simply gamma transforms are used to help map
dark intensities into a broader assortment of intensity values (Gonzales & Woods,
2008). Gamma defines the relationship between a pixels numerical value and its
actual luminance which is an important factor to microscopic samples. This is very
important in the matter of the amount of light the image had to contain so as to apply
the cell detection algorithm. The gamma transform can be obtained by:
Where C and r are +ve constants.
3.4.4 Circle Hough Transform
The Hough transform can be used to determine the parameters of a circle
when a number of points that fall on the perimeter are known (Rhody, 2005). A circle
with radius R and center (a, b) can be described with the parametric equations
= +()
= +()
30
(8)
(9)
When the angle sweeps through the full 360 degree range the points (x, y)
trace the perimeter of a circle. If an image contains many points, some of which fall
on perimeters of circles, then the job of the search program is to nd parameter triplets
(a, b, R) to describe each circle. The fact that the parameter space is 3D makes a direct
implementation of the Hough technique more expensive in computer memory and
time (Rhody, 2005).
3.4.4 K-Means Clustering Algorithm
The researchers will apply K-means clustering algorithm for estimating the
mean of a set of K-groups. According to Alsabti et al., the k-means method has been
shown to be effective in producing good clustering results for many practical
applications. A direct algorithm of k-means method requires time proportional to the
product of number of patterns and number of clusters per iteration. The number of
clusters is assumed to be fixed in k-means clustering. Let the prototypes
(
1
, ,
, {1, , }, {1, , }
Equation shows a high level description of the direct k-means clustering
algorithm.
is the
th
cluster whose value is a disjoint subset of input pattern. The
quality of clustering is determined by the following error function
= |
|
2
=1
31
Chapter 4
DESIGN CONSIDERATIONS
This chapter mainly contains various components of the prototype of the study that are
needed to be considered. This consists of the flowcharts, system diagrams, hardware and
software plans.
4.1 Proposed Design
The proposed prototype that is all about the detection and cell count of RBCs and
WBCs in a urine sample is then divided into two sub-categories: the hardware and software
plans. The hardware plan is composed of the physical instruments and equipment that will
be used in order to attain the goal of the study. For the most crucial part of the study, it
evolves around the software plan which comprises of the image processing software, the
environment to be used and the database for record keeping in which all of these will be
incorporated.
4.1.1 Hardware Plan
This part of the study will focus on the hardware plan of the proposed design
by the researchers. Essential components of the prototype and their functions will be
discussed in the succeeding segments.
The design will require a microscopic lens which will be mechanically attached
to the camera unit of the smartphone. This integrated device will serve as the image
capturing operation of the urine sediment. The researchers forethought of acquiring
the microscopic lens online.
The attachable microscope must have at least 40X objective magnification,
while the camera phone must be at least five (5) mega pixels.
The researchers found an affordable microscope designed specifically for the
iPhone 5/5s. This microscopic lens will convert the smartphone into a portable
microscope with a magnification of 60x 100x. It has a built-in LED light for quality
image output. It also has a on and off switch, focus control and zoom control features
that would certainly help to improve the researchers proposed design. The portable
microscope would cost around 22.99 U.S dollars with exclusion of the shipping
payment, 60 100x zoomable microscope for iPhone5/iPhone 5s.
The setup of the study will deeply focus on the software environment. The
hardware will only deliver the required object image that will undergo various image
processing techniques such as Median filter, threshold segmentation, color reversion,
and circle and blob detection.
The proposed design will also require a laptop or a computer unit. This will
serve as an image processing unit, data base, and output of the results. The
transportation of the object image from the smartphone to the laptop will use a cloud
storage like Dropbox that has a function that will automatically sync the captured
image from the smartphone online and will update the Dropbox folder from the laptop
device. An alternative method is to connect directly the smartphone to the laptop
using a universal serial bus (USB) cable.
33
4.1.2 Software Plan
In this section, it will comprise of the plan on how the software of this study is
to be implemented. The image to be processed is then acquired through the camera
phone, as stated in the hardware plan, which is then sync with the computer or laptop
which contains the software prototype. The primary software for the image
processing part of the study is OpenCV while for the graphical user interface and
environment it will then be handled by Code::Blocks using C++ language. The
database will be done using MySQL.
4.1.2.1 Open Computer Vision Library (OpenCV)
There are a lot of available image processing software available in the
market. One of the most commonly used is Matlab and OpenCV. Based on a
study conducted by Matsuka, Hudec and Benco (2012), the comparison of CPU
time consumption for image processing algorithm in Matlab and OpenCV,
results show that OpenCV is faster than Matlab in selected algorithms from 4
to 30 times and sometimes up to 100 times.
OpenCV is an open source computer vision library which contains more
than 500 optimized algorithms suited for image and video analysis. Since it is
an open source software, it is more economical and efficient to use for this kind
of implementation. The image being captured is then synced on this image
processing software.
34
For this study, the use of blob detection is needed to be able to identify
the cell structures within the captured sample. It will be used in terms of
utilizing on the detailed features of the cells. Certain formulas are entered in the
program to be able to utilize the shape detection function of the software. The
formulas to be used are to be found in the theoretical part of this study. After
detecting the blobs in the acquired sample, it will then be filtered according to
the distinct features of a red blood cell and pus. As the sample is being filtered,
cell count will come into picture. The cell count will serve as a counter for every
cell that will have the same distinct features as mentioned. Analysis of the
sample will be done based on the result of the automated cell count compared
to the normal cell count.
4.1.2.2 C++ (Code::Blocks)
An appropriate environment, where the process will reside, should be
taken into good consideration. To address the current trend and needs, a stand-
alone software is the most viable thing to offer for this study. OpenCV can be
incorporated to different environment, it can be through Java, Phython, C++,
etc.
OpenCV is highly recommended based on established studies and
known professionals. It runs smoothly in a C++ environment. The researchers
had decided to use Code::Blocks since it is a free C++ IDE, it is designed to be
extensible and fully configurable. Built around a plugin framework, it can be
35
extended with plugins which is viable in incorporating it with OpenCV and
MySQL.
The graphical user interface will serve as the bridge communication
between the user and the image processing software unit. The researchers aim
to create a user-friendly environment in which anyone could easily use it and
be able to perform the needed analysis. This will contain the basic input
information such as name, age, gender and the image of the urine sample to be
analyzed. There would also be initial restrictions due to the proper analysis of
the samples. The result would contain the pre-processing, processing and post-
processing images of the sample and the cell count of RBCs and WBCs. It will
be projected in the main window of the software prototype after the testing had
been made.
4.1.2.3 MySQL
There are so many available databases which can be used for the sake
of record keeping but the researchers had decided to use MySQL. MySQL is
being considered as the worlds most popular open source database. As being
stated, being an open source sets a huge advantage for it since it is economical
to use yet can handle the necessary work load. It is also easy to operate and it
can be interfaced with the C++ environment.
The results of the entire process is then saved and recorded in a
database system so as to be beneficial for a later use. By having a database
36
system with the prototype, it enables the person to keep a record of their results
and can be used to routinely monitor their own cell count.
Through the database, it is then needed for the researchers to create
sufficient tables with their data field and should be all linked so that it can easily
provide the relative data needed to be stored. The database will consist of: the
name of the patient, age, gender and the acquired result if the process.
4.2 Design Flow
Based on the initial study done by the researchers, they have found that to be able to
apply the proposed prototype, composed of the hardware and software, they divided the
process into two phases: capturing the samples and image processing. In the sampling
phase, they will use or obtain samples from the mid-stream specimen of the urine. The
specimen will be captured using the microscopic lens attached to a camera phone synced
to a laptop that contains the software prototype. In the image processing phase, the software
will process the image and will analyze it according to the researched evaluations for
urinary tract infections and the results gathered will be sent to a medical database for
storage and final diagnosis brought about by a physician. The algorithm of the proposed
prototype approach is shown in figure 4.1.
37
Figure 4.1 Basic Concept of the Proposed Design
4.2.1 Sampling and Testing Phase
In the sampling phase, which consists of the laboratory test procedure dealing
with the image acquisition of the samples, urine samples coming from volunteers
within the age range of 13 to 19 (adolescence) and 20 to 40 (young adults) will be
tested accordingly using at least 30 samples and will be analyzed if the number of
pus and red blood cells in these samples are enough to be considered critical for the
standard cell count. A MSU (mid-stream specimen of urine) standard will be used as
samples. MSU is preferred to reduce the possible contamination of the sample from
debris in the urethra, which may give rise to inaccurate results as mentioned by
Stegall (2007).
The testing phase would be divided into 2 categories: initial testing and
prototype testing. The initial testing would consist of 15 samples, having a variety of
good and bad samples. This will be used to be the basis of the image processing
system of the prototype. The prototype testing would serve as the prototypes test of
ability, effectivity and efficiency which is then conducted with at least 30 samples.
Capture an
image of the
urine sediment
with a x40 total
magnification
Image
processing
using Circle
Hough
Transform
Display cell
count,
processed
image and save
to data base
38
The researchers will obtain the samples from a clinical laboratory with
approval of the medical facility. The samples are in need of careful handling so the
help of a trained physician in urinalysis will be present in obtaining the samples that
the group needs.
4.2.2 Image Capturing
After obtaining the samples for examination, the researchers will use the
equipment stated under the hardware plan. The microscope is attached to the camera
of the casing of the phone to prevent damage on the surface of the device.
4.2.3 Image Processing
Upon obtaining the image from the camera phone, the image will now
undergo a series of image processing, in order to analyze what are the shape and size
of the following sediments that are shown in the image. The researchers intend to use
algorithms that are within Open CV such as blob detection, cell counting, summation,
thresholding and set parameters. Since RBCs and WBCs are similar to circular in
shape, image processing using circle Hough Transform will be used to identify which
parts of the image are considered to be cells.
4.2.4 User Interface and Database
After the image processing step, the researchers will have made a graphical
user interface (GUI) that will help identify the input, data and results properly. Since
OpenCV is versatile with most know GUI associated programming languages like
Java, C++, Phyton, etc., then the proposed user interface will be made using C++ as
39
prescribed in the software plan. The interface should contain the requirements for
necessary inputs such as the name, age, gender and most importantly the image of
the urine sample. Once the data is collected, it will undergo the image processing
phase and will output results as well as save the information in a database based on
MySQL.
40
4.3 Program Flow
4.3.1 Image Processing Flow
41
Chapter 5
SUMMARY OF THE PROPOSAL
The proposed thesis has provided the necessary information that can help in making
the software feasible. Certain scopes and limitations have been pointed out such that there
is room for improvement on the study that was not met by the researchers. The methods
for implementation were brought about by the theories that relate to the whole process for
the automation of the microscopic part of urinalysis. The quality and proposed standard
was considered in the basis of the results, which was determined by the most recent studies
related to the know standards for determining the risk of having infections brought about
by urinalysis.
BIBLIOGRAPHY/REFERENCES
Alsabti, K., Ranka, S., Singh, V. (n.d.). An Efficient K-Means Clustering Algortihm.
Retrieved November 15, 2013, from http://www.cs.utexas.edu/~kuipers/readings/Alsabti-
hpdm-98.pdf
Borja, O., Padua, B.J., Verdadero, C.J., Yangat, M.R., Yanos, M., Yoro, J.A., Yumul,
M., Yumul, M.G., Zambra, J. (2010, September 13). Case Presentation on Urinary
Tract Infection. Retrieved October 20, 2013, from
http://www.scribd.com/doc/37351290/Case-presentation-on-Urinary-tract-infection
Cornell University. (n.d.). Routine Urinalysis. Retrieved October 22, 2013, from
https://ahdc.vet.cornell.edu/clinpath/modules/ua-rout/ua-rout.htm
Deepthi R. S., & Sankaraiah S. (2011). Implementation of Mobile Platform Using QT
and Open CV for Image Processing Applications. IEEE Conference on Open
Systems. 284-289.
Department of Health of the Republic of the Philippines. (2011). MORBIDITY: 10
Leading Causes, Number and Rate 2004 2008 & 2009 [statistics]. Available from
Philippine Health Statistics database.
Fialov L., & Vejraka M. (2013/2013). Urine Analysis II: Physical Examination
Urinary Sediment. Retrieved from http://ulbld.lf1.cuni.cz/file/867/Urine_sediment1213.pdf
Fogazzi, G.B., Garigali, G. (2003, November). The Clinical Art and Science of Urine
Microscopy. Current Opinion in Nephrology and Hypertension, 12(6), 625-632.
43
Gonzalez, R. C., & Woods, R. E. (2008). Digital Image Processing, 3rd Ed. Upper Saddle
River, NJ: Pearson Prentice Hall.
Gupta, M. (2012). Cell Identification by Blob Detection. Universal Association of
Computer and Electronics Engineers. Universal Association of Computer and
Electronics Engineers. 233-236.
Gusewelle, R. (2011). Detection, Early Management & Prevention, of Urinary Tract
Infections in Older Adults. Retrieved October 20, 2013, from
http://www.ngna.org/_resources/documentation/events/2011_annual_convention.....
.........20Tract%20Infections%20in%20Older%20Adults%20(handouts).pdf
Halim, N., Hamid R. Mohamed, K., Arshad, W.A., Naim , Pekaulet al. (2012). Detection
and Summation of Pus Cells and Epithelial Cells for Sputum Quality Grading using
K-means Clustering and Color Thresholding. Computing and Convergence
Technology (ICCCT), 2012 7th International Conference. 1378-1383.
Hudai, F., Hua, W., Wei, Y. (2009, August 26-27). Application of Mixed Programming
between Matlab and Visual C++ on Circles Detection, IEEE. 53-57.
JJustad, M.D. (2010, November 17). Best Practice Guidelines: Urinary Tract Infections.
Retrieved from Department of Public Health and Human Services, Montana Website:
http://www.dphhs.mt.gov/dsd/ddp/documents/UrinaryTractInfections.pdf
Kapitza, H.G. (1997). Microscopy from the very beginning. Germany: Carl Zeiss Jena
GmbH. Retrieved October 27, 2013
44
Karargyris, A., Karargyris, O., and Pantelopoulos, A. (2012). DERMA/care: An
advanced Image Processing Mobile Application for Monitoring Skin Cancer. Tools
with Artificial Intelligence (ICTAI). 1-7.
Leboffe, M., & Pierce, B. (2011). A Photographic Atlas for the Microbiology Laboratory
(4th ed.). Retrieved November 4, 2013, from
http://bib.convdocs.org/docs/3/2152/conv_1/file1.pdf
Lee, D., Jang W.I., Jung, M.Y., Jeon, B.G., & Ihm, C. (2011). A Pocket-sized
Colorimetric Urine Reader for Telemedicine in the Developing Countries. 2011 IEEE
Sensors. 1495-1498.
Lockwood, W. R.N. (2011). The Complete Urinalysis and Urine Tests. Retrieved
October 7, 2013 from http://doczine.com/bigdata/1/1365798558_62335a64cb/coursematerial-
265.pdf
Matsuka, S., Hudec R., & Benco M. (2012). The Comparison of CPU Time Consumption
for Image Processing Algorithm in Matlab and OpenCV, ELEKTRO. 75-78. doi:
10.1109/ELEKTRO.2012.6225575
Mudanyali, O., Tseng, D., Isikman, S., Oztropak, C., Sencan I., Bishara, W., Taglidere,
O., & Ozana, A. (2011). Compact and Cost-effective Lensless Telemedicine
Microscopy for Global Health Applications. University of California, Los Angeles
(UCLA) Los Angeles, CA, USA. Global Humanitarian Technology Conference
(GHTC). 62-65.
45
National Kidney and Urologic Diseases Information Clearinghouse. (2011). Urinary
Tract Infenctions in Adult. (NIH Publication No. 122097). Bethesda, MD:
NKUDIC. Retrieved from http://kidney.niddk.nih.gov/KUDiseases/pubs/utiadult/index.aspx
NCCLS. (2001). Urinalysis and Collection, Transportation, and Preservation of Urine
Specimens. NCCLS document GP16-A2. Pennsylvania, USA: NCCLS. Retrieved
November 2, 2013, from http://isoforlab.com/phocadownload/csli/GP16-A2.pdf
Rai, Alex J. (2010). The Urinary Proteome: Methods and Protocols. New York, NY:
Humana Press.
Rhody, H. (2005, October 11). Hough Circle Transform. Rochester Institute of
Technology. Retrieved November 10, 2013, from
http://www.cis.rit.edu/class/simg782/lectures/lecture_10/lec782_05_10.pdf
Simerville, J. A. M.D., Maxted W. C. M.D., & Pahira J. J. M.D. (2005, March 15).
Urinalysis: A Comprehensive Review. American Family Physician, 71(6), 1153
1162. Retrieved October 5, 2013 from http://www.aafp.org/afp/2005/0315/p1153.html
Smith, B., & Foster, K.A. (2003, November 5). The Urine Microscopic Analysis of Urine
Sediment. Dayton, OH: Education Materials for Health Professionals. Retrieved
October 22, 2013, from https://www.medialabinc.net/courses/courseinfo.aspx?courseid=609
Stegall, M. J. (2007). Urine Samples and urinalysis. Nursing Standard. 22, 14-16, 42-45.
Sumriddetchkajorn, S., Somboonkaew, A., & Chanhornm, S. (2012). Mobile Device-
Based Digital Microscopy for Education, Healthcare, and Agriculture. Electrical
46
Engineering/Electronics, Computer, Telecommunications and Information
Technology (ECTI-CON). 14.
uChek. (2013). Urine Analysis Simplified. Retrieved October 19, 2013 from
https://sites.google.com/site/ucheksystem/customer-support
Velikova, M., Lucas, P. J. F., Smeets R.L., & Terwisscha van Scheltinga, J. (2012). Fully-
automated Interpretation of Biochemical Tests for Decision Support by Smartphones.
Computer-Based Medical Systems (CBMS). 16.
Williams, L. (September 2013). Urinalysis - New Technologies, New Potential. Medical
Laboratory Observer.
47
APPENDICES
Appendix A: Gantt Chart
48
Appendix B: Proposed Costing
EQUIPMENT
(MODEL)
QUANTITY PRICE
UF003124(Microscope
Lens)
1
$22.99
= 1003.28
*Lenovo Ideapad
G480(Laptop)
1 14,995.00
*Apple iPhone
5(Smartphone)
1
$664.99
= 29,020.16
*Open CV 1 Free (Open Source)
Visual Studio
Professional
1 75,825.91
My SQL 1 Free (Open Source)
Clinical equipment - Sponsored
Transportation - 10,000.00
Supplies - 5,000.00
*Already available Total: 135,844.35
Price Reference
http://www.usbfever.com/index_eproduct_view.php?products_id=2878
http://www.pccorner.com.ph/products.do?action=showproductdetail&typeid=23&categor
yid=56&productid=6111
http://www.amazon.com/Apple-iPhone-16GB-White-Unlocked/dp/B0097CZJEO
http://www.visualstudio.com/products/how-to-buy-vs
49