Cargando…
Improved YOLOv4-tiny based on attention mechanism for skin detection
BACKGROUND: An automatic bathing robot needs to identify the area to be bathed in order to perform visually-guided bathing tasks. Skin detection is the first step. The deep convolutional neural network (CNN)-based object detection algorithm shows excellent robustness to light and environmental chang...
Autores principales: | , , , , |
---|---|
Formato: | Online Artículo Texto |
Lenguaje: | English |
Publicado: |
PeerJ Inc.
2023
|
Materias: | |
Acceso en línea: | https://www.ncbi.nlm.nih.gov/pmc/articles/PMC10280476/ https://www.ncbi.nlm.nih.gov/pubmed/37346516 http://dx.doi.org/10.7717/peerj-cs.1288 |
_version_ | 1785060802294710272 |
---|---|
author | Li, Ping Han, Taiyu Ren, Yifei Xu, Peng Yu, Hongliu |
author_facet | Li, Ping Han, Taiyu Ren, Yifei Xu, Peng Yu, Hongliu |
author_sort | Li, Ping |
collection | PubMed |
description | BACKGROUND: An automatic bathing robot needs to identify the area to be bathed in order to perform visually-guided bathing tasks. Skin detection is the first step. The deep convolutional neural network (CNN)-based object detection algorithm shows excellent robustness to light and environmental changes when performing skin detection. The one-stage object detection algorithm has good real-time performance, and is widely used in practical projects. METHODS: In our previous work, we performed skin detection using Faster R-CNN (ResNet50 as backbone), Faster R-CNN (MobileNetV2 as backbone), YOLOv3 (DarkNet53 as backbone), YOLOv4 (CSPDarknet53 as backbone), and CenterNet (Hourglass as backbone), and found that YOLOv4 had the best performance. In this study, we considered the convenience of practical deployment and used the lightweight version of YOLOv4, i.e., YOLOv4-tiny, for skin detection. Additionally, we added three kinds of attention mechanisms to strengthen feature extraction: SE, ECA, and CBAM. We added the attention module to the two feature layers of the backbone output. In the enhanced feature extraction network part, we applied the attention module to the up-sampled features. For full comparison, we used other lightweight methods that use MobileNetV1, MobileNetV2, and MobileNetV3 as the backbone of YOLOv4. We established a comprehensive evaluation index to evaluate the performance of the models that mainly reflected the balance between model size and mAP. RESULTS: The experimental results revealed that the weight file of YOLOv4-tiny without attention mechanisms was reduced to 9.2% of YOLOv4, but the mAP maintained 67.3% of YOLOv4. YOLOv4-tiny’s performance improved after combining the CBAM and ECA modules, but the addition of SE deteriorated the performance of YOLOv4-tiny. MobileNetVX_YOLOv4 (X = 1, 2, 3), which used MobileNetV1, MobileNetV2, and MobileNetV3 as the backbone of YOLOv4, showed higher mAP than YOLOv4-tiny series (including YOLOv4-tiny and three improved YOLOv4-tiny based on the attention mechanism) but had a larger weight file. The network performance was evaluated using the comprehensive evaluation index. The model, which integrates the CBAM attention mechanism and YOLOv4-tiny, achieved a good balance between model size and detection accuracy. |
format | Online Article Text |
id | pubmed-10280476 |
institution | National Center for Biotechnology Information |
language | English |
publishDate | 2023 |
publisher | PeerJ Inc. |
record_format | MEDLINE/PubMed |
spelling | pubmed-102804762023-06-21 Improved YOLOv4-tiny based on attention mechanism for skin detection Li, Ping Han, Taiyu Ren, Yifei Xu, Peng Yu, Hongliu PeerJ Comput Sci Artificial Intelligence BACKGROUND: An automatic bathing robot needs to identify the area to be bathed in order to perform visually-guided bathing tasks. Skin detection is the first step. The deep convolutional neural network (CNN)-based object detection algorithm shows excellent robustness to light and environmental changes when performing skin detection. The one-stage object detection algorithm has good real-time performance, and is widely used in practical projects. METHODS: In our previous work, we performed skin detection using Faster R-CNN (ResNet50 as backbone), Faster R-CNN (MobileNetV2 as backbone), YOLOv3 (DarkNet53 as backbone), YOLOv4 (CSPDarknet53 as backbone), and CenterNet (Hourglass as backbone), and found that YOLOv4 had the best performance. In this study, we considered the convenience of practical deployment and used the lightweight version of YOLOv4, i.e., YOLOv4-tiny, for skin detection. Additionally, we added three kinds of attention mechanisms to strengthen feature extraction: SE, ECA, and CBAM. We added the attention module to the two feature layers of the backbone output. In the enhanced feature extraction network part, we applied the attention module to the up-sampled features. For full comparison, we used other lightweight methods that use MobileNetV1, MobileNetV2, and MobileNetV3 as the backbone of YOLOv4. We established a comprehensive evaluation index to evaluate the performance of the models that mainly reflected the balance between model size and mAP. RESULTS: The experimental results revealed that the weight file of YOLOv4-tiny without attention mechanisms was reduced to 9.2% of YOLOv4, but the mAP maintained 67.3% of YOLOv4. YOLOv4-tiny’s performance improved after combining the CBAM and ECA modules, but the addition of SE deteriorated the performance of YOLOv4-tiny. MobileNetVX_YOLOv4 (X = 1, 2, 3), which used MobileNetV1, MobileNetV2, and MobileNetV3 as the backbone of YOLOv4, showed higher mAP than YOLOv4-tiny series (including YOLOv4-tiny and three improved YOLOv4-tiny based on the attention mechanism) but had a larger weight file. The network performance was evaluated using the comprehensive evaluation index. The model, which integrates the CBAM attention mechanism and YOLOv4-tiny, achieved a good balance between model size and detection accuracy. PeerJ Inc. 2023-03-10 /pmc/articles/PMC10280476/ /pubmed/37346516 http://dx.doi.org/10.7717/peerj-cs.1288 Text en © 2023 Li et al. https://creativecommons.org/licenses/by/4.0/This is an open access article distributed under the terms of the Creative Commons Attribution License (https://creativecommons.org/licenses/by/4.0/) , which permits unrestricted use, distribution, reproduction and adaptation in any medium and for any purpose provided that it is properly attributed. For attribution, the original author(s), title, publication source (PeerJ Computer Science) and either DOI or URL of the article must be cited. |
spellingShingle | Artificial Intelligence Li, Ping Han, Taiyu Ren, Yifei Xu, Peng Yu, Hongliu Improved YOLOv4-tiny based on attention mechanism for skin detection |
title | Improved YOLOv4-tiny based on attention mechanism for skin detection |
title_full | Improved YOLOv4-tiny based on attention mechanism for skin detection |
title_fullStr | Improved YOLOv4-tiny based on attention mechanism for skin detection |
title_full_unstemmed | Improved YOLOv4-tiny based on attention mechanism for skin detection |
title_short | Improved YOLOv4-tiny based on attention mechanism for skin detection |
title_sort | improved yolov4-tiny based on attention mechanism for skin detection |
topic | Artificial Intelligence |
url | https://www.ncbi.nlm.nih.gov/pmc/articles/PMC10280476/ https://www.ncbi.nlm.nih.gov/pubmed/37346516 http://dx.doi.org/10.7717/peerj-cs.1288 |
work_keys_str_mv | AT liping improvedyolov4tinybasedonattentionmechanismforskindetection AT hantaiyu improvedyolov4tinybasedonattentionmechanismforskindetection AT renyifei improvedyolov4tinybasedonattentionmechanismforskindetection AT xupeng improvedyolov4tinybasedonattentionmechanismforskindetection AT yuhongliu improvedyolov4tinybasedonattentionmechanismforskindetection |