STM32N6570-DK: Inference always outputs the same class with the same confidence level

Question/Issue:
The inference result is always fixed to class 3 with a confidence of around ~0,996. When further investigated, I found that the features array is always (mostly) full of zero’s.

Project ID:
971849

Context/Use case:
I am building an algorithm to detect 9 different cylindrical objects. The microphone that’s on the DK picks up the sound, a DMA puts the samples in a uint16_t buffer. I then convert the buffer using q15_arm_to_float(); and after that I use signal_from_buffer() and call run_classifier()

Steps Taken:

  1. I enabled the debug and printed the results to UART, the Features calculation takes 0ms and the output after that shows the array filled with 0’s, before it had some float values, but most where still 0
  2. Confirmed the buffer for the raw microhpone data is not in the Dcache of the CPU.
  3. Confirmed that the float buffer that is being put into the signal_to_buffer function is also correct.

Expected Outcome:
The classifier should output different labels depending on the sound the microphone picks up.

Actual Outcome:
The classifier always outputs class 3

Reproducibility:

  • Always

Environment:

  • Platform: STM32N6570-DK, on-board microphone
  • Build Environment Details: STM32CubeIDE 2.0.0
  • OS Version: Windows 11
  • Edge Impulse Version (Firmware): N/A I am using my own Firmware
  • Edge Impulse CLI Version: N/A, see above
  • Project Version: Version 3
  • Custom Blocks / Impulse Configuration: [Describe custom blocks used or impulse configuration]
    Logs/Attachments:
    The output of the model in UART:
    Features (0 ms.): a bunch of zero’s here
    Running impulse…
    [0] Drinkbeker_0: 0.000000
    [1] Drinkbeker_100: 0.000000
    [2] Drinkbeker_50: 0.000000
    [3] Glas_0: 0.996094
    [4] Glas_100: 0.000000
    [5] Glas_50: 0.000000
    [6] MetalenBeker_0: 0.000000
    [7] MetalenBeker_100: 0.000000
    [8] MetalenBeker_50: 0.000000
    Segment 0: Glas_0 (99.61%)

Additional Information:
The model works fine when using it with a laptop microphone, it defaults to label 3 when doing nothing, but that is to be expected i think.