-
Notifications
You must be signed in to change notification settings - Fork 6
58 lines (57 loc) · 1.91 KB
/
segm.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
name: autobuild_segm
on:
pull_request:
branches:
- master
- dev
push:
branches:
- master
- 'V**'
- dev
env:
GDRIVE_CREDENTIALS_DATA: ${{ secrets.GDRIVE_CREDENTIALS_DATA }}
REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.10
uses: actions/setup-python@v4
with:
python-version: '3.10'
architecture: 'x64'
- uses: actions/setup-node@v3
with:
node-version: '16'
- uses: iterative/setup-cml@v1
- name: Display Python version
run: python -c "import sys; print(sys.version)"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install torch torchvision --extra-index-url https://download.pytorch.org/whl/cpu
pip install -e '.[dev,cv,cv_semantic]'
pip install dvc dvc-gdrive
npm install -g markdown-table-cli
- name: Download data
run: |
echo "$GDRIVE_CREDENTIALS_DATA" > credentials.json
dvc remote modify gdrive --local gdrive_user_credentials_file ./credentials.json
dvc pull
ls -la samples
- name: Test with pytest
run: |
pytest tests/semantic --capture=no
- name: Display report
run: |
echo "# Semantic Report" > report.md
echo "#### Metrics" >> report.md
cat runs/pytest_segm/Validation/metrics.json | md-table >> report.md
echo >> report.md
echo "#### Prediction" >> report.md
echo "![Prediction](runs/pytest_segm/overlays/fc9399fafb30_01.jpg)" >> report.md
echo "![Prediction](runs/pytest_segm/overlays/fcac2903b622_06.jpg)" >> report.md
echo "![Prediction](runs/pytest_segm/overlays/fcac2903b622_11.jpg)" >> report.md
cml comment create report.md