-
Notifications
You must be signed in to change notification settings - Fork 198
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
CI workflows for cmsis-pack-examples
Adding GitHub integrated CI workflows with documentation updates for CMSIS-Pack based Machine Learning Examples. Change-Id: I8e9ccdfc682c19b808561dba1f61a08e72ab8532 Signed-off-by: Kshitij Sisodia <[email protected]>
- Loading branch information
1 parent
2321def
commit 15c7506
Showing
11 changed files
with
243 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Continuous Integration (CI) Tests for CMSIS-Pack based Machine Learning Examples | ||
|
||
|
||
Content of `.ci` Directory | Description | ||
:----------------------------|:----------------- | ||
`vcpkg-configuration.json` | Tool setup for the CI test. | ||
|
||
|
||
## GitHub Action Workflows | ||
|
||
The [GitHub Actions](https://docs.github.com/en/actions) in the directory `.github/workflows` are the scripts for the CI tests. These scripts contain detailed comments about each step that is executed. | ||
|
||
These examples use the [Arm® Compiler for Embedded](https://developer.arm.com/Tools%20and%20Software/Arm%20Compiler%20for%20Embedded) (AC6) toolchain. As such all workflows are using this compiler. | ||
|
||
- `AVH-FVP-CI.yml` implements the *AVH build and execution test* that runs on [Arm Virtual Hardware - Fixed Virtual Platforms (AVH FVP)](https://arm-software.github.io/AVH/main/simulation/html/index.html) simulation models. The directory `FVP` contains configuration files for the FVP simulation models. | ||
|
||
- `Hardware-CI.yml` implmentes the *Hardware build test* that runs on evaluation boards. The output of this build test is stored as artifacts and can be downloaded to the evaluation board for execution. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
{ | ||
"registries": [ | ||
{ | ||
"name": "arm", | ||
"kind": "artifact", | ||
"location": "https://artifacts.tools.arm.com/vcpkg-registry" | ||
} | ||
], | ||
"requires": { | ||
"arm:tools/open-cmsis-pack/cmsis-toolbox": "^2.4.0", | ||
"arm:tools/kitware/cmake": "^3.28.4", | ||
"arm:tools/ninja-build/ninja": "^1.12.0", | ||
"arm:compilers/arm/armclang": "^6.22.0", | ||
"arm:compilers/arm/arm-none-eabi-gcc": "^13.2.1", | ||
"arm:models/arm/avh-fvp": "^11.26.11" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
# SPDX-FileCopyrightText: Copyright 2024 Arm Limited and/or its | ||
# affiliates <[email protected]> | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
name: AVH build and execution test | ||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
branches: [main] | ||
push: | ||
branches: [main] | ||
schedule: | ||
- cron: '00 20 * * 6' | ||
|
||
jobs: | ||
AVH: | ||
strategy: | ||
|
||
matrix: | ||
target: [ | ||
{proj: kws, board: AVH-SSE-300, model: FVP_Corstone_SSE-300, uart: mps3_board.uart0}, | ||
{proj: kws, board: AVH-SSE-300-U55, model: FVP_Corstone_SSE-300_Ethos-U55, uart: mps3_board.uart0}, | ||
{proj: kws, board: AVH-SSE-300-U65, model: FVP_Corstone_SSE-300_Ethos-U65, uart: mps3_board.uart0}, | ||
{proj: kws, board: AVH-SSE-310, model: FVP_Corstone_SSE-310, uart: mps3_board.uart0}, | ||
{proj: kws, board: AVH-SSE-310-U55, model: FVP_Corstone_SSE-310, uart: mps3_board.uart0}, | ||
{proj: kws, board: AVH-SSE-310-U65, model: FVP_Corstone_SSE-310_Ethos-U65, uart: mps3_board.uart0}, | ||
{proj: object-detection, board: AVH-SSE-300, model: FVP_Corstone_SSE-300, uart: mps3_board.uart0}, | ||
{proj: object-detection, board: AVH-SSE-300-U55, model: FVP_Corstone_SSE-300_Ethos-U55, uart: mps3_board.uart0}, | ||
{proj: object-detection, board: AVH-SSE-300-U65, model: FVP_Corstone_SSE-300_Ethos-U65, uart: mps3_board.uart0}, | ||
{proj: object-detection, board: AVH-SSE-310, model: FVP_Corstone_SSE-310, uart: mps3_board.uart0}, | ||
{proj: object-detection, board: AVH-SSE-310-U55, model: FVP_Corstone_SSE-310, uart: mps3_board.uart0}, | ||
{proj: object-detection, board: AVH-SSE-310-U65, model: FVP_Corstone_SSE-310_Ethos-U65, uart: mps3_board.uart0} | ||
] | ||
|
||
fail-fast: false | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout repo | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install tools | ||
uses: ARM-software/cmsis-actions/vcpkg@v1 | ||
with: | ||
config: ".ci/vcpkg-configuration.json" | ||
|
||
- name: Activate Arm tool license | ||
uses: ARM-software/cmsis-actions/armlm@v1 | ||
|
||
- name: Build project ${{ matrix.target.proj }} for target ${{ matrix.target.board }} with AC6 | ||
run: | | ||
cbuild mlek.csolution.yml --update-rte --packs --context ${{ matrix.target.proj }}+${{ matrix.target.board }} | ||
- name: Execute project ${{ matrix.target.proj }}, target ${{ matrix.target.board }}, build Release on AVH ${{ matrix.target.model }} | ||
if: always() | ||
run: | | ||
${{ matrix.target.model }} \ | ||
-a ./out/${{ matrix.target.proj }}/${{ matrix.target.board }}/Release/${{ matrix.target.proj }}.axf \ | ||
-f ./FVP/${{ matrix.target.model }}/fvp_config.txt \ | ||
-C ${{ matrix.target.uart }}.out_file=./out/${{ matrix.target.proj }}/${{ matrix.target.board }}/Release/fvp_stdout.log \ | ||
--simlimit 60 --stat | ||
cat ./out/${{ matrix.target.proj }}/${{ matrix.target.board }}/Release/fvp_stdout.log | ||
- name: Execute project ${{ matrix.target.proj }}, target ${{ matrix.target.board }}, build Debug on AVH ${{ matrix.target.model }} | ||
if: always() | ||
run: | | ||
${{ matrix.target.model }} \ | ||
-a ./out/${{ matrix.target.proj }}/${{ matrix.target.board }}/Debug/${{ matrix.target.proj }}.axf \ | ||
-f ./FVP/${{ matrix.target.model }}/fvp_config.txt \ | ||
-C ${{ matrix.target.uart }}.out_file=./out/${{ matrix.target.proj }}/${{ matrix.target.board }}/Debug/fvp_stdout.log \ | ||
--simlimit 60 --stat | ||
cat ./out/${{ matrix.target.proj }}/${{ matrix.target.board }}/Debug/fvp_stdout.log |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
# SPDX-FileCopyrightText: Copyright 2024 Arm Limited and/or its | ||
# affiliates <[email protected]> | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
name: Hardware build test | ||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
branches: [main] | ||
push: | ||
branches: [main] | ||
schedule: | ||
- cron: '00 20 * * 6' | ||
|
||
jobs: | ||
HW: | ||
strategy: | ||
|
||
matrix: | ||
target: [ | ||
{proj: kws, board: FRDM-K64F}, | ||
{proj: kws, board: STM32F746-DISCO} | ||
# {proj: kws, board: Alif-E7-M55-HP}, | ||
# {proj: object-detection, board: Alif-E7-M55-HP} | ||
] | ||
|
||
fail-fast: false | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout repo | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install tools | ||
uses: ARM-software/cmsis-actions/vcpkg@v1 | ||
with: | ||
config: ".ci/vcpkg-configuration.json" | ||
|
||
- name: Activate Arm tool license | ||
uses: ARM-software/cmsis-actions/armlm@v1 | ||
|
||
- name: Build project ${{ matrix.target.proj }} for target ${{ matrix.target.board }} with AC6 | ||
run: | | ||
cbuild mlek.csolution.yml --update-rte --packs --context ${{ matrix.target.proj }}+${{ matrix.target.board }} | ||
- name: Upload build Artifact | ||
if: always() | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: ${{ matrix.target.proj }}_${{ matrix.target.board }}_AC6 | ||
path: | | ||
./out/${{ matrix.target.proj }}/${{ matrix.target.board }}/ | ||
retention-days: 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Notes: | ||
# Parameters: | ||
# instance.parameter=value #(type, mode) default = 'def value' : description : [min..max] | ||
#--------------------------------------------------------------------------------------------------- | ||
mps3_board.visualisation.disable-visualisation=1 # (bool , init-time) default = '0' : Enable/disable visualisation | ||
mps3_board.uart0.shutdown_on_eot=1 # (bool , init-time) default = '0' : Shutdown simulation when a EOT (ASCII 4) char is transmitted (useful for regression tests when semihosting is not available) | ||
#--------------------------------------------------------------------------------------------------- |
8 changes: 8 additions & 0 deletions
8
cmsis-pack-examples/FVP/FVP_Corstone_SSE-300_Ethos-U55/fvp_config.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Notes: | ||
# Parameters: | ||
# instance.parameter=value #(type, mode) default = 'def value' : description : [min..max] | ||
#--------------------------------------------------------------------------------------------------- | ||
mps3_board.visualisation.disable-visualisation=1 # (bool , init-time) default = '0' : Enable/disable visualisation | ||
mps3_board.uart0.shutdown_on_eot=1 # (bool , init-time) default = '0' : Shutdown simulation when a EOT (ASCII 4) char is transmitted (useful for regression tests when semihosting is not available) | ||
ethosu.num_macs=256 # (int , init-time) default = '0x80' : Number of 8x8 MACs performed per cycle | ||
#--------------------------------------------------------------------------------------------------- |
8 changes: 8 additions & 0 deletions
8
cmsis-pack-examples/FVP/FVP_Corstone_SSE-300_Ethos-U65/fvp_config.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Notes: | ||
# Parameters: | ||
# instance.parameter=value #(type, mode) default = 'def value' : description : [min..max] | ||
#--------------------------------------------------------------------------------------------------- | ||
mps3_board.visualisation.disable-visualisation=1 # (bool , init-time) default = '0' : Enable/disable visualisation | ||
mps3_board.uart0.shutdown_on_eot=1 # (bool , init-time) default = '0' : Shutdown simulation when a EOT (ASCII 4) char is transmitted (useful for regression tests when semihosting is not available) | ||
ethosu.num_macs=256 # (int , init-time) default = '0x100' : Number of 8x8 MACs performed per cycle | ||
#--------------------------------------------------------------------------------------------------- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Parameters: | ||
# instance.parameter=value #(type, mode) default = 'def value' : description : [min..max] | ||
#--------------------------------------------------------------------------------------------------- | ||
mps3_board.visualisation.disable-visualisation=1 # (bool , init-time) default = '0' : Enable/disable visualisation | ||
mps3_board.uart0.shutdown_on_eot=1 # (bool , init-time) default = '0' : Shutdown simulation when a EOT (ASCII 4) char is transmitted (useful for regression tests when semihosting is not available) | ||
ethosu.num_macs=256 # (int , init-time) default = '0x100' : Number of 8x8 MACs performed per cycle (32, 64, 128, or 256) | ||
#--------------------------------------------------------------------------------------------------- |
7 changes: 7 additions & 0 deletions
7
cmsis-pack-examples/FVP/FVP_Corstone_SSE-310_Ethos-U65/fvp_config.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Parameters: | ||
# instance.parameter=value #(type, mode) default = 'def value' : description : [min..max] | ||
#--------------------------------------------------------------------------------------------------- | ||
mps3_board.visualisation.disable-visualisation=1 # (bool , init-time) default = '0' : Enable/disable visualisation | ||
mps3_board.uart0.shutdown_on_eot=1 # (bool , init-time) default = '0' : Shutdown simulation when a EOT (ASCII 4) char is transmitted (useful for regression tests when semihosting is not available) | ||
ethosu.num_macs=256 # (int , init-time) default = '0x100' : Number of 8x8 MACs performed per cycle (256 or 512) | ||
#--------------------------------------------------------------------------------------------------- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters