Skip to content

Commit 7f5229f

Browse files
DenisVieriu97Giovanni Versiglioni
andauthored
[MPS] float16 naming fixed and inexistent mps_logical_not model removed (#10562)
Upstream mps fixes by @versi379 Summary of changes: - Updated generated model name in MPS Backend documentation. - Removed extra line running an inexistent model when building mps_executor_runner. cc @cccclai , @shoumikhin Co-authored-by: Giovanni Versiglioni <giovanniversiglioini@outlook.it>
1 parent 280db15 commit 7f5229f

File tree

3 files changed

+4
-6
lines changed

3 files changed

+4
-6
lines changed

backends/apple/mps/setup.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -76,12 +76,12 @@ cd executorch
7676
## Run the mv3 generated model using the mps_executor_runner
7777

7878
```bash
79-
./cmake-out/examples/apple/mps/mps_executor_runner --model_path mv3_mps_bundled_fp16.pte --bundled_program
79+
./cmake-out/examples/apple/mps/mps_executor_runner --model_path mv3_mps_float16_bundled.pte --bundled_program
8080
```
8181

8282
- You should see the following results. Note that no output file will be generated in this example:
8383
```
84-
I 00:00:00.003290 executorch:mps_executor_runner.mm:286] Model file mv3_mps_bundled_fp16.pte is loaded.
84+
I 00:00:00.003290 executorch:mps_executor_runner.mm:286] Model file mv3_mps_float16_bundled.pte is loaded.
8585
I 00:00:00.003306 executorch:mps_executor_runner.mm:292] Program methods: 1
8686
I 00:00:00.003308 executorch:mps_executor_runner.mm:294] Running method forward
8787
I 00:00:00.003311 executorch:mps_executor_runner.mm:349] Setting up non-const buffer 1, size 606112.
@@ -118,7 +118,7 @@ python3 -m examples.apple.mps.scripts.mps_example --model_name="mv3" --generate_
118118
```
119119
2. Run your Program on the ExecuTorch runtime and generate an [ETDump](../../../docs/source/etdump.md).
120120
```
121-
./cmake-out/examples/apple/mps/mps_executor_runner --model_path mv3_mps_bundled_fp16.pte --bundled_program --dump-outputs
121+
./cmake-out/examples/apple/mps/mps_executor_runner --model_path mv3_mps_float16_bundled.pte --bundled_program --dump-outputs
122122
```
123123
3. Create an instance of the Inspector API by passing in the ETDump you have sourced from the runtime along with the optionally generated ETRecord from step 1.
124124
```bash

examples/apple/mps/executor_runner/mps_executor_runner.mm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@ HierarchicalAllocator planned_memory(
359359
if (FLAGS_bundled_program) {
360360
double rtol = 1e-05;
361361
double atol = 1e-08;
362-
if (strstr(model_path, "fp16")) {
362+
if (strstr(model_path, "float16")) {
363363
rtol = 1e-01;
364364
atol = 1e-01;
365365
} else if (strstr(model_path, "mv3") ||

examples/apple/mps/scripts/build_mps_executor_runner.sh

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,5 +60,3 @@ cmake \
6060
cmake --build cmake-out/examples/apple/mps -j9 --config "$MODE"
6161

6262
echo "Build succeeded!"
63-
64-
./cmake-out/examples/apple/mps/mps_executor_runner --model_path mps_logical_not.pte --bundled_program

0 commit comments

Comments
 (0)