# Local Contrast Learning for One-Shot Learning
## 4 Experiments and Results
### Classification Evaluation
#### 4.1.2. Hwdb  
Like the test on Omniglot, we evaluated LCNN on CASIA-HWDB1.1 [66; 67], which is a Chinese handwritten character dataset for machine learning and is more diversified \begin{table}
\begin{tabular}{l r r r r r} \hline \hline  & & \multicolumn{2}{c}{**5-Way Accuracy**} & \multicolumn{2}{c}{**20-Way Accuracy**} \\
**Model** & **Chars** & **1-Shot** & **5-Shot** & **1-Shot** & **5-Shot** \\ \hline Matching Nets [68] & 1200 & 98.1 & 98.9 & 93.8 & 98.7 \\ MAML [70] & 1200 & 98.7 \(\pm\) 0.4 & 99.9 \(\pm\) 0.1 & 95.8 \(\pm\) 0.3 & 98.9 \(\pm\) 0.2 \\ MetaNet [71] & 1200 & 98.95 & - & 97 & - \\ Relation Nets [77] & 1200 & 99.63 \(\pm\) 0.2 & 99.8 \(\pm\) 0.1 & 97.6 \(\pm\) 0.2 & 99.1 \(\pm\) 0.1 \\ CNPs [72] & 1200 & 95.3 & 98.5 & 89.9 & 96.8 \\ TAML [73] & 1200 & 99.47 \(\pm\) 0.25 & 99.83 \(\pm\) 0.09 & - & - \\ Cross-way training on Prototypical Networks [74] & 1200 & 98.73 \(\pm\) 0.19 & 99.64 \(\pm\) 0.07 & 95.21 \(\pm\) 0.17 & 98.77 \(\pm\) 0.05 \\ EDANet [75] & 1200 & 98.61 & 99.13 & - & - \\ MSRN [76] & 1200 & 99.35 \(\pm\) 0.25 & 99.70 \(\pm\) 0.08 & 97.41 \(\pm\) 0.28 & 99.01 \(\pm\) 0.13 \\ Attention mechanism and weight fusion [78] & 1200 & - & - & 97.8 & 99.2 \\ \hline LCNN 60 & 60 & 98.95 \(\pm\) 0.06 & 99.70 \(\pm\) 0.03 & 96.84 \(\pm\) 0.16 & 99.05 \(\pm\) 0.10 \\ LCNN 156 & 156 & **99.24 \(\pm\) 0.05** & **99.77 \(\pm\) 0.03** & 98.03 \(\pm\) 0.13 & 99.31 \(\pm\) 0.09 \\ LCNN 1200 & 1200 & 98.97 \(\pm\) 0.05 & 99.76 \(\pm\) 0.03 & **98.28 \(\pm\) 0.12** & **99.46 \(\pm\) 0.07** \\ \hline MetaNet [71] 964 & 964 & 98.45 & - & 95.92 & - \\ \hline LCNN tiny & 60 & 95.36 \(\pm\) 0.09 & 99.04 \(\pm\) 0.05 & 95.88 \(\pm\) 0.20 & 98.85 \(\pm\) 0.11 \\ LCNN small2 & 156 & 98.54 \(\pm\) 0.06 & 99.63 \(\pm\) 0.04 & 97.01 \(\pm\) 0.13 & 99.15 \(\pm\) 0.08 \\ LCNN 964 & 964 & 98.86 \(\pm\) 0.09 & 99.70 \(\pm\) 0.07 & 97.77 \(\pm\) 0.22 & 99.33 \(\pm\) 0.18 \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Twenty-way one-shot and few-shot accuracy (%) on Omniglot based on variant test protocol. Results are accuracies averaged over 100-time runs with 95% confidence intervals where reported. ‘-’: not reported. The bolded result indicates the best result in our experiment. and confusing than Omniglot. CASIA-HWDB1.1 is a widely used dataset that includes 3755 character classes and 300 images per class written by 300 calligraphers. Therefore, in order to extensively evaluate the performance and provide a benchmark for other one-shot classification approaches on the handwritten Chinese characters, we defined a one-shot classification of the handwritten Chinese characters. CASIA-HWDB1.1 includes a training subset with 240 images per character and a test subset with 60 images per character. However, we only used the first 20 images per character in the training subset to evaluate the performance of one-shot classification. Figure 7 presents examples of recognition classification errors along with visual comparisons. These examples clearly demonstrate the potential classification errors that the model may encounter when faced with similar contrast objects. For example, in the example from the first row, the handwriting forms of the first pair of positive and negative contrast objects are visually similar and difficult to differentiate. Similarly, in the example from the third row, the handwriting forms of the second pair of positive and negative contrast objects also exhibit significant visual similarity. We picked the last 600 characters as a test set out of 3755 characters (the characters are ordered by GB2312 code) and, respectively, picked the first 60, 200, and 3155 characters as three different training sets: HWDB60, HWDB200, and HWDB3155. All images were resized to 64 x 64 and not augmented. In all experiments in this section, the test trials were created using Algorithm 1 on the test set, and the number of test trials \(n_{trial}\) was computed by the equation in the previous section. To compare the performance of HWDB with other neural network approaches, we selected Matching Networks [68] as a baseline.