[HETERO] Fix problem with ov_hetero_unit_tests (#18794)
* [HETERO] Fix problem with ov_hetero_unit_tests * FIX 2 * Rename ov_hetero_unit_tests -> ov_hetero_func_tests
This commit is contained in:
parent
1a2e2551cd
commit
a930c74143
|
|
@ -366,8 +366,8 @@ jobs:
|
|||
- script: $(RUN_PREFIX) $(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: $(RUN_PREFIX) $(INSTALL_TEST_DIR)/ov_hetero_unit_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)/TEST-OVHeteroUnitTests.xml
|
||||
displayName: 'OV Hetero Unit Tests'
|
||||
- script: $(RUN_PREFIX) $(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: $(RUN_PREFIX) $(INSTALL_TEST_DIR)/ov_conditional_compilation_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)/TEST-ConditionalCompilation.xml
|
||||
displayName: 'Conditional Compilation Tests'
|
||||
|
|
|
|||
|
|
@ -282,6 +282,12 @@ jobs:
|
|||
LD_LIBRARY_PATH: $(INSTALL_TEST_DIR)
|
||||
displayName: 'OV Proxy Tests'
|
||||
|
||||
- script: |
|
||||
$(INSTALL_TEST_DIR)/ov_hetero_func_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)/TEST-OVHeteroFuncTests.xml
|
||||
env:
|
||||
LD_LIBRARY_PATH: $(INSTALL_TEST_DIR)
|
||||
displayName: 'OV Hetero Func Tests'
|
||||
|
||||
- script: $(INSTALL_TEST_DIR)/ov_onnx_frontend_tests --gtest_print_time=1 --gtest_filter=-*IE_GPU* --gtest_output=xml:$(INSTALL_TEST_DIR)/TEST-ONNXFrontend.xml
|
||||
env:
|
||||
LD_LIBRARY_PATH: $(INSTALL_TEST_DIR)
|
||||
|
|
|
|||
|
|
@ -188,8 +188,8 @@ jobs:
|
|||
displayName: 'OV Proxy Plugin Tests'
|
||||
enabled: 'false'
|
||||
|
||||
- script: . $(SETUPVARS) && $(INSTALL_TEST_DIR)/ov_hetero_unit_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)/TEST-OVHeteroUnitTests.xml
|
||||
displayName: 'OV Hetero Unit Tests'
|
||||
- script: . $(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'
|
||||
enabled: 'false'
|
||||
|
||||
- script: . $(SETUPVARS) && $(INSTALL_TEST_DIR)/ov_ir_frontend_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)/TEST-IRFrontend.xml
|
||||
|
|
|
|||
|
|
@ -266,8 +266,8 @@ jobs:
|
|||
- 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_unit_tests --gtest_print_time=1 --gtest_output=xml:$(INSTALL_TEST_DIR)\TEST-OVHeteroUnitTests.xml
|
||||
displayName: 'OV Hetero Unit 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'
|
||||
|
|
|
|||
|
|
@ -20,24 +20,24 @@ jobs:
|
|||
with:
|
||||
python-version: '3.10.10'
|
||||
architecture: 'x64'
|
||||
|
||||
|
||||
|
||||
|
||||
- name: Setup ccache
|
||||
uses: hendrikmuhs/ccache-action@v1.2
|
||||
with:
|
||||
max-size: 50G
|
||||
|
||||
|
||||
- name: Clone OpenVINO
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
submodules: recursive
|
||||
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
sudo apt --assume-yes update
|
||||
sudo -E ${{ github.workspace }}/install_build_dependencies.sh
|
||||
sudo apt --assume-yes install lcov
|
||||
|
||||
|
||||
python3 -m pip install --upgrade pip
|
||||
python3 -m pip install -r ${{ github.workspace }}/src/bindings/python/wheel/requirements-dev.txt
|
||||
python3 -m pip install -r ${{ github.workspace }}/src/bindings/python/requirements.txt
|
||||
|
|
@ -56,7 +56,7 @@ jobs:
|
|||
python3 -m pip install -r ${{ github.workspace }}/tools/mo/requirements_onnx.txt
|
||||
python3 -m pip install -r ${{ github.workspace }}/tools/mo/requirements_tf2.txt
|
||||
python3 -m pip install -r ${{ github.workspace }}/tools/mo/requirements_dev.txt
|
||||
|
||||
|
||||
- name: Get number of CPU cores
|
||||
uses: SimenB/github-actions-cpu-cores@v1
|
||||
id: cpu-cores
|
||||
|
|
@ -85,31 +85,34 @@ jobs:
|
|||
-DENABLE_SYSTEM_SNAPPY=ON
|
||||
build-type: Release
|
||||
parallel: ${{ steps.cpu-cores.outputs.count }}
|
||||
|
||||
|
||||
- name: Install wheel packages
|
||||
run: cmake -DCOMPONENT=python_wheels -DCMAKE_INSTALL_PREFIX=${{ github.workspace }}/install_pkg -P '${{ github.workspace }}/build/cmake_install.cmake'
|
||||
|
||||
|
||||
- name: Install python wheels
|
||||
run: python3 -m pip install openvino-dev --find-links=${{ github.workspace }}/install_pkg/tools
|
||||
|
||||
|
||||
- name: List binaries
|
||||
run: ls -la ${{ github.workspace }}/bin/intel64/Release
|
||||
|
||||
|
||||
- name: Install OpenVINO
|
||||
run: cmake -DCMAKE_INSTALL_PREFIX=${{ github.workspace }}/install_pkg -P '${{ github.workspace }}/build/cmake_install.cmake'
|
||||
|
||||
|
||||
- name: Run OV core unit tests
|
||||
run: ${{ github.workspace }}/bin/intel64/Release/ov_core_unit_tests
|
||||
|
||||
- name: Run OV Proxy plugin tests
|
||||
run: ${{ github.workspace }}/bin/intel64/Release/ov_proxy_plugin_tests
|
||||
|
||||
- name: Run OV Hetero Func tests
|
||||
run: ${{ github.workspace }}/bin/intel64/Release/ov_hetero_func_tests
|
||||
|
||||
- name: Run IR frontend tests
|
||||
run: ${{ github.workspace }}/bin/intel64/Release/ov_ir_frontend_tests # --gtest_print_time=1 --gtest_output=xml:${{ github.workspace }}/testdata/TEST-IRFrontend.xml
|
||||
|
||||
|
||||
- name: Run ONNX frontend tests
|
||||
run: ${{ github.workspace }}/bin/intel64/Release/ov_onnx_frontend_tests --gtest_filter=-*IE_GPU*
|
||||
|
||||
|
||||
#- name: Run Paddle frontend unit tests
|
||||
# run: ${{ github.workspace }}/bin/intel64/Release/paddle_tests --gtest_filter=-*IE_GPU*
|
||||
|
||||
|
|
@ -131,7 +134,7 @@ jobs:
|
|||
-DCMAKE_CXX_LINKER_LAUNCHER=ccache
|
||||
parallel: ${{ steps.cpu-cores.outputs.count }}
|
||||
|
||||
|
||||
|
||||
- name: Print info
|
||||
run: |
|
||||
ls -laR
|
||||
|
|
|
|||
|
|
@ -75,9 +75,9 @@ jobs:
|
|||
- name: Install build dependencies
|
||||
run: |
|
||||
sudo -E ${{ env.OPENVINO_REPO }}/install_build_dependencies.sh
|
||||
sudo -E apt update
|
||||
sudo -E apt update
|
||||
sudo -E apt --assume-yes install openjdk-11-jdk libbz2-dev clang unzip libpugixml-dev libtbb-dev intel-opencl-icd ocl-icd-opencl-dev opencl-headers
|
||||
|
||||
|
||||
wget https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-linux.zip
|
||||
unzip ninja-linux.zip
|
||||
sudo cp -v ninja /usr/local/bin/
|
||||
|
|
@ -94,16 +94,16 @@ jobs:
|
|||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/bindings/python/wheel/requirements-dev.txt
|
||||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/bindings/python/requirements.txt
|
||||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/bindings/python/requirements_test.txt
|
||||
|
||||
|
||||
# For running Python API tests
|
||||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/bindings/python/src/compatibility/openvino/requirements-dev.txt
|
||||
|
||||
|
||||
# For running ONNX frontend unit tests
|
||||
python3 -m pip install --force-reinstall -r ${{ env.OPENVINO_REPO }}/src/frontends/onnx/tests/requirements.txt
|
||||
|
||||
|
||||
# For running TensorFlow frontend unit tests
|
||||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/frontends/tensorflow/tests/requirements.txt
|
||||
|
||||
|
||||
# For running Paddle frontend unit tests
|
||||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/frontends/paddle/tests/requirements.txt
|
||||
|
||||
|
|
@ -294,7 +294,7 @@ jobs:
|
|||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
sudo -E apt update
|
||||
sudo -E apt update
|
||||
sudo -E apt --assume-yes install openjdk-11-jdk libbz2-dev clang unzip libpugixml-dev libtbb-dev intel-opencl-icd ocl-icd-opencl-dev opencl-headers
|
||||
|
||||
- name: Download OpenVINO package
|
||||
|
|
@ -450,6 +450,11 @@ jobs:
|
|||
source ${{ env.INSTALL_DIR }}/setupvars.sh
|
||||
${{ env.INSTALL_TEST_DIR }}/ov_proxy_plugin_tests --gtest_print_time=1 --gtest_output=xml:${{ env.INSTALL_TEST_DIR }}/TEST-OVProxyTests.xml
|
||||
|
||||
- name: Hetero Func Tests
|
||||
run: |
|
||||
source ${{ env.INSTALL_DIR }}/setupvars.sh
|
||||
${{ env.INSTALL_TEST_DIR }}/ov_hetero_func_tests --gtest_print_time=1 --gtest_output=xml:${{ env.INSTALL_TEST_DIR }}/TEST-OVHeteroFuncTests.xml
|
||||
|
||||
- name: Upload Test Results
|
||||
uses: actions/upload-artifact@v3
|
||||
if: ${{ always() }}
|
||||
|
|
@ -494,7 +499,7 @@ jobs:
|
|||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
sudo -E apt update
|
||||
sudo -E apt update
|
||||
sudo -E apt --assume-yes install openjdk-11-jdk libbz2-dev clang unzip libpugixml-dev libtbb-dev intel-opencl-icd ocl-icd-opencl-dev opencl-headers
|
||||
|
||||
- uses: actions/setup-python@v4
|
||||
|
|
@ -705,7 +710,7 @@ jobs:
|
|||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
sudo -E apt update
|
||||
sudo -E apt update
|
||||
sudo -E apt --assume-yes install openjdk-11-jdk libbz2-dev clang unzip libpugixml-dev libtbb-dev intel-opencl-icd ocl-icd-opencl-dev opencl-headers
|
||||
|
||||
- name: Download OpenVINO package
|
||||
|
|
|
|||
|
|
@ -85,16 +85,16 @@ jobs:
|
|||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/bindings/python/wheel/requirements-dev.txt
|
||||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/bindings/python/requirements.txt
|
||||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/bindings/python/requirements_test.txt
|
||||
|
||||
|
||||
# For running Python API tests
|
||||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/bindings/python/src/compatibility/openvino/requirements-dev.txt
|
||||
|
||||
|
||||
# For running ONNX frontend unit tests
|
||||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/frontends/onnx/tests/requirements.txt
|
||||
|
||||
|
||||
# For running TensorFlow frontend unit tests
|
||||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/frontends/tensorflow/tests/requirements.txt
|
||||
|
||||
|
||||
# For running Paddle frontend unit tests
|
||||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/frontends/paddle/tests/requirements.txt
|
||||
|
||||
|
|
@ -196,7 +196,7 @@ jobs:
|
|||
DestinationPath = "${{ env.BUILD_DIR }}/openvino_package.zip"
|
||||
}
|
||||
Compress-Archive @compress
|
||||
|
||||
|
||||
$file=Get-ChildItem -Path "${{ env.INSTALL_DIR }}\tests"
|
||||
$compress = @{
|
||||
Path = $file
|
||||
|
|
@ -365,14 +365,14 @@ jobs:
|
|||
- name: Model Optimizer UT
|
||||
shell: cmd
|
||||
run: |
|
||||
|
||||
|
||||
python3 -m pip install -r ${{ env.OPENVINO_REPO }}/tools/mo/requirements_mxnet.txt ^
|
||||
-r ${{ env.OPENVINO_REPO }}/tools/mo/requirements_caffe.txt ^
|
||||
-r ${{ env.OPENVINO_REPO }}/tools/mo/requirements_kaldi.txt ^
|
||||
-r ${{ env.OPENVINO_REPO }}/tools/mo/requirements_onnx.txt ^
|
||||
-r ${{ env.OPENVINO_REPO }}/tools/mo/requirements_tf2.txt ^
|
||||
-r ${{ env.OPENVINO_REPO }}/tools/mo/requirements_dev.txt
|
||||
|
||||
|
||||
set PYTHONPATH=${{ env.OPENVINO_REPO }}\tools\mo;${{ env.LAYER_TESTS_INSTALL_DIR }};${{ env.INSTALL_TEST_DIR }};${{ env.INSTALL_DIR }}\python\python3.11;%PYTHONPATH%
|
||||
|
||||
call "${{ env.INSTALL_DIR }}\\setupvars.bat" && python3 -m pytest -s ${{ env.INSTALL_TEST_DIR }}/mo/unit_tests --ignore=${{ env.INSTALL_TEST_DIR }}/mo/unit_tests/mo/front/mxnet --junitxml=${{ env.INSTALL_TEST_DIR }}/TEST-ModelOptimizer.xml
|
||||
|
|
@ -455,7 +455,7 @@ jobs:
|
|||
-r ${{ env.OPENVINO_REPO }}/tools/mo/requirements_onnx.txt ^
|
||||
-r ${{ env.OPENVINO_REPO }}/tools/mo/requirements_tf2.txt ^
|
||||
-r ${{ env.OPENVINO_REPO }}/tools/mo/requirements_dev.txt
|
||||
|
||||
|
||||
set PYTHONPATH=${{ env.OPENVINO_REPO }}\tools\mo;${{ env.LAYER_TESTS_INSTALL_DIR }};%PYTHONPATH%
|
||||
|
||||
call "${{ env.INSTALL_DIR }}\\setupvars.bat" && python3 -m pytest ${{ env.LAYER_TESTS_INSTALL_DIR }}/tensorflow_lite_tests/ --junitxml=${{ env.INSTALL_TEST_DIR }}/TEST-tfl_fe.xml
|
||||
|
|
@ -640,6 +640,11 @@ jobs:
|
|||
run: |
|
||||
call "${{ env.INSTALL_DIR }}\\setupvars.bat" && ${{ env.INSTALL_TEST_DIR }}/ov_proxy_plugin_tests --gtest_print_time=1 --gtest_output=xml:${{ env.INSTALL_TEST_DIR }}/TEST-OVProxyTests.xml
|
||||
|
||||
- name: Hetero Func Tests
|
||||
shell: cmd
|
||||
run: |
|
||||
call "${{ env.INSTALL_DIR }}\\setupvars.bat" && ${{ env.INSTALL_TEST_DIR }}/ov_hetero_func_tests --gtest_print_time=1 --gtest_output=xml:${{ env.INSTALL_TEST_DIR }}/TEST-OVHeteroFuncTests.xml
|
||||
|
||||
- name: Upload Test Results
|
||||
uses: actions/upload-artifact@v3
|
||||
if: ${{ always() }}
|
||||
|
|
|
|||
|
|
@ -29,6 +29,6 @@ ie_add_api_validator_post_build_step(TARGET ${TARGET_NAME})
|
|||
|
||||
set_target_properties(${TARGET_NAME} PROPERTIES INTERPROCEDURAL_OPTIMIZATION_RELEASE ${ENABLE_LTO})
|
||||
|
||||
if(ENABLE_TESTS)
|
||||
add_subdirectory(tests/unit)
|
||||
if(ENABLE_FUNCTIONAL_TESTS)
|
||||
add_subdirectory(tests/functional)
|
||||
endif()
|
||||
|
|
@ -2,7 +2,7 @@
|
|||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
set(TARGET_NAME ov_hetero_unit_tests)
|
||||
set(TARGET_NAME ov_hetero_func_tests)
|
||||
|
||||
ov_add_test_target(
|
||||
NAME ${TARGET_NAME}
|
||||
|
|
@ -15,7 +15,7 @@ ov_add_test_target(
|
|||
openvino::runtime::dev
|
||||
gtest
|
||||
gtest_main
|
||||
unit_test_utils
|
||||
common_test_utils
|
||||
ADD_CLANG_FORMAT
|
||||
LABELS
|
||||
HETERO
|
||||
|
|
@ -27,9 +27,9 @@
|
|||
namespace {
|
||||
|
||||
std::string get_mock_engine_path() {
|
||||
std::string mockEngineName("mock_engine");
|
||||
std::string mock_engine_name("mock_engine");
|
||||
return ov::util::make_plugin_library_name(CommonTestUtils::getExecutableDirectory(),
|
||||
mockEngineName + IE_BUILD_POSTFIX);
|
||||
mock_engine_name + IE_BUILD_POSTFIX);
|
||||
}
|
||||
|
||||
template <class T>
|
||||
|
|
@ -714,17 +714,15 @@ public:
|
|||
};
|
||||
|
||||
void ov::hetero::tests::HeteroTests::reg_plugin(std::shared_ptr<ov::IPlugin>& plugin) {
|
||||
std::string libraryPath = get_mock_engine_path();
|
||||
std::string library_path = get_mock_engine_path();
|
||||
if (!m_so)
|
||||
m_so = ov::util::load_shared_object(libraryPath.c_str());
|
||||
m_so = ov::util::load_shared_object(library_path.c_str());
|
||||
if (auto mock_plugin = std::dynamic_pointer_cast<MockPluginBase>(plugin))
|
||||
mock_plugin->set_version(mock_plugin->get_const_version());
|
||||
std::function<void(ov::IPlugin*)> injectProxyEngine = make_std_function<void(ov::IPlugin*)>(m_so, "InjectPlugin");
|
||||
|
||||
injectProxyEngine(plugin.get());
|
||||
core.register_plugin(ov::util::make_plugin_library_name(CommonTestUtils::getExecutableDirectory(),
|
||||
std::string("mock_engine") + IE_BUILD_POSTFIX),
|
||||
plugin->get_device_name());
|
||||
core.register_plugin(library_path, plugin->get_device_name());
|
||||
m_mock_plugins.emplace_back(plugin);
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue