350 lines
15 KiB
YAML
350 lines
15 KiB
YAML
trigger:
|
|
branches:
|
|
include:
|
|
- 'master'
|
|
- 'releases/*'
|
|
paths:
|
|
exclude:
|
|
- '*/docs/*'
|
|
- 'docs/*'
|
|
- '*/*.md'
|
|
- '*.md'
|
|
- '*/layer_tests_summary/*'
|
|
- '*/conformance/*'
|
|
|
|
pr:
|
|
branches:
|
|
include:
|
|
- 'master'
|
|
- 'releases/*'
|
|
paths:
|
|
exclude:
|
|
- '*/docs/*'
|
|
- 'docs/*'
|
|
- '*/*.md'
|
|
- '*.md'
|
|
- '*/layer_tests_summary/*'
|
|
- '*/conformance/*'
|
|
|
|
resources:
|
|
repositories:
|
|
- repository: openvino_contrib
|
|
type: github
|
|
endpoint: openvinotoolkit
|
|
name: openvinotoolkit/openvino_contrib
|
|
ref: master
|
|
|
|
- repository: testdata
|
|
type: github
|
|
endpoint: openvinotoolkit
|
|
name: openvinotoolkit/testdata
|
|
ref: master
|
|
|
|
jobs:
|
|
- job: Win
|
|
strategy:
|
|
matrix:
|
|
Static:
|
|
CMAKE_BUILD_SHARED_LIBS: 'OFF'
|
|
# Dynamic:
|
|
# CMAKE_BUILD_SHARED_LIBS: 'ON'
|
|
maxParallel: '2'
|
|
|
|
# About 150% of total time
|
|
timeoutInMinutes: '270' #Temporary change
|
|
|
|
pool:
|
|
name: WIN_VMSS_VENV_D8S_WU2
|
|
|
|
variables:
|
|
system.debug: true
|
|
VSTS_HTTP_RETRY: 5
|
|
VSTS_HTTP_TIMEOUT: 200
|
|
BUILD_TYPE: Release
|
|
REPO_DIR: $(Build.Repository.LocalPath)
|
|
OPENVINO_CONTRIB_REPO_DIR: $(REPO_DIR)\..\openvino_contrib
|
|
MODELS_PATH: $(REPO_DIR)\..\testdata
|
|
WORK_DIR: $(Pipeline.Workspace)\_w
|
|
BUILD_DIR: $(WORK_DIR)\build
|
|
BUILD_SAMPLES_DIR: $(WORK_DIR)\build_samples
|
|
BUILD_SAMPLES_TESTS_DIR: $(WORK_DIR)\build_samples_tests
|
|
MSVS_VARS_PATH: C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvars64.bat
|
|
MSVC_COMPILER_PATH: C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.24.28314\bin\Hostx64\x64\cl.exe
|
|
INSTALL_DIR: $(WORK_DIR)\install_pkg
|
|
INSTALL_TEST_DIR: $(INSTALL_DIR)\tests
|
|
SETUPVARS: $(INSTALL_DIR)\setupvars.bat
|
|
PYTHON_DIR: C:\hostedtoolcache\windows\Python\3.11.2\x64
|
|
CMAKE_VERSION: 3.24.0
|
|
CMAKE_CMD: $(WORK_DIR)\cmake-$(CMAKE_VERSION)-windows-x86_64\cmake-$(CMAKE_VERSION)-windows-x86_64\bin\cmake.exe
|
|
OV_CMAKE_TOOLCHAIN_FILE: $(REPO_DIR)\cmake\toolchains\mt.runtime.win32.toolchain.cmake
|
|
PYTHON_VENV_DIR: $(WORK_DIR)\.venv
|
|
|
|
|
|
steps:
|
|
- script: |
|
|
rd /Q /S $(WORK_DIR) & mkdir $(WORK_DIR)
|
|
rd /Q /S $(BUILD_DIR) & mkdir $(BUILD_DIR)
|
|
rd /Q /S $(WORK_DIR) & mkdir C:\hostedtoolcache\windows\Python\3.11.2
|
|
rd /Q /S $(BUILD_DIR) & mkdir C:\hostedtoolcache\windows\Python\3.11.2\x64
|
|
rd /Q /S $(BUILD_SAMPLES_DIR) & mkdir $(BUILD_SAMPLES_DIR)
|
|
rd /Q /S $(BUILD_SAMPLES_TESTS_DIR) & mkdir $(BUILD_SAMPLES_TESTS_DIR)
|
|
displayName: 'Make dir'
|
|
|
|
- script: curl -O https://www.python.org/ftp/python/3.11.2/python-3.11.2-amd64.exe
|
|
displayName: 'Download Python'
|
|
workingDirectory: $(WORK_DIR)
|
|
|
|
- script: |
|
|
python-3.11.2-amd64.exe /passive InstallAllUsers=0 Include_launcher=0 TargetDir=C:\hostedtoolcache\windows\Python\3.11.2\x64 && ^
|
|
cp C:\hostedtoolcache\windows\Python\3.8.2\x64.complete C:\hostedtoolcache\windows\Python\3.11.2\x64.complete
|
|
displayName: 'Install Python'
|
|
workingDirectory: $(WORK_DIR)
|
|
|
|
- task: UsePythonVersion@0
|
|
displayName: 'Use Python'
|
|
inputs:
|
|
versionSpec: '3.11.2'
|
|
disableDownloadFromRegistry: true
|
|
|
|
- script: |
|
|
powershell -command "Invoke-RestMethod -Headers @{\"Metadata\"=\"true\"} -Method GET -Uri http://169.254.169.254/metadata/instance/compute?api-version=2019-06-01 | format-custom"
|
|
tree C:\hostedtoolcache\windows\Python
|
|
where python
|
|
python --version
|
|
where java
|
|
java -version
|
|
wmic computersystem get TotalPhysicalMemory
|
|
wmic cpu list
|
|
wmic logicaldisk get description,name
|
|
wmic VOLUME list
|
|
set
|
|
displayName: 'System info'
|
|
|
|
- checkout: self
|
|
clean: 'true'
|
|
submodules: 'true'
|
|
path: openvino
|
|
|
|
- checkout: openvino_contrib
|
|
clean: 'true'
|
|
submodules: 'true'
|
|
path: openvino_contrib
|
|
|
|
- checkout: testdata
|
|
clean: 'true'
|
|
lfs: 'true'
|
|
path: testdata
|
|
|
|
- script: |
|
|
python -m pip install --upgrade pip
|
|
rem For running Python API tests
|
|
python -m pip install -r $(REPO_DIR)\src\bindings\python\src\compatibility\openvino\requirements-dev.txt
|
|
python -m pip install -r $(REPO_DIR)\src\bindings\python\wheel\requirements-dev.txt
|
|
python -m pip install -r $(REPO_DIR)\src\bindings\python\requirements.txt
|
|
rem For running Paddle frontend unit tests
|
|
# TODO Reenable PDPD after paddlepaddle==2.5.0 with compliant protobuf is released (ticket 95904)
|
|
#python -m pip install -r $(REPO_DIR)\src\frontends\paddle\tests\requirements.txt
|
|
rem For running ONNX frontend unit tests
|
|
python -m pip install -r $(REPO_DIR)\src\frontends\onnx\tests\requirements.txt
|
|
rem For running TensorFlow frontend unit tests
|
|
python -m pip install -r $(REPO_DIR)\src\frontends\tensorflow\tests\requirements.txt
|
|
rem For MO unit tests
|
|
python -m pip install -r $(REPO_DIR)\tools\mo\requirements.txt
|
|
python -m pip install -r $(REPO_DIR)\tools\mo\requirements_dev.txt
|
|
rem Speed up build
|
|
powershell -command "Invoke-WebRequest https://github.com/Kitware/CMake/releases/download/v$(CMAKE_VERSION)/cmake-$(CMAKE_VERSION)-windows-x86_64.zip -OutFile cmake-$(CMAKE_VERSION)-windows-x86_64.zip"
|
|
powershell -command "Expand-Archive -Force cmake-$(CMAKE_VERSION)-windows-x86_64.zip"
|
|
powershell -command "Invoke-WebRequest https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip -OutFile ninja-win.zip"
|
|
powershell -command "Expand-Archive -Force ninja-win.zip"
|
|
workingDirectory: $(WORK_DIR)
|
|
displayName: 'Install dependencies'
|
|
|
|
- powershell: |
|
|
Write-Host "##vso[task.setvariable variable=CMAKE_TOOLCHAIN_FILE]$(OV_CMAKE_TOOLCHAIN_FILE)"
|
|
condition: eq(variables['CMAKE_BUILD_SHARED_LIBS'], 'ON')
|
|
displayName: "Set cmake toolchain"
|
|
|
|
- script: |
|
|
set PATH=$(WORK_DIR)\ninja-win;%PATH% && ^
|
|
call "$(MSVS_VARS_PATH)" && $(CMAKE_CMD) ^
|
|
-G "Ninja Multi-Config" ^
|
|
-DENABLE_CPPLINT=OFF ^
|
|
-DENABLE_ONEDNN_FOR_GPU=$(CMAKE_BUILD_SHARED_LIBS) ^
|
|
-DBUILD_SHARED_LIBS=$(CMAKE_BUILD_SHARED_LIBS) ^
|
|
-DENABLE_FASTER_BUILD=ON ^
|
|
-DENABLE_TESTS=ON ^
|
|
-DCMAKE_COMPILE_WARNING_AS_ERROR=ON ^
|
|
-DENABLE_STRICT_DEPENDENCIES=OFF ^
|
|
-DENABLE_PYTHON=ON ^
|
|
-DBUILD_nvidia_plugin=OFF ^
|
|
-DCUSTOM_OPERATIONS="calculate_grid;complex_mul;fft;grid_sample;sparse_conv;sparse_conv_transpose" ^
|
|
-DPYTHON_EXECUTABLE="C:\hostedtoolcache\windows\Python\3.11.2\x64\python.exe" ^
|
|
-DPYTHON_INCLUDE_DIR="C:\hostedtoolcache\windows\Python\3.11.2\x64\include" ^
|
|
-DPYTHON_LIBRARY="C:\hostedtoolcache\windows\Python\3.11.2\x64\libs\python311.lib" ^
|
|
-DOPENVINO_EXTRA_MODULES=$(OPENVINO_CONTRIB_REPO_DIR)\modules ^
|
|
-DCMAKE_C_COMPILER:PATH="$(MSVC_COMPILER_PATH)" ^
|
|
-DCMAKE_CXX_COMPILER:PATH="$(MSVC_COMPILER_PATH)" ^
|
|
-S $(REPO_DIR) ^
|
|
-B $(BUILD_DIR)
|
|
displayName: 'CMake OpenVINO'
|
|
|
|
- script: dir $(REPO_DIR)\temp\ /s
|
|
displayName: 'List temp SDKs'
|
|
|
|
- script: |
|
|
set PATH=$(WORK_DIR)\ninja-win;%PATH% && ^
|
|
call "$(MSVS_VARS_PATH)" && $(CMAKE_CMD) --build $(BUILD_DIR) --parallel --config Release"
|
|
displayName: 'Build Win'
|
|
|
|
- script: dir $(REPO_DIR)\bin\ /s
|
|
displayName: 'List bin files'
|
|
|
|
- script: $(CMAKE_CMD) -DCMAKE_INSTALL_PREFIX=$(INSTALL_DIR) -P $(BUILD_DIR)/cmake_install.cmake
|
|
displayName: 'Install'
|
|
|
|
- script: dir $(INSTALL_DIR) /s
|
|
displayName: 'List install files'
|
|
|
|
- script: python -m pip install openvino-dev --find-links=$(INSTALL_DIR)\tools
|
|
displayName: 'Install Wheels'
|
|
|
|
- script: |
|
|
call "$(MSVS_VARS_PATH)" && ^
|
|
$(CMAKE_CMD) ^
|
|
-DCMAKE_C_COMPILER:PATH="$(MSVC_COMPILER_PATH)" ^
|
|
-DCMAKE_CXX_COMPILER:PATH="$(MSVC_COMPILER_PATH)" ^
|
|
-S $(REPO_DIR)\tests\samples_tests ^
|
|
-B $(BUILD_SAMPLES_TESTS_DIR)
|
|
displayName: 'CMake Samples Tests'
|
|
|
|
- script: $(CMAKE_CMD) -DCOMPONENT=tests -DCMAKE_INSTALL_PREFIX=$(INSTALL_DIR) -P $(BUILD_SAMPLES_TESTS_DIR)\cmake_install.cmake
|
|
displayName: 'Install Samples Tests'
|
|
|
|
- script: |
|
|
$(INSTALL_DIR)\samples\cpp\build_samples_msvc.bat -i $(INSTALL_DIR)
|
|
if not exist %USERPROFILE%\Documents\Intel\OpenVINO\openvino_cpp_samples_build\ exit 1
|
|
displayName: 'Build cpp samples'
|
|
|
|
- script: |
|
|
$(INSTALL_DIR)\samples\c\build_samples_msvc.bat -i $(INSTALL_DIR)
|
|
if not exist %USERPROFILE%\Documents\Intel\OpenVINO\openvino_c_samples_build\ exit 1
|
|
displayName: 'Build c samples'
|
|
|
|
- script: python -m pip install -r $(INSTALL_TEST_DIR)\smoke_tests\requirements.txt
|
|
displayName: 'Install dependencies for samples smoke tests'
|
|
|
|
- script: |
|
|
call $(SETUPVARS) && ^
|
|
python -m pytest $(INSTALL_DIR)\tests\smoke_tests\ --env_conf $(INSTALL_TEST_DIR)\smoke_tests\env_config.yml -s --junitxml=$(INSTALL_TEST_DIR)/TEST-SamplesSmokeTests.xml
|
|
env:
|
|
IE_APP_PATH: $(INSTALL_DIR)\samples_bin
|
|
IE_APP_PYTHON_PATH: $(INSTALL_DIR)\samples\python\
|
|
SHARE: $(INSTALL_DIR)\tests\smoke_tests\samples_smoke_tests_data\
|
|
WORKSPACE: $(INSTALL_DIR)
|
|
displayName: 'Samples Smoke Tests'
|
|
|
|
- script: $(CMAKE_CMD) -DCMAKE_INSTALL_PREFIX=$(INSTALL_DIR) -DCOMPONENT=tests -P $(BUILD_DIR)\cmake_install.cmake
|
|
displayName: 'Install tests'
|
|
|
|
- script: dir $(INSTALL_DIR) /s
|
|
displayName: 'List install files'
|
|
|
|
- script: rd /Q /S $(BUILD_DIR)
|
|
displayName: 'Clean build dir'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_core_unit_tests --gtest_print_time=1 --gtest_filter=-*IE_GPU* --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-NGraphUT.xml
|
|
displayName: 'OV Core UT'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_inference_functional_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-InferenceFunc.xml
|
|
displayName: 'Inference Func Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_inference_unit_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-InferenceUnit.xml
|
|
displayName: 'Inference Unit Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_proxy_plugin_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-OVProxyTests.xml
|
|
displayName: 'OV Proxy Plugin Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_hetero_func_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-OVHeteroFuncTests.xml
|
|
displayName: 'OV Hetero Func Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_conditional_compilation_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-ConditionalCompilation.xml
|
|
displayName: 'Conditional Compilation Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_ir_frontend_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-IRFrontend.xml
|
|
displayName: 'IR Frontend Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_onnx_frontend_tests --gtest_print_time=1 --gtest_filter=-*IE_GPU* --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-ONNXFrontend.xml
|
|
displayName: 'ONNX Frontend Tests'
|
|
|
|
# TODO Reenable PDPD after paddlepaddle==2.5.0 with compliant protobuf is released (ticket 95904)
|
|
#- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\paddle_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-Paddle.xml
|
|
# displayName: 'Paddle Frontend UT'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_tensorflow_frontend_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-Tensorflow.xml
|
|
displayName: 'TensorFlow Frontend Unit Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_tensorflow_common_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-TensorflowCommon.xml
|
|
displayName: 'TensorFlow Common Unit Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_tensorflow_lite_frontend_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-TensorflowLite.xml
|
|
displayName: 'TensorFlow Lite Frontend Unit Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_lp_transformations_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\LpTransformations.xml
|
|
displayName: 'Low Precision Transformations Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_transformations_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\Transformations.xml
|
|
displayName: 'Transformations Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_legacy_transformations_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\LegacyTransformations.xml
|
|
displayName: 'Legacy Transformations Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_util_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\CommonUtilTests.xml
|
|
displayName: 'Common Utils Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\InferenceEngineUnitTests --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-InferenceEngineUnitTests.xml
|
|
displayName: 'IE UT old'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_snippets_func_tests --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-ov_snippets_func_tests.xml
|
|
displayName: 'Snippets Func Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_cpu_unit_tests --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-ov_cpu_unit_tests.xml
|
|
displayName: 'Intel CPU Unit Tests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_gna_unit_tests --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-ov_gna_unit_tests.xml
|
|
displayName: 'GNA UT'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_auto_unit_tests --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-ov_auto_unit_tests.xml
|
|
displayName: 'AUTO UT'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_auto_batch_unit_tests --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-ov_auto_batch_unit_tests.xml
|
|
displayName: 'AutoBatch UT'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_template_func_tests --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-templateFuncTests.xml
|
|
displayName: 'TEMPLATE FuncTests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_auto_batch_func_tests --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-ov_auto_batch_func_tests.xml
|
|
displayName: 'AutoBatch FuncTests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\InferenceEngineCAPITests --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-InferenceEngineCAPITests.xml
|
|
displayName: 'IE CAPITests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_capi_test --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-ov_capi_test.xml
|
|
displayName: 'OV CAPITests'
|
|
|
|
- script: call $(SETUPVARS) && $(INSTALL_TEST_DIR)\ov_cpu_func_tests --gtest_filter=*smoke* --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-ov_cpu_func_tests.xml
|
|
displayName: 'CPU FuncTests'
|
|
condition: and(succeeded(), eq(variables['CMAKE_BUILD_SHARED_LIBS'], 'OFF'))
|
|
|
|
- task: PublishTestResults@2
|
|
condition: always()
|
|
inputs:
|
|
testResultsFormat: 'JUnit' # Options: JUnit, NUnit, VSTest, xUnit, cTest
|
|
testResultsFiles: '**/TEST-*.xml'
|
|
#searchFolder: '$(BUILD_DIR)'
|
|
mergeTestResults: false # Optional
|
|
#failTaskOnFailedTests: false # Optional
|
|
#testRunTitle: 'Pre/Post-Commit' # Optional
|
|
buildPlatform: 'x64' # Optional
|
|
buildConfiguration: 'Windows' # Optional
|
|
#publishRunAttachments: true # Optional
|