## 5 Comparison and Discussion
Despite the discrepancy between the 512 output units in the penultimate layer of RESNET-18 and the 6763 classes in CASIA-HWDB, the model's performance was respectable. A noticeable trend in the training process was the rapid ups and downs during the first 10 epochs, after which the model approached a local minimum. The optimal results were achieved at around the 14 th epoch. An intriguing observation was that the lowest accuracy rate was recorded for one of the simplest Chinese characters, consisting of just four strokes. Similarly, other characters with low recognition accuracy rates tended to be simple and had few strokes. In contrast, the highest accuracy rates were achieved for more complex characters with over 10, 15, or even 20 strokes. Although this phenomenon could be attributed to the model's architecture and capacity, a deeper investigation was beyond the scope of this study, as this phase primarily aimed to generate the initial weights. When analyzing the results of the handwritten kanji recognition models, several consistent patterns emerged as follows:  
* Regardless of the number of classes, the models typically approached a local minimum within 2-4 epochs, followed by gradual refinement over 14-40 epochs. A recurring issue was the lower accuracy rate for the visually similar kanji & and 3;
* Across all the experiments, the pretrained RESNET-18 model with all the layers unfrozen consistently delivered the best results, while the pretrained model with only the last layer unfrozen performed the worst. These findings support the hypothesis  
Figure 9: Comparison of all the evaluated models for the 300-class classification task. that pretraining in a large dataset of handwritten Chinese characters is beneficial because of their visual similarity to handwritten kanji. The pretrained weights likely begin closer to a favorable loss basin compared to those in a random initialization;
* The underperformance of the pretrained model with only the last layer unfrozen was anticipated, as this approach prioritizes computational efficiency over the optimal performance. Despite its limitations, the model still achieved reasonable results;
* The models trained from scratch, with and without data augmentation, exhibited comparable performances. For the 150-class recognition task, the non-augmented model slightly outperformed the augmented one across all the metrics. In the 200-class task, the augmented model led in every metric. For the 300-class task, the augmented model achieved a higher accuracy rate but lower mAP and MAA values. These results suggest that data augmentation does not consistently enhance the models' performances, which explains its exclusion from the pretrained models' training. Notably, the non-pretrained models demonstrated significantly lower mAP scores compared to that of the pretrained model with all the layers unfrozen, underscoring the value of transfer learning. When comparing our solutions to the previous state-of-the-art (SOTA) approach for recognizing 150 kanji, our best model--pretrained RESNET-18 with all the layers unfrozen--achieved a 1.51% improvement in accuracy, which is an accuracy rate of 97.94%. For the 300-kanji recognition task, which doubles the class count of the previous SOTA approach, our model surpassed its accuracy by 1.19%, which is an accuracy rate of 97.62%. To facilitate future research, we have also provided benchmark metrics for mAP and mAA, offering a more comprehensive evaluation framework for this complex multiclass classification task.