An enhanced algorithmic approach for automatic defects detection in green coffee beans

Christian E.Portugal Zambrano, Juan Carlos Gutierrez Caceres, Juan Ramirez Ticona, Norman J. Beltran-Castanon, Jose M.Ramos Cutipa, Cesar A. Beltran-Castanon

Research output: Contribution to conferencePaperpeer-review


Classification green coffee beans is one of the main tasks during the quality grading process. This evaluation is normally carried out by specialist doing a visual inspection or using traditional instruments which have some limitations. This work is focused on the implementation of a computer vision system combining a hardware prototype and a software module. The hardware was made to guarantee the controlled conditions to capture the images of green coffee beans, the software is based on computer vision algorithms in order to detect defects of the coffee beans. The novelty of our proposal is the combination of algorithms to enhance the accuracy and the high number of defects detected. We applied a White Patch algorithm as an image enhancement procedure, color histograms as feature extractor and Support Vector Machine (SVM) for the classification task. It was constituted an image beans database of 1930 instances, and it was extracted 768 features, finally, the model was applied over 13 categories of defects described by the Specialty Coffee Association of America (SCAA). Results of classification achieved a 98.8% of overall accuracy detection, therefore the proposed system proved to be effective in classifying physical defects of green coffee beans. With this work we showed that the grading green coffee process can be automatized, adding a new paradigm in quality evaluation task to enhance the coffee industry.

Original languageEnglish
Number of pages8
StatePublished - 2018
Event9th International Conference on Pattern Recognition Systems, ICPRS 2018 - Valparaiso, Chile
Duration: 22 May 201824 May 2018


Conference9th International Conference on Pattern Recognition Systems, ICPRS 2018

Bibliographical note

Funding Information:
The authors would like to thank CECOVASA (Central Cooper-ativa Agrarias Cafetaleras de los Valles de Sandia Ltda.) who provided the support and knowledge necessary for the development of the research. This work has been subsidized by Fondo Nacional de Desarrollo Cientfico, Tecnolgico y de In-novacin Tecnolgica (FONDECYT), through contract No. 143-2013-FONDECYT between the Universidad Nacional de San Agustin and CONCYTEC.

Publisher Copyright:
© 2018 Institution of Engineering and Technology. All rights reserved.


  • Coffee beans defects
  • Computer vision
  • Grading green coffee
  • White Patch


Dive into the research topics of 'An enhanced algorithmic approach for automatic defects detection in green coffee beans'. Together they form a unique fingerprint.

Cite this