An Efficient Scheme for Automatic Pill Recognition Using Neural Networks

R. Chughtai, G. Raja, J. Mir, F. Shaukat


An efficient scheme, capable of extracting key pill features, for an automatic pill recognition is proposed.
The devised system involves a number of processes which starts with the thresholding applied to the
input query pill image for extraction of the shape feature vector and generation of mask images. The
extracted shape feature vector is used for shape recognition through a trained neural network.
Information regarding the color and size of the pill is obtained by using the mask images and shape
information. For pill imprint extraction, a modified stroke width transform (MSWT) and two-step
sampling is applied. The extracted pill query features are compared with the feature values of the created
database for recognition of the pill and its purpose. The proposed method is evaluated on a dataset of
2500 images and achieves an accuracy of 98% which shows the supremacy of the proposed method in
comparison to the other similar pill recognition systems.

Full Text:



CFR- Code of Federal Regulations Title 21, “US food and drug administration homepage”, Available: http:// www.accessdata.fda. gov/scripts/cdrh/cfdocs/cfcfr/CFRSearch.cfm?CFRPart=211, 2015

WebMD Pill Identification Tool, “Pill identification homepage”, Available: [Accessed: 2018].

National Library of Medicine, National Institutes of Health, United States, “Pillbox homepage”, Available: developer.html [Accessed: 2018].

RxList Pill Identification Tool, “Pill-identification-tool homepage”, available at [Accessed: 2018].

Pill Identification Tool, “Pill identification homepage”, Available: [Accessed: 2018]

Healthline Pill Identifier, “Pill-identifier homepage”, Available: [Accessed: 2018].

J. Yu and Z. Chen, “Accurate system for automatic pill recognition using imprint information”, IET Image Process., vol. 9, no. 12, pp. 1039-1047, 2015.

M.A.V. Neto, J.W.M. de Souza, P.P. Reboucas Filho and W.D.O. Antonio, "CoforDes: An invariant feature extractor for the drug pill identification", IEEE 31st Int. Symp. on Computer-Based Medical Systems (CBMS), Karlstad, pp. 30-35, 2018.

J.S. Wang, A. Ambikapathi, Y. Han, S.L. Chung, H.W. Ting and C.F. Chen, "Highlighted deep learning based identification of pharmaceutical blister packages”, IEEE 23rd Int. Conf. on Emerging Technologies and Factory Automation (ETFA), Turin, pp. 638-645, 2018.

R. Palenychka, A. Lakhssassi and M. Palenychka, "Verification of medication dispensing using the attentive computer vision approach", IEEE Intl. Symp. on Circuits and Systems (ISCAS), Florence, pp. 1-4, 2018.

Y.F. Wong, H.T. Ng, K.Y. Leung, K.Y. Chan, S.Y. Chan and C.C. Loy,” Development of fine-grained pill identification algorithm using deep convolutional network”, Journal of Biomedical Informatics, vol. 74, pp. 130-136, 2017.

A. Hartl, “Computer-vision based pharmaceutical pill recognition on mobile phones”, Proc. 14th Central European Seminar on Computer Graphics, pp. 5, 2010.

T.H. Huynh and T.S. Nguyen, “A new imprinted tablet recognition algorithm using polar transform and neural networks”, Int. Conf. on Advanced Technologies for Communications (ATC), pp. 38-43, 2015.

M.K. Hu, “Visual pattern recognition by moment invariants”, IRE Trans. Inf. Theory, pp. 179-187, 1962.

Z. Chen and S.I. Kamata, “A new accurate pill recognition system using imprint information”, Sixth Int. Conf. Machine Vision, London, UK, pp. 906711, Dec. 2013.

J.J. Caban, A. Rosebrock and T.S. Yoo, “Automatic identification of prescription drugs using shape distribution models”, IEEE 19th Int. Conf. Image Process., pp. 1005-1008, 2012.

C. Grigorescu and N. Petkov, “Distance sets for shape filters and shape recognition”, IEEE Trans. Image Process., vol. 12, no. 10, pp. 1274-1286, 2003.

S. Siroratt and R. Sukanya, “Pill image binarization for detecting text imprints”, 13th Int. Conf. Computer Science and Software Engineering (CSSE), pp. 978-983, 2016.

R. Osada, T. Funkhouser, B. Chazelle and D. Dobkin, “Shape distributions”, ACM Trans. Graphics, vol. 4, pp. 807–832, 2002

Y.B. Lee, U. Park and A.K. Jain, “Pill-ID: Matching and retrieval of drug pill imprint images”, IEEE Proc. 20th Int. Conf. Pattern Recognition, pp. 2632-2635, August, 2010.

S. Belongie, J. Malik and J. Puzicha, “Shape matching and object recognition using shape contexts”, IEEE Trans. on Pattern Analysis and Machine Intelligence, vol. 24, no. 4, pp. 509-522, 2002.

B. Epshtein, E. Ofek and Y. Wexler, “Detecting text in natural scenes with stroke width transform”, IEEE Computer Society Conf. on Computer Vision and Pattern Recognition , pp. 2963-2970, 2010.

H. Chen, S.S. Tsai, G. Schroth, D.M. Chen, R. Grzeszczuk and B. Girod, “Robust text detection in natural images with edge-enhanced maximally stable extremal regions”, IEEE 18th Int. Conf. on Image Process., pp. 2609-2612, 2011.

M.A. Rahman, R.A. Kabir, Z. Begum and M.M. Haque, "A study of human recognition using inner joining lines of fingers,"5th Int. Conf. on Computer Sciences and Convergence Information Technology, Seoul, pp. 186-191, 2010.


  • There are currently no refbacks.