| Literature DB >> 36230030 |
Ewa Ropelewska1, Kadir Sabanci2, Muhammet Fatih Aslan2.
Abstract
Food processing allows for maintaining the quality of perishable products and extending their shelf life. Nondestructive procedures combining image analysis and machine learning can be used to control the quality of processed foods. This study was aimed at developing an innovative approach to distinguishing fresh and lacto-fermented red bell pepper samples involving selected image textures and machine learning algorithms. Before processing, the pieces of fresh pepper and samples subjected to spontaneous lacto-fermentation were imaged using a digital camera. The texture parameters were extracted from images converted to different color channels L, a, b, R, G, B, X, Y, and Z. The textures after selection were used to build models for the classification of fresh and lacto-fermented samples using algorithms from the groups of Lazy, Functions, Trees, Bayes, Meta, and Rules. The highest average accuracy of classification reached 99% for the models developed based on sets of selected textures for color space Lab using the IBk (instance-based K-nearest learner) algorithm from the group of Lazy, color space RGB using SMO (sequential minimal optimization) from Functions, and color space XYZ and color channel X using IBk (Lazy) and SMO (Functions). The results confirmed the differences in image features of fresh and lacto-fermented red bell pepper and revealed the effectiveness of models built based on textures using machine learning algorithms for the evaluation of the changes in the pepper flesh structure caused by processing.Entities:
Keywords: discrimination; image processing; machine learning algorithms; pepper preservation; spontaneous lacto-fermentation; texture parameters
Year: 2022 PMID: 36230030 PMCID: PMC9563776 DOI: 10.3390/foods11192956
Source DB: PubMed Journal: Foods ISSN: 2304-8158
Figure 1The sample of red bell pepper fruit used in the experiments.
Figure 2The original digital color images of samples of fresh and lacto-fermented bell pepper (a) and images converted to selected color channels: a (b); R (c); G (d); X (e).
Figure 3A flowchart presenting steps of distinguishing fresh and lacto-fermented red bell pepper samples using image textures and machine learning algorithms.
The selected texture parameters used to develop the models to distinguish fresh and lacto-fermented red bell pepper samples.
| Color Space Lab | Color Channel | Color Space RGB | Color Channel | Color Space XYZ | Color Channel |
|---|---|---|---|---|---|
| LHMean | LHMean LHPerc01 | RHPerc10 | RHPerc10 | XHPerc10 | XHPerc10 |
The performance metrics of discrimination of fresh and lacto-fermented red bell pepper samples using selected image textures from color space Lab.
| Algorithm | Predicted Class (%) | Actual Class | Average Accuracy (%) | Precision | F-Measure | MCC | |
|---|---|---|---|---|---|---|---|
| Fresh | Lacto-Fermented | ||||||
| IBk | 98 | 2 | Fresh | 99 | 1.000 | 0.990 | 0.980 |
| 0 | 100 | Lacto-fermented | 0.980 | 0.990 | 0.980 | ||
| SMO (Functions) | 98 | 2 | Fresh | 98 | 0.980 | 0.980 | 0.960 |
| 2 | 98 | Lacto-fermented | 0.980 | 0.980 | 0.960 | ||
| Random forest | 97 | 3 | Fresh | 98 | 0.990 | 0.980 | 0.960 |
| 1 | 99 | Lacto-fermented | 0.971 | 0.980 | 0.960 | ||
| Naïve Bayes | 99 | 1 | Fresh | 98 | 0.971 | 0.980 | 0.960 |
| 3 | 97 | Lacto-fermented | 0.990 | 0.980 | 0.960 | ||
| Filtered classifier | 97 | 3 | Fresh | 97 | 0.970 | 0.970 | 0.940 |
| 3 | 97 | Lacto-fermented | 0.970 | 0.970 | 0.940 | ||
| JRip | 96 | 4 | Fresh | 96.5 | 0.970 | 0.965 | 0.930 |
| 3 | 97 | Lacto-fermented | 0.960 | 0.965 | 0.930 | ||
MCC—Matthews correlation coefficient.
The results of discrimination of fresh and lacto-fermented red bell pepper samples using selected image textures from color channel L.
| Algorithm | Predicted Class (%) | Actual Class | Average Accuracy (%) | Precision | F-Measure | MCC | |
|---|---|---|---|---|---|---|---|
| Fresh | Lacto-Fermented | ||||||
| IBk | 98 | 2 | Fresh | 98 | 0.980 | 0.980 | 0.960 |
| 2 | 98 | Lacto-fermented | 0.980 | 0.980 | 0.960 | ||
| SMO (Functions) | 98 | 2 | Fresh | 98 | 0.980 | 0.980 | 0.960 |
| 2 | 98 | Lacto-fermented | 0.980 | 0.980 | 0.960 | ||
| Random forest | 98 | 2 | Fresh | 98.5 | 0.990 | 0.985 | 0.970 |
| 1 | 99 | Lacto-fermented | 0.980 | 0.985 | 0.970 | ||
| Naïve Bayes | 97 | 3 | Fresh | 97 | 0.970 | 0.970 | 0.940 |
| 3 | 97 | Lacto-fermented | 0.970 | 0.970 | 0.940 | ||
| Filtered classifier | 97 | 3 | Fresh | 97 | 0.970 | 0.970 | 0.940 |
| 3 | 97 | Lacto-fermented | 0.970 | 0.970 | 0.940 | ||
| JRip | 97 | 3 | Fresh | 96.5 | 0.960 | 0.965 | 0.930 |
| 4 | 96 | Lacto-fermented | 0.970 | 0.965 | 0.930 | ||
MCC—Matthews correlation coefficient.
The discrimination of fresh and lacto-fermented red bell pepper samples based on models developed using selected image textures from color space RGB.
| Algorithm | Predicted Class (%) | Actual Class | Average Accuracy (%) | Precision | F-Measure | MCC | |
|---|---|---|---|---|---|---|---|
| Fresh | Lacto-Fermented | ||||||
| IBk | 98 | 2 | Fresh | 98.5 | 0.990 | 0.985 | 0.970 |
| 1 | 99 | Lacto-fermented | 0.980 | 0.985 | 0.970 | ||
| SMO (Functions) | 100 | 0 | Fresh | 99 | 0.980 | 0.990 | 0.980 |
| 2 | 98 | Lacto-fermented | 1.000 | 0.990 | 0.980 | ||
| Random forest | 96 | 4 | Fresh | 96.5 | 0.970 | 0.965 | 0.930 |
| 3 | 97 | Lacto-fermented | 0.960 | 0.965 | 0.930 | ||
| Naïve Bayes | 99 | 1 | Fresh | 98.5 | 0.980 | 0.985 | 0.970 |
| 2 | 98 | Lacto-fermented | 0.990 | 0.985 | 0.970 | ||
| Filtered classifier | 94 | 6 | Fresh | 93 | 0.922 | 0.931 | 0.860 |
| 8 | 92 | Lacto-fermented | 0.939 | 0.929 | 0.860 | ||
| JRip | 91 | 9 | Fresh | 93.5 | 0.958 | 0.933 | 0.871 |
| 4 | 96 | Lacto-fermented | 0.914 | 0.937 | 0.871 | ||
MCC—Matthews correlation coefficient.
The performance metrics of distinguishing fresh and lacto-fermented red bell pepper samples using selected image textures from color channel R.
| Algorithm | Predicted Class (%) | Actual Class | Average Accuracy (%) | Precision | F-Measure | MCC | |
|---|---|---|---|---|---|---|---|
| Fresh | Lacto-Fermented | ||||||
| IBk | 98 | 2 | Fresh | 97.5 | 0.970 | 0.975 | 0.950 |
| 3 | 97 | Lacto-fermented | 0.980 | 0.975 | 0.950 | ||
| SMO (Functions) | 99 | 1 | Fresh | 98.5 | 0.980 | 0.985 | 0.970 |
| 2 | 98 | Lacto-fermented | 0.990 | 0.985 | 0.970 | ||
| Random forest | 96 | 4 | Fresh | 97 | 0.980 | 0.970 | 0.940 |
| 2 | 98 | Lacto-fermented | 0.961 | 0.970 | 0.940 | ||
| Naïve Bayes | 95 | 5 | Fresh | 96 | 0.969 | 0.960 | 0.920 |
| 3 | 97 | Lacto-fermented | 0.951 | 0.960 | 0.920 | ||
| Filtered classifier | 94 | 6 | Fresh | 91.5 | 0.895 | 0.917 | 0.831 |
| 11 | 89 | Lacto-fermented | 0.937 | 0.913 | 0.831 | ||
| JRip | 89 | 11 | Fresh | 90.5 | 0.918 | 0.904 | 0.810 |
| 8 | 92 | Lacto-fermented | 0.893 | 0.906 | 0.810 | ||
MCC—Matthews correlation coefficient.
The discrimination performance metrics for models developed on the basis of selected image textures from color space XYZ for distinguishing fresh and lacto-fermented red bell pepper samples.
| Algorithm | Predicted Class (%) | Actual Class | Average Accuracy (%) | Precision | F-Measure | MCC | |
|---|---|---|---|---|---|---|---|
| Fresh | Lacto-Fermented | ||||||
| IBk | 99 | 1 | Fresh | 99 | 0.990 | 0.990 | 0.980 |
| 1 | 99 | Lacto-fermented | 0.990 | 0.990 | 0.980 | ||
| SMO (Functions) | 100 | 0 | Fresh | 99 | 0.980 | 0.990 | 0.980 |
| 2 | 98 | Lacto-fermented | 1.000 | 0.990 | 0.980 | ||
| Random forest | 97 | 3 | Fresh | 98 | 0.990 | 0.980 | 0.960 |
| 1 | 99 | Lacto-fermented | 0.971 | 0.980 | 0.960 | ||
| Naïve Bayes | 98 | 2 | Fresh | 98 | 0.980 | 0.980 | 0.960 |
| 2 | 98 | Lacto-fermented | 0.980 | 0.980 | 0.960 | ||
| Filtered classifier | 95 | 5 | Fresh | 97 | 0.990 | 0.969 | 0.941 |
| 1 | 99 | Lacto-fermented | 0.952 | 0.971 | 0.941 | ||
| JRip | 95 | 5 | Fresh | 96.5 | 0.979 | 0.964 | 0.930 |
| 2 | 98 | Lacto-fermented | 0.951 | 0.966 | 0.930 | ||
MCC—Matthews correlation coefficient.
The results of distinguishing fresh and lacto-fermented red bell pepper samples using selected image textures from color channel X.
| Algorithm | Predicted Class (%) | Actual Class | Average Accuracy (%) | Precision | F-Measure | MCC | |
|---|---|---|---|---|---|---|---|
| Fresh | Lacto-Fermented | ||||||
| IBk | 99 | 1 | Fresh | 99 | 0.990 | 0.990 | 0.980 |
| 1 | 99 | Lacto-fermented | 0.990 | 0.990 | 0.980 | ||
| SMO (Functions) | 100 | 0 | Fresh | 99 | 0.980 | 0.990 | 0.980 |
| 2 | 98 | Lacto-fermented | 1.000 | 0.990 | 0.980 | ||
| Random forest | 96 | 4 | Fresh | 97 | 0.980 | 0.970 | 0.940 |
| 2 | 98 | Lacto-fermented | 0.961 | 0.970 | 0.940 | ||
| Naïve Bayes | 99 | 1 | Fresh | 98.5 | 0.980 | 0.985 | 0.970 |
| 2 | 98 | Lacto-fermented | 0.990 | 0.985 | 0.970 | ||
| Filtered classifier | 93 | 7 | Fresh | 95.5 | 0.979 | 0.954 | 0.911 |
| 2 | 98 | Lacto-fermented | 0.933 | 0.956 | 0.911 | ||
| JRip | 94 | 6 | Fresh | 93.5 | 0.931 | 0.935 | 0.870 |
| 7 | 93 | Lacto-fermented | 0.939 | 0.935 | 0.870 | ||
MCC—Matthews correlation coefficient.