-
Notifications
You must be signed in to change notification settings - Fork 0
92 lines (75 loc) · 2.36 KB
/
regressiontests.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
name: Regression tests
on:
pull_request:
branches: ['develop']
jobs:
compute_seg_masks:
name: Compute results
runs-on: self-hosted
defaults:
run:
shell: bash -el {0}
steps:
- name: Checkout
uses: actions/checkout@v2
# - uses: actions/setup-python@v4
# with:
# python-version: '3.8.5'
#
# - name: Install dependencies
# run: pip install -r requirements.txt
- name: Setup Miniconda
uses: conda-incubator/setup-miniconda@v2
with:
miniconda-version: 'latest'
channels: conda-forge, bioconda
use-only-tar-bz2: true # IMPORTANT: This needs to be set for caching to work properly!
auto-update-conda: true
auto-activate-base: false
activate-environment: superdsm
environment-file: superdsm.yml
- name: Download image data
run: |
conda info
python --version
cd examples
python load_data.py
- name: Run SuperDSM
run: python -m "superdsm.batch" examples --task-dir "U2OS" --task-dir "NIH3T3" --task-dir "BBBC039" --task-dir "GOWT1-1" --task-dir "GOWT1-2" --run
- name: Aggregate results
run: |
rm -rf examples/fibroblast
for taskdir in $(cd examples && find . -name 'seg')
do
mkdir -p "results/$taskdir"
mv examples/$taskdir/*.png "results/$taskdir/"
done
- name: Upload results artifact
uses: actions/upload-artifact@v3
with:
name: seg_masks
path: results
validate_results:
name: Validate results
runs-on: ubuntu-latest
needs: ['compute_seg_masks']
strategy:
matrix:
taskdir:
- U2OS/default
- U2OS/default/adapted
- U2OS/default/adapted/isbi24
steps:
- name: Checkout
uses: actions/checkout@v2
- uses: actions/setup-python@v5
with:
python-version: '3.8.5'
- name: Install dependencies
run: pip install -r tests/regression/requirements.txt
- name: Download results artifact
uses: actions/download-artifact@v3
- name: Run tests
run: |
mkdir actual_csv
python tests/regression/test.py results/${{ matrix.taskdir }}/seg actual_csv tests/regression/expected/${{ matrix.taskdir }}