Skip to content

Commit 1e41b20

Browse files
committed
update README.md file
- updated README.md file according to review by Executorch team Signed-off-by: jiseong.oh <[email protected]>
1 parent 407b23a commit 1e41b20

File tree

2 files changed

+15
-13
lines changed

2 files changed

+15
-13
lines changed

backends/samsung/README.md

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
# ExecuTorch Samsung Exynos Delegate
22

3-
The subtree contains Exynos delegation implementation for ExecuTorch. The target of delegation
4-
is deploying torch model run with exynos NPU/DSP.
3+
The subtree contains Exynos delegate implementation for ExecuTorch. The target of delegation
4+
is deploying torch model to run with exynos NPU/DSP.
55

6-
This backend is implemented on the top of [EXYNOS_LITECORE](https://soc-developer.semiconductor.samsung.com/global/development/light-core)
6+
This backend is implemented on the top of [EXYNOS_LITECORE](https://soc-developer.semiconductor.samsung.com/global/development/ai-litecore)
77
Please prepare the SDK before you start, it is important to code compilation and runtime.
88

99
## Delegate Options
@@ -33,26 +33,26 @@ examples
3333
```
3434

3535
## How to build
36-
Please download Exynos AI LiteCore, and set the root path of SDK directory to `EXYNOS_AI_LITECORE_PATH`.</br>
36+
Please download Exynos AI LiteCore, and set the root path of SDK directory to `EXYNOS_AI_LITECORE_ROOT`.</br>
3737
Please navigate to [Android NDK](https://developer.android.com/ndk) and download a version of NDK.
3838
`ANDROID_NDK` refers the root path of NDK directory.</br>
3939

4040
### Set up environment variables
4141
```bash
42-
export LD_LIBRARY_PATH=${EXYNOS_AI_LITECORE_PATH}/lib64
42+
export LD_LIBRARY_PATH=${EXYNOS_AI_LITECORE_ROOT}/lib/x86_64-linux/
4343
```
4444

4545
### Build AOT Targets
46-
Generated python artifacts allow user call `Compile` interface to lower a model to ENN backend in python script.
46+
Generates python artifacts that allow user call `Compile` interface to lower a model to Exynos backend in python script.
4747
```bash
4848
./backends/samsung/build.sh -b x86_64
4949
```
5050

51-
### Build ENN Runtime
51+
### Build ENN Executor Runner
5252
```bash
5353
./backends/samsung/build.sh -b android --ndk ${ANDROID_NDK}
5454
```
55-
ANDROID_ABI=arm64-v8a is default, necessary runtime executable generate in `build_exynos_android` directory.
55+
ANDROID_ABI=arm64-v8a is default, necessary runtime executable generated in `build_exynos_android` directory.
5656

5757
### Build Anroid Extension
5858
This is later exposed Java app. Please turn on CMake option `EXECUTORCH_BUILD_ENN`, and ENN runtime will be added.
@@ -67,5 +67,6 @@ cmake --build cmake-android-out/extension/android -j8
6767
```
6868

6969
## Examples
70+
python -m executorch.examples.samsung.aot_compiler --chipset e9955 -m ic3
7071

7172
Please see this [README.md](../../examples/samsung/README.md).

examples/samsung/README.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,15 +25,17 @@ Check the chip's version, when lower the model, set the corresponding chip versi
2525
## Lowering
2626

2727
Before running an example, please copy python artifacts to target directory `PYTHON_TARGET_DIR`.
28+
If you use `build.sh` script to compile samsung backend, please skip the copy step.
29+
2830
Set up `PYTHON_TARGET_DIR` to `${EXECUTORCH_ROOT}/backends/samsung/python`.
2931
```bash
3032
cp -rf ${EXECUTORCH_ROOT}/build_x86_64/backends/samsung/Py*.so ${PYTHON_TARGET_DIR}
3133
cp -rf ${EXYNOS_AI_LITECORE_PATH}/python/snc_py_api*.so ${PYTHON_TARGET_DIR}
3234
```
3335

34-
Take `EXECUTORCH_ROOT` as work directory and here is an example for mul.
36+
Take `EXECUTORCH_ROOT` as work directory and here is an example for ic3.
3537
```bash
36-
python -m executorch.examples.samsung.aot_compiler -m mul
38+
python -m executorch.examples.samsung.aot_compiler --chipset E9955 -m ic3 --output_dir ic3_artifact
3739
```
3840

3941
## Execution
@@ -45,15 +47,14 @@ After lowering, we could get a pte model and then run it on mobile phone.
4547
DEVICE_DIR=/data/local/tmp/executorch
4648
adb shell mkdir ${DEVICE_DIR}
4749
adb push ${EXECUTORCH_ROOT}/cmake-android-out/backends/samsung/enn_executor_runner ${DEVICE_DIR}
48-
adb push ${EXYNOS_AI_LITECORE_PATH}/enn_api/libenn* ${DEVICE_DIR}
4950
```
5051

5152
#### Step 2: Indicate dynamic linkers and execute model
5253
```bash
53-
adb push ./mul_exynos_fp32.pte ${DEVICE_DIR}
54+
adb push ./ic3_exynos_fp32.pte ${DEVICE_DIR}
5455
adb shell "cd ${DEVICE_DIR} \
5556
&& export LD_LIBRARY_PATH=${DEVICE_DIR} \
56-
&& ./enn_executor_runner -model ./mul_exynos_fp32.pte"
57+
&& ./enn_executor_runner -model ./ic3_exynos_fp32.pte -input ./ic3_input_0.bin --output_path ."
5758
```
5859

5960
`enn_executor_runner` has more usages, please refer to the help message.

0 commit comments

Comments
 (0)