-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c18b1cd
commit 2f47932
Showing
1 changed file
with
45 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
name: Run Benchmarks | ||
|
||
on: | ||
push: | ||
branches: | ||
- feat/run-benchmarks # Trigger the workflow on push to the main branch | ||
|
||
jobs: | ||
benchmark: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Clone tile-benchmarking repository | ||
run: git clone https://github.com/developmentseed/tile-benchmarking.git | ||
|
||
- name: Set working directory to 03-e2e | ||
run: cd tile-benchmarking/03-e2e | ||
|
||
- name: Install requirements | ||
run: pip install -r requirements.txt | ||
|
||
- name: Run locus on files in urls/ directory and store results in results/ | ||
run: | | ||
mkdir -p results | ||
for file in urls/*; do | ||
locus -i 10 --urls-file=$file > --csv=results/$(basename ${file%.*}) | ||
done | ||
working-directory: tile-benchmarking/03-e2e | ||
|
||
- name: Configure AWS credentials | ||
uses: aws-actions/configure-aws-credentials@v2 | ||
with: | ||
role-to-assume: arn:aws:iam::444055461661:role/github-actions-role-eodc | ||
role-session-name: samplerolesession | ||
aws-region: us-west-2 | ||
|
||
- name: Upload results to S3 | ||
run: | | ||
current_time=$(date +"%Y-%m-%d_%H-%M-%S") | ||
aws s3 cp results/ s3://nasa-eodc-data-store/tile-benchmarking-results/latest/ --recursive | ||
aws s3 cp results/ s3://nasa-eodc-data-store/tile-benchmarking-results/$current_time/ --recursive | ||
working-directory: tile-benchmarking/03-e2e |