forked from modelbox-ai/modelbox
-
Notifications
You must be signed in to change notification settings - Fork 0
176 lines (169 loc) · 5.63 KB
/
modelbox-images-unittest.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
name: Modelbox images unittest
on:
workflow_run:
workflows: ['Publish modelbox images']
types:
- completed
defaults:
run:
shell: bash
jobs:
unittest_cuda112_trt:
runs-on: ubuntu-latest
container: zxk114/modelbox-develop-tensorrt_8.4.2-cuda_11.2-${{matrix.osName}}-x86_64:latest
strategy:
matrix:
osName: [ubuntu, openeuler]
steps:
- name: Checkout
uses: actions/checkout@main
- name: CMake
run: |
mkdir build
cd build
ldconfig
cmake .. -DCMAKE_BUILD_TYPE=Release -DWITH_ALL_DEMO=on -DWITH_WEBUI=on
- name: Test
working-directory: build
run: |
if [ "${{matrix.osName}}" == "ubuntu" ];then
dpkg -r $(dpkg -l|grep modelbox|awk '{print $2}') || true
elif [ "${{matrix.osName}}" == "openeuler" ];then
rpm -e $(rpm -qa|grep modelbox) || true
fi
make build-test -j8
make unittest
unittest_cuda112_tf:
runs-on: ubuntu-latest
container: zxk114/modelbox-develop-tensorflow_2.6.0-cuda_11.2-${{matrix.osName}}-x86_64:latest
strategy:
matrix:
osName: [ubuntu, openeuler]
steps:
- name: Checkout
uses: actions/checkout@main
- name: CMake
run: |
mkdir build
cd build
ldconfig
cmake .. -DCMAKE_BUILD_TYPE=Release -DWITH_ALL_DEMO=on -DWITH_WEBUI=on
- name: Test
working-directory: build
run: |
if [ "${{matrix.osName}}" == "ubuntu" ];then
dpkg -r $(dpkg -l|grep modelbox|awk '{print $2}') || true
elif [ "${{matrix.osName}}" == "openeuler" ];then
rpm -e $(rpm -qa|grep modelbox) || true
fi
make build-test -j8
make unittest
unittest_cuda102_trt:
runs-on: ubuntu-latest
container: zxk114/modelbox-develop-tensorrt_7.1.3-cuda_10.2-${{matrix.osName}}-x86_64:latest
strategy:
matrix:
osName: [ubuntu, openeuler]
steps:
- name: Checkout
uses: actions/checkout@main
- name: CMake
run: |
mkdir build
cd build
ldconfig
cmake .. -DCMAKE_BUILD_TYPE=Release -DWITH_ALL_DEMO=on -DWITH_WEBUI=on
- name: Test
working-directory: build
run: |
if [ "${{matrix.osName}}" == "ubuntu" ];then
dpkg -r $(dpkg -l|grep modelbox|awk '{print $2}') || true
elif [ "${{matrix.osName}}" == "openeuler" ];then
rpm -e $(rpm -qa|grep modelbox) || true
fi
make build-test -j8
make unittest
unittest_cuda102_torch:
runs-on: ubuntu-latest
container:
image: zxk114/modelbox-develop-libtorch_1.9.1-cuda_10.2-${{matrix.osName}}-x86_64:latest
strategy:
matrix:
osName: [ubuntu, openeuler]
steps:
- name: Checkout
uses: actions/checkout@main
- name: CMake
run: |
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DWITH_ALL_DEMO=on -DWITH_WEBUI=on
- name: Test
working-directory: build
run: |
if [ "${{matrix.osName}}" == "ubuntu" ];then
dpkg -r $(dpkg -l|grep modelbox|awk '{print $2}') || true
elif [ "${{matrix.osName}}" == "openeuler" ];then
rpm -e $(rpm -qa|grep modelbox) || true
fi
make build-test -j8
make unittest
unittest_x86d:
runs-on: ubuntu-latest
container:
image: zxk114/modelbox-develop-mindspore_1.9.0-cann_6.0.1-d${{matrix.dtype}}-${{matrix.osName}}-x86_64:latest
strategy:
matrix:
osName: [ubuntu, openeuler]
dtype: [310, 310p]
steps:
- name: Checkout
uses: actions/checkout@main
- name: CMake
run: |
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DWITH_ALL_DEMO=on -DWITH_WEBUI=on
- name: Test
working-directory: build
run: |
if [ "${{matrix.osName}}" == "ubuntu" ];then
dpkg -r $(dpkg -l|grep modelbox|awk '{print $2}') || true
elif [ "${{matrix.osName}}" == "openeuler" ];then
rpm -e $(rpm -qa|grep modelbox) || true
fi
make build-test -j8
make unittest
unittest_armd:
runs-on: ${{matrix.osName}}-d310
strategy:
matrix:
osName: [ubuntu, openeuler]
steps:
- name: Checkout
uses: actions/checkout@main
- name: CMake
run: |
sed -i 's@https://gitee.com/modelbox/modelbox-binary/attach_files/1010735/download@http://192.168.59.29@g' thirdparty/CMake/pre-download.in
mkdir build
cd build
ldconfig
export $(cat /proc/1/environ|tr "\\0" "\\n"|xargs)
if [ "${{matrix.osName}}" == "ubuntu" ];then
export LD_LIBRARY_PATH=/usr/lib:/usr/local/lib${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}
elif [ "${{matrix.osName}}" == "openeuler" ];then
export LD_LIBRARY_PATH=/usr/lib64:/usr/local/lib64${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}
fi
cmake .. -DCMAKE_BUILD_TYPE=Release -DWITH_ALL_DEMO=on -DWITH_WEBUI=on -DUSE_CN_MIRROR=yes
- name: Test
working-directory: build
run: |
if [ "${{matrix.osName}}" == "ubuntu" ];then
dpkg -r $(dpkg -l|grep modelbox|awk '{print $2}') || true
export LD_PRELOAD=/usr/lib/aarch64-linux-gnu/libgomp.so.1
elif [ "${{matrix.osName}}" == "openeuler" ];then
rpm -e $(rpm -qa|grep modelbox) || true
export LD_PRELOAD=/usr/lib64/libgomp.so.1
fi
make build-test -j8
make unittest