Run MobileSAM prompt segmentation on Arm Ethos-U85 with ExecuTorch
Introduction
Understand the MobileSAM deployment workflow
Prepare the ExecuTorch and Arm environment
Export MobileSAM for Ethos-U85
Build and run MobileSAM on the Corstone-320 FVP
Validate the MobileSAM segmentation result
Next Steps
Run MobileSAM prompt segmentation on Arm Ethos-U85 with ExecuTorch
Review frequently asked questions
These FAQs were drafted with an approved AI-assisted workflow and reviewed by Arm contributors before publication. Human technical review remains part of the process so the final page reflects engineering rigor, accuracy, and Arm editorial standards.
Run the preflight check to verify macOS 15 or later on Apple silicon, or glibc 2.28 or later on Linux. You’ll also check
python3.12, git, c++, ninja, curl, pkg-config, and xz.Run commands from the
ExecuTorch repository root. Activate your Python environment and source setup_path.sh from the examples/arm/arm-scratch/ directory in the current shell.Prepare the pinned source and checkpoint first with
prepare_mobilesam.py. After running export_mobilesam.py without arguments, you’ll find mobilesam.pte, input.bin, host mask images, metrics.json, and delegation.txt under arm_test/mobilesam/export/. Check that fp32_quantized_iou in the metrics is at least 0.9.Confirm successful runner execution in
arm_test/mobilesam/fvp.log and check that output-0.bin under arm_test/mobilesam/io/ contains the target output tensor. Then run the visualization step to compare the target mask with your host quantized mask. If you use the complete run.sh workflow, you’ll see MobileSAM example: PASS after validation succeeds.Run the MobileSAM example’s
visualize_fvp_output.py without arguments, as shown in the validation step. Under arm_test/mobilesam/result/, check fvp_reference_iou in metrics.json and inspect fvp_comparison.png. You need an IoU of at least 0.9. This comparison checks agreement with your host mask on the example image.