2021-09-08 04:28 AM
I have a project running with X-CUBE-AI version 5.2 and I have trouble generating new network with old version, however I have also found updating very complicated since the way of calling NN changed. Should I just stick to older version and find a way to generate model with it? Or should I rebuild whole project to work with 7.0? If so how should I approach it?
2021-09-08 06:42 AM
The process to upgrade to a new version is the following\
Click on this icon You'll have a window on the right
Select in the "Migrate to" combo the version you want to use, click on the Try button, then Accept
All the parameters that you used in previous version of AI are normally migrated to the chosen version. If you see some parameters not correctly migrated you can signal them so that it get fixed in a future release.
Regards
Daniel
2021-09-08 06:44 AM
Unfortunately the snapshots are not transmitted :-( the icon to click on is a black icon with 2 arrows next to the green check
2021-09-10 02:01 AM
Hi Jczk,
Can you elaborate more about the issue of migration, in particular about the way of calling NN? Because between the 5.1 until 7.0, the API (ai_<network_name>_XX functions) to use the generated model is always the same?
br,
Jean-Michel
2021-09-10 02:09 AM
According your stating point, in the embedded documentation from the v7 pack, there is a specific article to explain "How to upgrade a STM32 project" with a new version of the X-CUBE-AI library.
2021-09-10 02:43 AM
Hi,
well I've been reading about it since posting and it seems that my issue is caused by the fact that the old project I'm referring to is not using this default way of calling NN. Instead it is using a function found in app_x-cube-ai.c by calling it directly from main.c:
int aiRun(const void *in_data, void *out_data)
which seems to be changed to:
static int ai_run(void *data_in, void *data_out)
I have found that the aiRun function still can be used when copied to app_x-cube-ai.c and it seems to be working just fine, however I assume that this change was made for a reason I should try to rework the project to use function:
ai_i32 ai_network_run(ai_handle network, const ai_buffer* input, ai_buffer* output)
For some reason I'm unable to generate the code under 5.2.0 properly and cubemx is not showing it as availible (It does after I reinstall it under software packages but after I restart cubemx it is not availble again).