Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separate ML model from NS image #66

Merged
merged 4 commits into from
Apr 16, 2024

Conversation

urutva
Copy link
Contributor

@urutva urutva commented Apr 15, 2024

Description

The idea is to move the ML model to the DDR memory region, generate a separate image for the DDR memory region. To do so the following changes are needed:

  • Modify the linker scripts for all platforms to remove the RAM load address of the ML model image as it should be
    loaded to DDR memory region.
  • Some linker sections were renamed to be more descriptive.
  • A new CMake function is introduced to extract sections from input AXF file, this function is used to extract DDR section
    which contains the ML model out of the NS image to be loaded separately.

Test Steps

Validated changes in the CI, no regression observed.

Checklist:

  • I have tested my changes. No regression in existing tests.
  • I have modified and/or added unit-tests to cover the code changes in this Pull Request.

Related Issue

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

It seems like the speech recognition DSP task which is collecting
the input data from ROM/VSI audio source needs to be a bit
slower as in case of using software to do the ML inference the
performance is way slower than using the Ethos-NPU which means the
DSP task must be delayed for sometime as to allow some extra time
for the software inference to be finished.

Signed-off-by: Ahmed Ismail <[email protected]>
The idea is to move the ML model to the DDR memory region,
generate a separate image for the DDR memory region where
the model can be over the air updated without the need
to update the NS image. To do so the following changes are
needed:

* Modify the linker scripts for all platforms to remove the
RAM load address of the ML model image as it should be
loaded to DDR memory region.

* Some linker sections were renamed to be more descriptive.

* A new CMake function is introduced to extract sections from
input AXF file, this function is used to extract DDR section
which contains the ML model out of the NS image to be loaded
separately.

Signed-off-by: Ahmed Ismail <[email protected]>
@urutva urutva requested a review from a team as a code owner April 15, 2024 09:33
@amazonKamath amazonKamath self-requested a review April 16, 2024 09:08
@urutva urutva merged commit 781d45f into FreeRTOS:main Apr 16, 2024
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants