I am trying to run microphone_continuous example ported from arduino example on faucet dataset at imxrt10xx.
I am getting error below:
ERR: MFCC failed (-1002)
ERR: Failed to run DSP process (-1002)
ERR: Failed to run classifier (-5)
By the way when I (debug) print the offset and length in the microphone_audio_signal_get_data function, it prints offset: 3999, length: 1 only once and then above error happens.
@naveen -1002 is EIDSP_OUT_OF_MEM (out of memory). This could be: 1) really out of memory (not sure what the RAM of your device is), 2) malloc not succeeding, either because the heap is too small, or because different memory allocation functions should be used - you can override ei_malloc / ei_calloc / ei_free for this (see edge-impulse-sdk/porting/ei_classifier_porting.h).
Thanks @janjongboom, it was a memory issue. The 128KB RAM is divided into multiple 32 KB banks and the default heap memory was only 4KB which was not enough. After increasing the heap size it worked!
Hi @DW_FYP the Nano 33 BLE Sense is already fully using its memory, so your option here would be to tweak the parameters in the MFCC block to use less memory (see the āPerformanceā widget for an indication). E.g. by upping the frame length parameter.
Sorry but I am having the same issue, I want to try and solve it increasing the heap size as you did. Can you tell me how can I modify it? If it is in Arduino IDE or directly in the EI libraries or files?
Sorry, 4MB is the Flash Memory, and the SRAM is 512kB. Now my problem is that iām getting another error message āStack canary watchpoint triggered (mytask)ā for the ESP32. Apparently the heap or stack size is being overflown, even when I increase or free with malloc.
Helloā¦ iām using nano 33 ble sense. Iām having the same issue. But i donāt understand since it has 256 KBS of RAM and the estimated peak RAM Usage from edge impulse is 104 KBs. Please can you helpā¦
FIrstly i was having tf arena allocation issueā¦ which got solved by declaring -DEI_CLASSIFIER_ALLOCATION_STATIC.