sirius-ai / LPRNet_Pytorch

Pytorch Implementation For LPRNet, A High Performance And Lightweight License Plate Recognition Framework.
Apache License 2.0
908 stars 227 forks source link

Accuracy 0.0, when i training custom dataset. #76

Open Lightmourne opened 2 years ago

Lightmourne commented 2 years ago

Hi, when i training model with custom data set, the accuracy is always 0. I modified the list of CHARS and license plate length, what could be the problem?

image

LadiesMan924 commented 2 years ago

I think your learning rate is too big, set it to 0.001 when start training.

Lightmourne commented 2 years ago

I think your learning rate is too big, set it to 0.001 when start training.

Thank you, that really worked. Now best accuracy = 0.58 I think this is because my dataset contains a lot of "dirty" images.

LadiesMan924 commented 2 years ago

I've tried many times even if the learning rate is set very small, the best accuracy would not be higher than 0.6. Maybe we should use more images for training.

feitianhouren commented 2 years ago

Set the training epochs parameter to a larger value (for example, 100), increase the test frequency (decrease the --testinterval parameter), and carefully observe the accuracy of each test to see if there are non-zero values. In my training, using my own data set (80,000 for training set and 20,000 for test set), after 15 iterations of the network, the accuracy has reached more than 0.94 (the learning rate is 0.00001 at this time), and then continue training (set The epochs value is greater than 15), the train*.py program will automatically adjust the learning rate back to 0.1, the loss will become larger again, and the accuracy will be reduced to 0.