# Method for Enhancing AI Accuracy in Pressure Injury Detection Using Real and Synthetic Datasets
## 4 Experimental Results
### Result  
We demonstrated the quality of the synthetic PI images generated using the stable diffusion model by providing synthetic images for each PI class. Table 3 lists the real and synthetic images of the PI. Each synthetic image was generated by training on the real images of the corresponding class. The t-distributed stochastic neighbor embedding (t-SNE) graph in Figure 4 visualizes the feature distribution of the synthetic data generated in this study alongside the actual data on a two-dimensional plane. The feature distributions of the real, synthetic, and hybrid data are displayed from left to right. Each dot represents a data point, and each color corresponds to a different class. As illustrated in the figure, the synthetic data captured the structure and patterns of the real data, with the features being relatively clearly differentiated. The density and distribution of each class were distinctly separated, indicating that the synthetic data were generated in a manner that may be more favorable for learning than the original data. These results suggest that the synthetic data faithfully reflect the characteristics of real data and can be effectively used in conjunction with real \begin{table}
\begin{tabular}{c c c c c c c c} \hline \hline
**Category** & **Stage 1 PI \({}^{*}\)** & **Stage 2 PI** & **Stage 3 PI** & **Stage 4 PI** & **Deep Tissue PI** & **Unstageable PI** & **Total** \\ \hline Real Data & 454 (13\%) & 452 (13\%) & 274 (8\%) & 598 (18\%) & 789 (23\%) & 832 (24\%) & 3399 (100\%) \\ Synthetic Data & 500 (15\%) & 500 (15\%) & 500 (15\%) & 500 (15\%) & 500 (15\%) & 500 (15\%) & 3000 (100\%) \\ \hline \hline \end{tabular}  
* PI = Pressure Injury.  
\end{table} 
Table 2: PI dataset construction table. data. Relying solely on synthetic data poses a high risk of overfitting the learning model due to the distinct features present in the synthetic data. However, when used in conjunction with real data, a model that generalizes well can be trained. Figure 5 illustrates the confusion matrices and receiver operating characteristic (ROC) curves for the real, synthetic, balanced, and hybrid datasets. Element (i, j) of each confusion matrix represents the empirical probability of predicting class j given that the ground truth is class i. In the ROC curve, the area under the curve (AUC) represents the classifier's performance, with values closer to 1 indicating better performance. The false-positive rate (FPR) on the \(x\)-axis represents the proportion of actual negative samples that the model incorrectly predicted as positive. The true-positive rate (TPR) on the \(y\)-axis represents the proportion of actual positive samples that the model correctly predicted as positive. Table 4 presents the precision, recall, F1 score, and processing time of the training results. The hybrid data showed higher precision, recall, and F1 scores compared to the results obtained using the real dataset. A hybrid dataset was created by combining the real and synthetic datasets. The balanced dataset was constructed by combining 200 real and 200 synthetic samples. Of the real datasets, 100 were allocated for validation and testing, and the remaining were used for training. The hybrid was all of the data including real and synthetic datasets. Table 5 lists the accuracies obtained from the experiments using the four types of datasets. The overall accuracy of the PI classifier using the synthetic image dataset was the lowest among the real, synthetic, balanced, and hybrid datasets. However, the top-1 and top-2 accuracies of the classifier trained on the hybrid image datasets were higher than those of the classifier trained solely on the real dataset. Figure 4: Comparison of feature distribution through t-SNE visualization of real, synthetic, balanced, and hybrid datasets. (**a**) Real dataset. (**b**) Synthetic dataset. (**c**) Balanced dataset. (**d**) Hybrid dataset.