Closed kangliyu1 closed 2 years ago
Your testbench works ok. You just choose image which get as result 10 (A) in math model.
Image number, Real, Predicted
0. 0 - 0
13. 1 - 10
26. 10 - 10
38. 2 - 10
51. 3 - 10
65. 4 - 6/10
79. 5 - 10
103. 6 - 6
114. 7 - 10
129. 8 - 8
141. 9 - 9
Try to run image 103.
I made changes in r03_find_optimal_bit_for_weights.py
. Now it has parameters to run.
If you run like this:
python r03_find_optimal_bit_for_weights.py --dump_memory_struct --print_pixel_calc --start_bit 10 --end_bit 11 --use_cache 0
It will generate state of feature maps on each layer of neural net. Also it will generate how first pixel of each feature map was calculated. It useful for debugging.
Results will be in:
verilog/memory_structure_level_0_conv.txt
verilog/memory_structure_level_1_conv.txt
verilog/memory_structure_level_3_conv.txt
verilog/memory_structure_level_4_conv.txt
verilog/memory_structure_level_6_conv.txt
verilog/memory_structure_level_7_conv.txt
verilog/memory_structure_level_9_dense.txt
Hello! After you modified convert_image_for_testbench.py yesterday, I used this code to generate the storage data in Figure 1, but found that the simulation results are still all "a" (only the first "0" was successfully recognized, and all other results were It outputs "a", as shown in Figure 2), the following is my testbench, I am still very confused about this, I hope you can give me some pointers, thank you very much! ! fig1: fig2: fig3:
testbench: