Desarrollo de una aplicación móvil con Android Studio y OpenCV para la clasificación de tuercas, tornillos y arandelas.

Cargando...
Miniatura

Fecha

Director/Asesor

Contribuidores

Título de la revista

ISSN de la revista

Título del volumen

Editor

Título del libro

Tipo

Otro

Seleccione un documento PDF para visualizar

Resumen

En este proyecto se desarrolló una aplicación móvil (DetectApp) usando el IDE Android Studio enlazado a las librerías OpenCV, donde se implementó el algoritmo KNN logrando la clasificación 3 objetos (tuercas, tonillos y arandelas). Inicialmente, se realizó una breve revisión bibliografía del algoritmo KNN y su uso en la visión artificial y el machine learning. El funcionamiento de la aplicación móvil consiste en leer la imagen, convertirla del espacio de color RGB al espacio de color HSV, luego se hallan los umbrales para detectar solo los objetos de interés, se aplica un filtro gaussiano para reducir el ruido y luego se realiza un procesamiento de imagen que extrae características únicas de los objetos, en este caso relacionadas con los primeros seis momentos invariantes de Hu. Posteriormente el algoritmo KNN se encarga de clasificar cada objeto en una clase determinada (tuerca, tornillo, arandela), el cual fue validado mediante pruebas de funcionamiento que consistieron en tomar varias fotografías de los objetos variando la distancia entre la cámara y el objeto, la posición y la rotación de los objetos de donde se obtuvieron buenos resultados que permiten afirmar que este algoritmo puede ser implementado en otro tipo de aplicaciones. El funcionamiento del algoritmo se comprobó usando la matriz de confusión dando como resultado una exactitud mayor al 95% para cada uno de los 3 objetos. Finalmente, se diseñó una interfaz de usuario que permite seleccionar si se desea hacer una clasificación con video en línea, tomar una fotografía o buscar una fotografía en la galería del teléfono.


In this research project it was developed a mobile application (DetectApp) using the Android Studio IDE linked to OpenCV libraries, where the KNN algorithm was implemented obtaining the classification of 3 objects (nuts, bolts and washers). First a a brief literature review of the KNN algorithm is explained and its use in computer vision and machine learning was performed. The operation of the mobile application consists in image reading, converting the image from RGB color space to HSV color space, then thresholds are found to detect only the objects of interest, a Gaussian filter is applied to reduce noise, and then image processing is performed to extract unique features of the objects, in this case related to the first six invariant Hu moments. Subsequently, the KNN algorithm is in charge of classifying each object in a specific class (nut, screw, washer), which was validated through performance tests that consist in taking several photographs of the objects by varying the distance between the camera and the object, the position and the rotation of the objects from which good results were obtained that allow us to affirm that this algorithm can be implemented in other types of applications. The performance of the algorithm was tested using the confusion matrix resulting in 95% of accuracy for each one of the 3 objects. Finally, an user interface was designed to allow the user to select whether to make a classification with online video, take a photograph or search for a photograph in the phone's gallery.

Citación

ISSN

ISBN

Aprobación

Revisión

Complementado por

Referenciado por

Licencia Creative Commons

Excepto donde se indique lo contrario, la licencia de este ítem se describe como Attribution-NonCommercial-NoDerivatives 4.0 Internacional