Cortex-M: Add MLPerf Tiny model tests#18546
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/18546
Note: Links to docs will display an error until the docs builds have been completed. ❌ 1 New Failure, 3 Unrelated FailuresAs of commit eea1921 with merge base c39a0ff ( NEW FAILURE - The following job has failed:
BROKEN TRUNK - The following jobs failed but were present on the merge base:👉 Rebase onto the `viable/strict` branch to avoid these failures
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
This PR needs a
|
eb30d0a to
0468885
Compare
0468885 to
95cfdb9
Compare
Add Cortex-M dialect and implementation tests for DeepAutoEncoder, DS-CNN, MobileNet V1 0.25, and ResNet-8 from the MLPerf Tiny benchmark suite. All 4D model inputs use explicit channels_last memory format as required by CMSIS-NN. Add atol parameter to CortexMTester.test_dialect() and test_implementation() for models that need relaxed tolerance. Fix McuTestCase.example_inputs type annotation to accept both tuples and callables, matching actual usage. Co-authored-by: Claude <noreply@anthropic.com>
The dialect test was using atol=0.1 while the implementation test used the default atol=1e-03, which is backwards — the CPU graph comparison should not need a looser tolerance than hardware simulation. Remove the override; the test passes at the stricter default. Co-authored-by: Claude <noreply@anthropic.com>
0399baf to
eea1921
Compare
### Summary Add Cortex-M dialect and implementation tests for DeepAutoEncoder, DS-CNN, MobileNet V1 0.25, and ResNet-8 from the MLPerf Tiny benchmark suite. All 4D model inputs use explicit channels_last memory format as required by CMSIS-NN. Add atol parameter to CortexMTester.test_dialect() and test_implementation() for models that need relaxed tolerance. Fix McuTestCase.example_inputs type annotation to accept both tuples and callables, matching actual usage. Fixes pytorch#16038 ### Test plan ``` pytest backends/cortex_m/test/models/ ``` cc @psiddh @AdrianLundell @digantdesai --------- Co-authored-by: Claude <noreply@anthropic.com>
Summary
Add Cortex-M dialect and implementation tests for DeepAutoEncoder, DS-CNN, MobileNet V1 0.25, and ResNet-8 from the MLPerf Tiny benchmark suite. All 4D model inputs use explicit channels_last memory format as required by CMSIS-NN.
Add atol parameter to CortexMTester.test_dialect() and test_implementation() for models that need relaxed tolerance.
Fix McuTestCase.example_inputs type annotation to accept both tuples and callables, matching actual usage.
Fixes #16038
Test plan
cc @psiddh @AdrianLundell @digantdesai