cancel
Showing results for 
Search instead for 
Did you mean: 

Import weights at runtime

aget
Associate

Hello,

is it possible to import weights at runtime?

I plan to convert a NN with Cube AI and deploy it to the controller, and later on receive weights via BT and overwrite the previous weights. Would that be possible or can the weights only be set while converting the network with CubeAI?

I couldn't find any information on this so far...

1 REPLY 1
JNord
Associate II

The weights are stored in FLASH program memory. This program memory can be overwritten by user code, but only in full sectors. https://stackoverflow.com/questions/44443619/how-to-write-read-to-flash-on-stm32f4-cortex-m4#44855815

So you could theoretically implement your own weight updating code using this mechanism. There are as far as I know no example code or libraries for this.

An alternative would be to flash a full new firmware image. Using a standard Bluetooth FOTA process.