mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-06-30 03:37:44 +00:00
* Simplify linux gpu pipeline * Refactor win-gpu-ci-pipeline.yml * Set cuda environment variables for testing and version * Remove variables from starter script * minor fix * Add GPU Nuget pipeline * Set DisableContribOps environment variable for Linux package tests * Add ESRP tasks * Add ESRP signing templates * Test out hardcode value of ERSP * Test out hardcode value of ERSP * Test out hardcode value of ERSP * Test out hardcode value of ERSP * test variable expansion * test variable expansion * test variable expansion * test variable expansion * test variable expansion * test variable expansion * test out variable expansion * test variable expansion * test variable expansion * test variable expansion * test variable expansion * test variable expansion * test variable expansion * test variable expansion * test variable expansion * update cpu pipeline to conditionally esrp sign * Set C# GPU tests to run only if env var is set * Refactor for easy parameter passing * refactored esrp templates * remove variables from template * Add packaging variables back to pipelines * update C# for cuda 10 * Merge vars ana parameters for gpu pipeline * remove vars from mklml pipeline * display envvars on terminal * Clean up C# cuda tests, and upgrade to Cuda10 * Introduce CUDNN_PATH pipeline varaible * YAML variable are always uppercased (not true with classic) * Update C# GPU test to be more meaningful * remove macos from gpu tests * remove debugging info for DisableContribOps option * Remove DisableContrib ops parameters -- use variables only * Fix typo from = to - * remove debug steps * fix typo * remove unused variable TESTONGPU from some templates * clean up CUDA env setup scripts * Remove CUDNN_PATH from setup_env_cuda.bat
54 lines
1.6 KiB
Bash
Executable file
54 lines
1.6 KiB
Bash
Executable file
#!/bin/bash
|
|
# Copyright (c) Microsoft Corporation. All rights reserved.
|
|
# Licensed under the MIT License.
|
|
|
|
# build docker image for CPU
|
|
|
|
set -x
|
|
|
|
SOURCE_ROOT=$1
|
|
BUILD_DIR=$2
|
|
NUGET_REPO_DIRNAME=$3 # path relative to BUILD_DIR
|
|
Arch=${4:-x64} # x32, x64
|
|
PackageName=${PackageName:-Microsoft.ML.OnnxRuntime}
|
|
RunTestCsharp=${RunTestCsharp:-true}
|
|
RunTestNative=${RunTestNative:-true}
|
|
PYTHON_VER=3.5
|
|
IMAGE="ubuntu16.04_$Arch"
|
|
|
|
OldDir=$(pwd)
|
|
|
|
cd $SOURCE_ROOT/tools/ci_build/github/linux/docker
|
|
if [ $Arch = "x86" ]; then
|
|
docker build -t "onnxruntime-$IMAGE" --build-arg OS_VERSION=16.04 --build-arg PYTHON_VERSION=${PYTHON_VER} -f Dockerfile.ubuntu_x86 .
|
|
else
|
|
docker build -t "onnxruntime-$IMAGE" --build-arg OS_VERSION=16.04 --build-arg PYTHON_VERSION=${PYTHON_VER} -f Dockerfile.ubuntu .
|
|
fi
|
|
|
|
docker rm -f "onnxruntime-cpu" || true
|
|
|
|
set +e
|
|
|
|
docker run -h $HOSTNAME \
|
|
--rm \
|
|
--name "onnxruntime-cpu" \
|
|
--volume "$SOURCE_ROOT:/onnxruntime_src" \
|
|
--volume "$BUILD_DIR:/home/onnxruntimedev" \
|
|
--volume "$HOME/.cache/onnxruntime:/home/onnxruntimedev/.cache/onnxruntime" \
|
|
-e "OnnxRuntimeBuildDirectory=/home/onnxruntimedev" \
|
|
-e "IsReleaseBuild=$IsReleaseBuild" \
|
|
-e "PackageName=$PackageName" \
|
|
-e "DisableContribOps=$DISABLECONTRIBOPS" \
|
|
-e "RunTestCsharp=$RunTestCsharp" \
|
|
-e "RunTestNative=$RunTestNative" \
|
|
"onnxruntime-$IMAGE" \
|
|
/bin/bash /onnxruntime_src/csharp/test/Microsoft.ML.OnnxRuntime.EndToEndTests/runtest.sh \
|
|
/home/onnxruntimedev/$NUGET_REPO_DIRNAME /onnxruntime_src /home/onnxruntimedev &
|
|
|
|
wait -n
|
|
|
|
EXIT_CODE=$?
|
|
|
|
set -e
|
|
exit $EXIT_CODE
|
|
cd $OldDir
|