forked from CMU-Perceptual-Computing-Lab/openpose
-
Notifications
You must be signed in to change notification settings - Fork 2
295 lines (285 loc) · 10.2 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
name: CI
on: [push, pull_request]
env:
GH_REPO_NAME: ${{ github.event.repository.name }}
DOXYFILE: ${{ github.workspace }}/.doc_autogeneration.doxygen
GH_REPO_REF: ${{ github.repositoryUrl }}
jobs:
build:
name: ${{ matrix.env.NAME }}
runs-on: ${{ matrix.os }}
env: ${{ matrix.env }}
strategy:
fail-fast: false
matrix:
include:
# Ubuntu
# Ubuntu 20.04 - Default - CMake - CUDA
- os: ubuntu-20.04
os_name: linux
env:
NAME: U20-default-cmake-cuda
WITH_CUDNN: false
CI_OS_NAME: linux
# Ubuntu 18.04 - Default - CMake - CUDA
- os: ubuntu-18.04
os_name: linux
env:
NAME: U18-default-cmake-cuda
WITH_CUDNN: false
CI_OS_NAME: linux
# Ubuntu 20.04 - Python - CMake - CUDA
- os: ubuntu-20.04
os_name: linux
env:
NAME: U20-python-cmake-cuda
WITH_CUDNN: false
WITH_PYTHON: true
CI_OS_NAME: linux
CI_BUILD_NUMBER: ${{ github.run_number }}
CI_COMMIT: ${{ github.sha }}
PYTHON3_VERSION: python3.8
DOCS: true
# Ubuntu 18.04 - Python - CMake - CUDA
- os: ubuntu-18.04
os_name: linux
env:
NAME: U18-python-cmake-cuda
WITH_CUDNN: false
WITH_PYTHON: true
CI_OS_NAME: linux
# Ubuntu 20.04 - Python - CMake - CPU
- os: ubuntu-20.04
os_name: linux
env:
NAME: U20-python-cmake-cpu
WITH_PYTHON: true
WITH_CUDA: false
WITH_CUDNN: false
CI_OS_NAME: linux
PYTHON3_VERSION: python3.8
# Ubuntu 18.04 - Python - CMake - CPU
- os: ubuntu-18.04
os_name: linux
env:
NAME: U18-python-cmake-cpu
WITH_PYTHON: true
WITH_CUDA: false
WITH_CUDNN: false
CI_OS_NAME: linux
# TO-DO (not passing)
# # Ubuntu 20.04 - Python - CMake - OpenCL
# - os: ubuntu-20.04
# os_name: linux
# env:
# NAME: U20-python-cmake-opencl
# WITH_PYTHON: true
# WITH_CUDA: false
# WITH_CUDNN: false
# WITH_OPEN_CL: true
# CI_OS_NAME: linux
# PYTHON3_VERSION: python3.8
# Ubuntu 18.04 - Python - CMake - OpenCL
- os: ubuntu-18.04
os_name: linux
env:
NAME: U18-python-cmake-opencl
WITH_PYTHON: true
WITH_CUDA: false
WITH_CUDNN: false
WITH_OPEN_CL: true
CI_OS_NAME: linux
# Ubuntu 20.04 - Python - CMake - CPU - Debug
- os: ubuntu-20.04
os_name: linux
env:
NAME: U20-python-cmake-cpu-debug
WITH_PYTHON: true
WITH_CUDA: false
WITH_CUDNN: false
WITH_DEBUG: true
CI_OS_NAME: linux
PYTHON3_VERSION: python3.8
# Ubuntu 18.04 - Python - CMake - CPU - Debug
- os: ubuntu-18.04
os_name: linux
env:
NAME: U18-python-cmake-cpu-debug
WITH_PYTHON: true
WITH_CUDA: false
WITH_CUDNN: false
WITH_DEBUG: true
CI_OS_NAME: linux
# Ubuntu 20.04 - Python - CMake - CPU - Unity
- os: ubuntu-20.04
os_name: linux
env:
NAME: U20-python-cmake-cpu-unity
WITH_PYTHON: true
WITH_UNITY: true
WITH_CUDA: false
WITH_CUDNN: false
CI_OS_NAME: linux
PYTHON3_VERSION: python3.8
# Ubuntu 20.04 - Default - CMake - CPU
- os: ubuntu-20.04
os_name: linux
env:
NAME: U20-default-cmake-cpu
WITH_CUDA: false
WITH_CUDNN: false
CI_OS_NAME: linux
# Mac OSX
# Mac OSX - Python - CMake - CPU
- os: macos-10.15
os_name: osx
env:
NAME: OSX-python-cmake-cpu
WITH_CUDA: false
WITH_CUDNN: false
WITH_PYTHON: true
CI_OS_NAME: osx
# Mac OSX - Python - CMake - OpenCL
- os: macos-10.15
os_name: osx
env:
NAME: OSX-default-cmake-opencl
WITH_CUDA: false
WITH_CUDNN: false
WITH_OPEN_CL: true
CI_OS_NAME: osx
# Mac OSX - Python - CMake - CPU - Debug
- os: macos-10.15
os_name: osx
env:
NAME: OSX-python-cmake-cpu-debug
WITH_CUDA: false
WITH_CUDNN: false
WITH_PYTHON: true
WITH_DEBUG: true
CI_OS_NAME: osx
# Mac OSX - Python - CMake - CPU - Unity
- os: macos-10.15
os_name: osx
env:
NAME: OSX-python-cmake-cpu-unity
WITH_CUDA: false
WITH_CUDNN: false
WITH_PYTHON: true
WITH_UNITY: true
CI_OS_NAME: osx
# Mac OSX - Default - CMake - CPU
- os: macos-10.15
os_name: osx
env:
NAME: OSX-default-cmake-cpu
WITH_CUDA: false
WITH_CUDNN: false
CI_OS_NAME: osx
# TO-DO (not passing)
# Note: CUDA jobs fail in U16 because of an issue with GCC 5.5 (https://github.com/NVIDIA/apex/issues/529). GH Actions doesn't support
# GCC 5.4 and CUDA does not support newer than GCC 5.X. Thus, cuDNN (sh file only for Ubuntu 16) is no longer tested.
# # Ubuntu 16.04
# # Ubuntu 16.04 - Default - CMake - CUDA
# - os: ubuntu-16.04
# os_name: linux
# env:
# NAME: U16-default-cmake-cuda8
# CI_OS_NAME: linux
# # Deprecated (not working for the above issue between CUDA and the Ubuntu16 from GitHub Actions)
# # Ubuntu 16.04 - Default - Make - CUDA
# - os: ubuntu-16.04
# os_name: linux
# env:
# NAME: U16-default-make-cuda
# WITH_CUDNN: false
# WITH_CMAKE: false
# CI_OS_NAME: linux
# Ubuntu 16 no longer works
# # Ubuntu 16.04 - Python - CMake - CPU
# - os: ubuntu-16.04
# os_name: linux
# env:
# NAME: U16-python-cmake-cpu
# WITH_PYTHON: true
# WITH_CUDA: false
# WITH_CUDNN: false
# CI_OS_NAME: linux
# # Ubuntu 16.04 - Python - CMake - OpenCL
# - os: ubuntu-16.04
# os_name: linux
# env:
# NAME: U16-python-cmake-opencl
# WITH_PYTHON: true
# WITH_CUDA: false
# WITH_CUDNN: false
# WITH_OPEN_CL: true
# CI_OS_NAME: linux
# # Ubuntu 16.04 - Python - CMake - CPU - Debug
# - os: ubuntu-16.04
# os_name: linux
# env:
# NAME: U16-python-cmake-cpu-debug
# WITH_PYTHON: true
# WITH_CUDA: false
# WITH_CUDNN: false
# WITH_DEBUG: true
# CI_OS_NAME: linux
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
submodules: recursive
- uses: actions/setup-python@v2
with:
python-version: 2.x
if: ${{ matrix.env.WITH_PYTHON }}
- name: Install (Linux)
run: scripts/CI/install_deps_ubuntu.sh
if: ${{ matrix.os_name == 'linux' }}
- name: Install (Mac OS)
run: scripts/CI/install_deps_osx.sh
if: ${{ matrix.os_name == 'osx' }}
- name: Configure
run: scripts/CI/configure.sh
- name: Make
run: scripts/CI/run_make.sh
- name: Tests
run: scripts/CI/run_tests.sh
- name: Docs APT packages
run: |
# The Doxygen apt-get version for Ubuntu 20 is 1.8.17, which has some bugs fixed in 1.9.1
# run: sudo apt-get -yq install doxygen doxygen-doc doxygen-latex doxygen-gui graphviz
git clone https://github.com/doxygen/doxygen.git && cd doxygen && git checkout Release_1_9_1
mkdir build && cd build
cmake -G "Unix Makefiles" ..
make -j`nproc`
sudo make install
if: ${{ matrix.DOCS }}
- name: Generate docs
run: |
cd ${{ github.workspace }}
echo 'Generating Doxygen code documentation...'
doxygen $DOXYFILE 2>&1 | tee doxygen.log
# Required so Doxygen links/finds the license file
cp LICENSE doxygen/html/LICENSE
# Required in order to link .github/media/ images with doc without modifying doc links. Remove if using `publish_dir: doxygen/html/`
mkdir -p doxygen_final/web/html/ && mv doxygen/html doxygen_final/web/html/doc
mkdir -p doxygen_final/web/.github/media/ && cp -rf .github/media/ doxygen_final/web/.github/
mkdir -p doxygen_final/web/html/.github/media/ && cp -rf .github/media/ doxygen_final/web/html/.github/
mkdir -p doxygen_final/web/html/doc/.github/media/ && cp -rf .github/media/ doxygen_final/web/html/doc/.github/
echo 'Copying log...'
cp doxygen.log doxygen_final/doxygen.log
echo 'Copying index.html to root pointing to actual docs'
cp .github/root_index.html doxygen_final/index.html
if: ${{ matrix.DOCS }}
- name: Deploy Docs
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: doxygen_final/
# publish_dir: doxygen/html/ # Original one, it would turn [...].github.io/openpose/web/html/doc/ into [...].github.io/openpose/, but images would not work
destination_dir: .
enable_jekyll: false
force_orphan: true
if: ${{ matrix.DOCS && github.event_name == 'push' && github.ref == 'refs/heads/master' }}