-
Notifications
You must be signed in to change notification settings - Fork 45
159 lines (136 loc) · 5.04 KB
/
all_jobs.yaml
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
name: All Build
on:
workflow_dispatch:
pull_request:
env:
#General variables
numpy_version: "numpy==1.23.4" # replace with only 'numpy' if no version needed
python_versions: 3.8
pybind_version: "2.6.0"
#Windows variables
python_executable: "C:/hostedtoolcache/windows/Python/3.8.10/x64/python.exe" #Cmake needs this to find python on windows
jobs:
job1:
name: Ubuntu 20
runs-on: ubuntu-20.04
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build Docker image
run: docker build -t openeb:ubuntu-20.04 -f .github/workflows/Dockerfile.OpenEB .
- name: Run Docker image
run : docker run -it -v $PWD:/workspace -w /workspace openeb:ubuntu-20.04
- name: Build openEB
run: |
mkdir build && cd build
cmake .. -DBUILD_TESTING=ON
cmake --build . --config Release --parallel 4
- name: Getting datasets from storage
uses: dawidd6/action-download-artifact@v2
with:
workflow: upload_datasets.yaml
workflow_conclusion: success
name: datasets
path: datasets
- name: Run ctest
run: |
cd build
ctest --output-on-failure
job2:
name: Ubuntu 22
runs-on: ubuntu-22.04
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Install dependencies
run: |
sudo apt-get -y update && sudo apt-get install -y sudo apt-utils wget cmake build-essential \
libglew-dev git g++ libusb-1.0-0-dev libgtest-dev libgmock-dev libssl-dev \
python3-pip python3-distutils xvfb libglfw3 libglfw3-dev libglew-dev libopencv-dev ffmpeg \
libboost-dev libboost-program-options-dev libboost-filesystem-dev libboost-timer-dev \
libprotobuf-dev protobuf-compiler \
libboost-chrono-dev libboost-thread-dev zip unzip git-lfs libhdf5-dev hdf5-tools
pip install $numpy_version pytest opencv-python==4.5.5.64 torch==1.13.1 scipy sk-video==1.1.10 numba==0.56.3 h5py protobuf==3.20.3 command_runner kornia==0.6.8 pytorch_lightning==1.8.6 pytorch_msssim==0.2.1
- name: Build pybind and gtest
run: |
openebfolder=${PWD}
cd ..
wget https://github.com/pybind/pybind11/archive/v$pybind_version.zip
unzip v$pybind_version.zip
cd pybind11-$pybind_version/
mkdir build && cd build
cmake .. -DPYBIND11_TEST=OFF
cmake --build . --config Release --parallel 4
sudo make install
- name: Build openEB
run: |
mkdir build && cd build
cmake .. -DBUILD_TESTING=ON
cmake --build . --config Release --parallel 4
- name: Getting datasets from storage
uses: dawidd6/action-download-artifact@v2
with:
workflow: upload_datasets.yaml
workflow_conclusion: success
name: datasets
path: datasets
- name: Run ctest
run: |
cd build
ctest --output-on-failure
job3:
name: Windows
runs-on: windows-2019
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Setup Python
uses: actions/[email protected]
with:
python-version: ${{ env.python_versions }}
- name: Download vcpkg binaries
uses: dawidd6/action-download-artifact@v2
with:
workflow: upload_win_binaries.yaml
workflow_conclusion: success
name: vcpkg_binaries
path: ".."
- name: Download ffmpeg archive
uses: dawidd6/action-download-artifact@v2
with:
workflow: upload_win_binaries.yaml
workflow_conclusion: success
name: ffmpeg_archive
path: ".."
- name: Install build and tests dependencies
shell: bash
run: |
cd ..
unzip -q "vcpkg-export.zip"
7z x ffmpeg-archive.7z
$python_executable -m pip install pytest $numpy_version opencv-python==4.5.5.64 torch==1.13.1 scipy sk-video==1.1.10 numba==0.56.3 h5py command_runner kornia==0.6.8 pytorch_lightning==1.8.6 pytorch_msssim==0.2.1
cd openeb
- name: Build openEB
shell: bash
run: |
export PATH=$PATH:`realpath ../ffmpeg-*-full_build/bin`
mkdir build && cd build
cmake -A x64 -DCMAKE_TOOLCHAIN_FILE="../cmake/toolchains/vcpkg.cmake" \
-DVCPKG_DIRECTORY=`realpath ../../vcpkg` \
-D Python3_EXECUTABLE=$python_executable \
-DBUILD_TESTING=ON ..
cmake --build . --config Release --parallel 4
- name: Getting datasets from storage
uses: dawidd6/action-download-artifact@v2
with:
workflow: upload_datasets.yaml
workflow_conclusion: success
name: datasets
path: datasets
- name: Ctest suite
shell: powershell
run: |
cd build
ctest -C Release --output-on-failure