From 9926045d5edd2d034cbbbad00c6021a2350162a4 Mon Sep 17 00:00:00 2001 From: yoni13 Date: Sat, 18 Jan 2025 16:32:08 +0800 Subject: [PATCH] add a simple script to notify user if some op is not supported --- machine-learning/rknn/export/convert.sh | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 machine-learning/rknn/export/convert.sh diff --git a/machine-learning/rknn/export/convert.sh b/machine-learning/rknn/export/convert.sh new file mode 100644 index 0000000000..99a33f60fd --- /dev/null +++ b/machine-learning/rknn/export/convert.sh @@ -0,0 +1,13 @@ +#!/bin/bash + +python3 build_rknn.py $1 $2 > immich_to_rknn2.log + +# if "No lowering found for" found in log file, return error status 1 +if grep -q "No lowering found for" immich_to_rknn2.log; then + echo -e "\e[31mSome operations are not supported by RKNN, please check the log file for details.\e[0m" + exit 1 +else + echo -e "\e[32mConversion completed successfully.\e[0m" + rm immich_to_rknn2.log + exit 0 +fi