-
Notifications
You must be signed in to change notification settings - Fork 78
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Digit Recognition Demo vs SVHN model difference #326
Comments
Could you please give more details about how you generated the 'c' files and which example code you modified? |
I used the following script to generate the C files. The checkpoint and yaml files came with the synthesis repository and I used them unmodified. And finally i copied the cnn.c, cnn.h, log and weights files into the digit_detection_demo example project that came with MSDK. #!/bin/sh python ai8xize.py --test-dir $TARGET --prefix svhn_tinierssd --checkpoint-file trained/ai85-svhn-tinierssd-qat8-q.pth.tar --config-file networks/svhn-tinierssd.yaml --device MAX78000 --compact-data --mexpress --timer 0 --display-checkpoint --verbose --overlap-data --mlator --new-kernel-loader --overwrite --no-unload I noticed something strange in original cnn.c file that came with digit_detection_demo project. the last 4 layers in original cnn.c have dimensions of 48x18x18, 48x9x9, 48x4x4 and 48x2x2; however, the cnn.c file that I generated with above script have different dimensions of last 4 layers as 44x18x18, 44x9x9, 44x4x4 and 44x2x2. Moreover the following script mentioned in original cnn.c file of digit_detection_demo contains different yaml file which is not provided in repository as well. // Created using ./ai8xize.py --test-dir sdk/Examples/MAX78000/CNN --prefix tinyssd_svhn_prior_unload --checkpoint-file /home/ermanokman/repos/github/egg_localization/logs/2022.04.07-190512/qat_tinierssd_svhn_q.pth.tar --config-file /home/seldauyanik/GitHub/Eta2/ai8x-training/tinyssd8x.yaml --device MAX78000 --compact-data --mexpress --timer 0 --display-checkpoint --verbose --overlap-data --mlator --new-kernel-loader --overwrite --no-unload My objective is to use max78000 in real world object detection applications in aquaponic systems. And I am planning to use digit_recognition_demo and tinierssd model as baseline. Thanks |
Hi. I just solved the issue by doing these steps.
This may be a temporary solution . Hope you can fix this with better solution. Thanks. the modified files are attached as follows. |
Hi, What you observe is correct. If you check the The digit detection demo in the MSDK uses a modified version of this model and it seems you have already the realized the modification. This model outputs 12 classes other than 11. This modification was done for ease of unloading the model output to the prior class probability array. You can check the |
This issue has been marked stale because it has been open for over 30 days with no activity. It will be closed automatically in 10 days unless a comment is added or the "Stale" label is removed. |
I tried to generate 'c' files of digit recognition demo with SVHN dataset. However, the 'c' code that I get after using training, quantization and generate scripts, the 'c' files that I get have different CNN parameters than actual 'c' code of digit detection demo in final layers. Moreover, when I copy my generated 'c' code in the digit recognition MSDK example, I get weird detection on LCD (Connected with Max78000FTHR).
The text was updated successfully, but these errors were encountered: