-
Notifications
You must be signed in to change notification settings - Fork 1
57 lines (49 loc) · 1.73 KB
/
qe_speaker-mapping-accuracy.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
name: "Riksdagen Records: Speaker Mapping Accuracy Estimate"
on:
pull_request:
branches:
- 'dev'
paths:
- data/
jobs:
Estimate-speaker-accuracy:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.8]
steps:
- name: Checkout PR source branch
uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pyriksdagen
pip install scipy
- name: Estimate Mapping Accuracy
run: |
python quality/qe_speaker-mapping-accuracy.py
- name: Add and commit changes
run: |
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
if [[ `git status quality/estimates/speaker-mapping-accuracy/ --porcelain --untracked-files=no` ]]; then
git add quality/estimates/speaker-mapping-accuracy/
git commit -m "chore (workflow): update speaker mapping accuracy estimate"
else
echo ""
echo "::warning:: WARNING!!! No changes to speaker mapping accuracy estimate."
echo " Double check the version nr and everything else is up to date."
echo ""
git commit --allow-empty -m "chore (workflow): no changes to speaker mapping accuracy estimate"
fi
- name: Push changes
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.head_ref }}