2025-03-13 12:46 AM
I have followed the model zoo github tutorial to train, quantize and deploy an Audio Event Detection model. I used the available yamnet-256 and followed the tutorial to the end of deployment. I manage to get successful deployment but when I connect the B-U585I-IOT02A board, and open putty and connect via serial, i get this on putty:
Network informations...
model name : network
model signature : 0x80e2ec0fd41896ad70099555488edefd
model datetime : 2025-03-12T18:36:47+0800
compile datetime : Mar 12 2025 18:37:57
runtime version : 10.0.0
tools version : 2.0.0
complexity : 23932020 MACC
c-nodes : 21
map_activations : 1
[0] (1,1,1,112196)112196/u8 Q8.0 @0x20017480/112196
map_weights : 1
[0] (1,1,1,139176)139176/u8 Q8.0 @0x80201E0/139176
n_inputs/n_outputs : 1/1
I[0] (1,64,96,1)6144/i8 1:(0.053046,44), @0x20028180/6144
O[0] (1,1,1,10)10/float32 @0x2001748C/40
--- Start Processing ---
It stops at start processing, when I play the audio files from ESC-50 dataset, nothing happens. Am I supposed to perform some configurations on the stm32ide like enable the microphone or USART or something?
2025-03-13 2:44 AM
Hello
It should normally works out of the box without additional configuration with microphone or USART .
I think you should tune values of silence threshold located in Projects\Common\dpu\ai_model_config.h :
#define CTRL_X_CUBE_AI_SPECTROGRAM_SILENCE_THR (123) // 0 means disabled
for info I tuned mine at 123, but you set it to zero in case you want to disable it
I hope this can fix
best regards
L
2025-03-13 9:15 PM
I tried setting it to zero and still getting the same results. But during the deployment in the logs of command prompt i always see this error is it an issue?
Finished building: default.size.stdout
Finished building: b_u585i_iot2a_gs_aed.list
12:13:05 Build Failed. 7 errors, 8 warnings. (took 9s.656ms)
2025-03-13 9:23 PM
I notice also that when i deploy the model, it automatically sets it back to this value:
2025-03-14 12:24 AM
Hello,
This setting should be applied on the deployed project, on the specified file, to be re-build afterwards with cube Ide ,this done after deployment and thus should not influence the deployement itself
best regards
L
2025-03-14 12:32 AM
Yes, and this is why it is still npt working, two solutions
1 - you apply the fix I described after the deployment. but you need to clean, re-build and flash the project.
2 - you fix the deployment script so that the correct value is generated in the first place
in \stm32ai-modelzoo-services\audio_event_detection\src\utils\gen_h_file.py, line 140
if config.feature_extraction.to_db:
f.write('#define CTRL_X_CUBE_AI_SPECTROGRAM_SILENCE_THR (0) // 0 means disabled\n')
else:
f.write('#define CTRL_X_CUBE_AI_SPECTROGRAM_SILENCE_THR (100.0F) // 0 means disabled\n')
I hope this help
best regards
L