|
47 | 47 | github_token: ${{ secrets.GITHUB_TOKEN}} |
48 | 48 | # missingInclude: cppcheck can't find stl, openvino, opencv |
49 | 49 | other_options: --suppress=missingInclude -Isrc/cpp/models/include -Isrc/cpp/utils/include -Isrc/cpp/pipelines/include --check-config |
50 | | - CPP-Precommit: |
51 | | - runs-on: ubuntu-22.04 |
52 | | - steps: |
53 | | - - uses: actions/checkout@v3 |
54 | | - - uses: actions/setup-python@v4 |
55 | | - with: |
56 | | - python-version: "3.10" |
57 | | - cache: pip |
58 | | - - name: Create and start a virtual environment |
59 | | - run: | |
60 | | - python -m venv venv |
61 | | - source venv/bin/activate |
62 | | - - name: Install dependencies |
63 | | - run: | |
64 | | - source venv/bin/activate |
65 | | - python -m pip install --upgrade pip |
66 | | - pip install src/python/[tests,build] --extra-index-url https://download.pytorch.org/whl/cpu |
67 | | -
|
68 | | - sudo bash src/cpp/install_dependencies.sh |
69 | | - - name: Prepare test data |
70 | | - run: | |
71 | | - source venv/bin/activate |
72 | | - python tests/cpp/precommit/prepare_data.py -d data -p tests/cpp/precommit/public_scope.json |
73 | | - - name: Build |
74 | | - run: | |
75 | | - mkdir build && cd build |
76 | | - pip install nanobind==2.4.0 |
77 | | - pip install typing_extensions==4.12.2 |
78 | | - cmake ../tests/cpp/precommit/ |
79 | | - cmake --build . -j $((`nproc`*2+2)) |
80 | | - - name: Run test |
81 | | - run: | |
82 | | - build/test_sanity -d data -p tests/cpp/precommit/public_scope.json && build/test_model_config -d data |
83 | | - CPP-Windows-Precommit: |
84 | | - runs-on: windows-latest |
85 | | - steps: |
86 | | - - uses: actions/checkout@v3 |
87 | | - - uses: actions/setup-python@v4 |
88 | | - with: |
89 | | - python-version: 3.9 |
90 | | - cache: pip |
91 | | - - name: Create and start a virtual environment |
92 | | - shell: bash |
93 | | - run: | |
94 | | - python -m venv venv |
95 | | - source venv/Scripts/activate |
96 | | - - name: Install dependencies |
97 | | - shell: bash |
98 | | - run: | |
99 | | - source venv/Scripts/activate |
100 | | - python -m pip install --upgrade pip |
101 | | - pip install src/python/[tests,build] --extra-index-url https://download.pytorch.org/whl/cpu |
102 | | - curl https://storage.openvinotoolkit.org/repositories/openvino/packages/2024.6/windows/w_openvino_toolkit_windows_2024.6.0.17404.4c0f47d2335_x86_64.zip --output w_openvino_toolkit_windows.zip |
103 | | - unzip w_openvino_toolkit_windows.zip |
104 | | - rm w_openvino_toolkit_windows.zip |
105 | | - curl -L https://github.com/opencv/opencv/releases/download/4.10.0/opencv-4.10.0-windows.exe --output opencv-4.10.0-windows.exe |
106 | | - ./opencv-4.10.0-windows.exe -oopencv -y |
107 | | - rm opencv-4.10.0-windows.exe |
108 | | - - name: Prepare test data |
109 | | - shell: bash |
110 | | - run: | |
111 | | - source venv/Scripts/activate |
112 | | - python tests/cpp/precommit/prepare_data.py -d data -p tests/cpp/precommit/public_scope.json |
113 | | - - name: Build |
114 | | - shell: bash |
115 | | - run: | |
116 | | - mkdir build && cd build |
117 | | - MSYS_NO_PATHCONV=1 cmake ../examples/cpp/ -DOpenVINO_DIR=$GITHUB_WORKSPACE/w_openvino_toolkit_windows_2024.6.0.17404.4c0f47d2335_x86_64/runtime/cmake -DOpenCV_DIR=$GITHUB_WORKSPACE/opencv/opencv/build -DCMAKE_CXX_FLAGS=/WX |
118 | | - cmake --build . --config Release -j $((`nproc`*2+2)) |
119 | | - - name: Run sync sample |
120 | | - shell: cmd |
121 | | - # .\w_openvino_toolkit_windows_2023.0.0.10926.b4452d56304_x86_64\setupvars.bat exits with 0 code without moving to a next command. Set PATH manually |
122 | | - run: | |
123 | | - set PATH=opencv\opencv\build\x64\vc16\bin;w_openvino_toolkit_windows_2024.6.0.17404.4c0f47d2335_x86_64\runtime\bin\intel64\Release;w_openvino_toolkit_windows_2024.6.0.17404.4c0f47d2335_x86_64\runtime\3rdparty\tbb\bin;%PATH% |
124 | | - .\build\Release\synchronous_api.exe .\data\otx_models\detection_model_with_xai_head.xml .\data\BloodImage_00007.jpg |
125 | 50 | serving_api: |
126 | 51 | strategy: |
127 | 52 | fail-fast: false |
|
0 commit comments