precise-lite/entrypoint.sh
Tyler cf59c1ffcd
Some checks reported errors
continuous-integration/drone/push Build was killed
Use tensorflow 2.4.4 and GPU
2022-12-07 00:32:14 -05:00

33 lines
583 B
Bash
Executable File

#!/bin/bash
set -e
function populate_env() {
if [[ -z "$MODEL_PATH" ] && [ ! -z "$1" ]]; then
export MODEL_PATH="$1"
fi
if [[ -z "$DATA_FOLDER" ] && [ ! -z "$2" ]]; then
export DATA_FOLDER="$2"
fi
}
populate_env
case "$1" in
train)
precise-lite-train $TRAIN_ARGS "$MODEL_PATH" "$DATA_FOLDER"
;;
"train-incremental")
precise-lite-train-incremental $TRAIN_ARGS "$MODEL_PATH" "$DATA_FOLDER"
;;
test)
precise-lite-test "$MODEL_PATH" "$DATA_FOLDER"
;;
convert)
precise-lite-convert "$MODEL_PATH"
;;
*)
exec $@
;;
esac