tensorflow-hangul-recognition
tensorflow-hangul-recognition copied to clipboard
training accuracy
hi author I have changed datasets, including blur, rotate, scale. black fond and white background images create (contrary to this project )
but training accuracy does not improve.. Can you tell me what problem is
How large is your dataset and how long are you training for? Depending on the size of the dataset, it can take a long time for the model to start converging and accuracy to improve, so ensure you training for a sufficient number of epochs. Or if the number of images for each character is too small, training performance may also be negatively impacted.
thank you for reply!
The number of my datasets is 130K(orig, blur, distortion, and scale). training time is about 1 - 2 hours with Titan-X.
now, special characters(!, ?, [, ]) and alphabet is also contained as labels.
the number of images for each character is about 600..
epoch is 30, batch is 128
however, if I select font color with black and background with white, training accuracy does not still improve. any idea to solve this problem? Is there a good model for Exquisitely predicting Korean character better ?
Is the image you posted showing the training run for the white background images?
Based on that image, it looks like you've reached a decent accuracy, but it seems like you've reached a training saturation point where additional training does not help as shown by the constant fluctuations. The training can probably be stopped around where the training accuracy is consistently mid-90%. You can definitely reduce the number of epochs for training in that case.
What I don't have here in this project is mechanism for early stopping by checking the accuracy on a validation set of images every 1000 steps or so and stopping the training when validation accuracy begins to decline.
In any case, I'm sure there are better models out there as this is a fairly simple model which was extended from the MNIST TensorFlow model. Its focus is on showcasing the end the end process of data generation to app deployment and not so much creating a state of the art Hangul recognition model.
I think the accuracy you've gotten is reasonable, but if it is not sufficient, then for this project's model, you can always tweak the architecture of the model to add more nodes/layers. This will increase the learning capacity of the model. There are other hyperparameter tunings you could do such as changing the batch size, dropout rate, etc, but finding the optimal settings is likely to be time consuming and tough.
@pvaneck Hi. author! First of all, thanks for the details. I have tested better models (resnet) with pytorch as your advice. but result is not better than yours. I used your code about creating datasets, and converted train, test, and, model to pytorch version.
my train code is here this is simliar to MNIST pytorch model.
Can you advise me to get higher performance? I will try.
Thanks in advance