Skip to content

Commit

Permalink
Save benchmark config filename as GH output
Browse files Browse the repository at this point in the history
  • Loading branch information
huydhn committed Dec 30, 2024
1 parent 9b5876c commit 9667850
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/android-perf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ jobs:
- uses: actions/checkout@v3

- name: Prepare the spec
id: prepare
shell: bash
env:
BENCHMARK_CONFIG: ${{ toJSON(matrix) }}
Expand All @@ -123,6 +124,7 @@ jobs:
BENCHMARK_CONFIG_FILENAME=$(echo "${BENCHMARK_CONFIG_ID}" | sed -e 's/[^A-Za-z0-9._-]/_/g')
# Save the benchmark configs so that we can use it later in the dashboard
echo "${BENCHMARK_CONFIG}" > "${BENCHMARK_CONFIG_FILENAME}.json"
echo "benchmark-config-filename=${BENCHMARK_CONFIG_FILENAME}" >> $GITHUB_OUTPUT
- name: Upload the spec
uses: seemethere/upload-artifact-s3@v5
Expand All @@ -142,7 +144,7 @@ jobs:
${{ github.repository }}/${{ github.run_id }}/artifacts/benchmark-configs/
retention-days: 1
if-no-files-found: error
path: extension/benchmark/android/benchmark/${{ matrix.model }}_${{ matrix.config }}.json
path: extension/benchmark/android/benchmark/${{ steps.prepare.outputs.benchmark-config-filename }}.json

export-models:
name: export-models
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/apple-perf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@ jobs:
BENCHMARK_CONFIG_FILENAME=$(echo "${BENCHMARK_CONFIG_ID}" | sed -e 's/[^A-Za-z0-9._-]/_/g')
# Save the benchmark configs so that we can use it later in the dashboard
echo "${BENCHMARK_CONFIG}" > "${BENCHMARK_CONFIG_FILENAME}.json"
echo "benchmark-config-filename=${BENCHMARK_CONFIG_FILENAME}" >> $GITHUB_OUTPUT
- name: Upload the spec
uses: seemethere/upload-artifact-s3@v5
Expand All @@ -144,7 +145,7 @@ jobs:
${{ github.repository }}/${{ github.run_id }}/artifacts/benchmark-configs/
retention-days: 1
if-no-files-found: error
path: extension/benchmark/apple/Benchmark/${{ matrix.model }}_${{ matrix.config }}.json
path: extension/benchmark/apple/Benchmark/${{ steps.prepare.outputs.benchmark-config-filename }}.json

export-models:
name: export-models
Expand Down

0 comments on commit 9667850

Please sign in to comment.