REQUIRED_UNITS+=("souschef")
REQUIRED_UNITS+=("safemain")
REQUIRED_UNITS+=("arser")
+ REQUIRED_UNITS+=("vconone")
# Hermes Logging Framework
REQUIRED_UNITS+=("hermes" "hermes-std")
# loco IR and related utilities
REQUIRED_UNITS+=("tf2tfliteV2" "luci-interpreter" "circle-verify")
REQUIRED_UNITS+=("record-minmax" "circle-quantizer")
REQUIRED_UNITS+=("one-cmds")
+ REQUIRED_UNITS+=("bcq-tools")
+
+ NPROC=${NPROC:-$(cat /proc/cpuinfo | grep -c processor)}
# TODO Use "nncc configure" and "nncc build"
cmake \
-DCMAKE_INSTALL_PREFIX="${NNCC_INSTALL_PREFIX}" \
-DCMAKE_BUILD_TYPE=release \
-DBUILD_WHITELIST=$(join_by ";" "${REQUIRED_UNITS[@]}") \
+ -DEXTERNALS_BUILD_THREADS=$((NPROC/2)) \
${EXTRA_OPTIONS[@]} \
"${NNAS_PROJECT_PATH}/infra/nncc"
}
# Install tf2nnpkg
install -T -m 755 -D "${SCRIPT_PATH}/res/tf2nnpkg.${PRESET}" "${NNAS_INSTALL_PREFIX}/bin/tf2nnpkg"
-
- # Create python virtual enviornment
- python3 -m venv "${NNAS_INSTALL_PREFIX}/bin/venv"
-
- # Install tensorflow
- source "${NNAS_INSTALL_PREFIX}/bin/venv/bin/activate"
- python -m pip --default-timeout=1000 --trusted-host pypi.org --trusted-host files.pythonhost.org \
- install -U pip setuptools
- python -m pip --default-timeout=1000 --trusted-host pypi.org --trusted-host files.pythonhost.org \
- install tensorflow-cpu==2.3.0rc0
}