Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ONNX CI improvement #3673

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions ngraph/python/tests/test_onnx/model_zoo_preprocess.sh
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ function pull_and_postprocess_onnx_model_zoo() {
mkdir -p test_data_set_0
mv *.pb test_data_set_0/

# Save SHA of successfully post processed repository
git rev-parse HEAD > onnx_sha
}

function update_onnx_models() {
Expand All @@ -90,7 +92,7 @@ function update_onnx_models() {
pull_and_postprocess_onnx_model_zoo
else
# Check if ONNX Model Zoo directory consists of proper git repo
git_remote_url=`git -C $ONNX_MODELS_DIR config --local remote.origin.url 2> /dev/null 2>&1`
export git_remote_url=`git -C $ONNX_MODELS_DIR config --local remote.origin.url 2> /dev/null 2>&1`
printf "ONNX Model Zoo repository exists: %s\n" "$ONNX_MODELS_DIR"
if [[ $git_remote_url = "https://github.com/onnx/models.git" ]]; then
printf "The proper github repository detected: %s\n" "$git_remote_url"
Expand All @@ -101,7 +103,7 @@ function update_onnx_models() {
fi

cd "$ONNX_MODELS_DIR"
CURRENT_ONNX_MODELS_SHA=`git rev-parse HEAD`
export CURRENT_ONNX_MODELS_SHA=`head -n1 onnx_sha 2> /dev/null 2>&1`
if [[ $ONNX_SHA = $CURRENT_ONNX_MODELS_SHA ]] ; then
echo "ONNX Model Zoo repository is in the right state"
else
Expand Down