Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Fix GPU bench regression check #1062

Merged
merged 1 commit into from
Jan 16, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions .github/workflows/gpu-bench-merge-regression.yml
Original file line number Diff line number Diff line change
Expand Up @@ -126,22 +126,22 @@ jobs:
else
REGRESSION_FACTOR=1.1
fi
echo "NOISE_THRESHOLD=$(echo "(REGRESSION_FACTOR-1)*100" | bc) | tee -a $GITHUB_ENV
echo "NOISE_THRESHOLD=$(echo "($REGRESSION_FACTOR-1)*100" | bc)" | tee -a $GITHUB_ENV
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😢


for r in $REGRESSIONS
do
if (( $(echo "$r >= $REGRESSION_FACTOR" | bc -l) ))
then
exit 1
echo "regression=true" | tee -a $GITHUB_OUTPUT
fi
done
continue-on-error: true
# Not possible to use ${{ github.event.number }} with the `merge_group` trigger
- name: Get PR number from merge branch
if: steps.regression-check.outputs.regression == 'true'
run: |
echo "PR_NUMBER=$(echo ${{ github.event.merge_group.head_ref }} | sed -e 's/.*pr-\(.*\)-.*/\1/')" | tee -a $GITHUB_ENV
- uses: JasonEtco/create-an-issue@v2
if: steps.regression-check.outcome == 'failure'
if: steps.regression-check.outputs.regression == 'true'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PR_NUMBER: ${{ env.PR_NUMBER }}
Expand All @@ -151,12 +151,13 @@ jobs:
with:
filename: .github/PERF_REGRESSION.md
- name: Remove old main bench
if: steps.regression-check.outputs.regression != 'true'
run: |
rm fibonacci-${{ env.BASE_COMMIT }}.json
mv fibonacci-${{ github.sha }}.json fibonacci-${{ github.sha }}-${{ env.GPU_ID }}.json
working-directory: ${{ github.workspace }}
- name: Commit bench result to `gh-pages` branch if no regression
if: steps.regression-check.outcome != 'failure'
if: steps.regression-check.outputs.regression != 'true'
uses: stefanzweifel/git-auto-commit-action@v5
with:
branch: gh-pages
Expand Down