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: Cache the earth_day_01d_p grid #2937

Merged
merged 3 commits into from
Jan 2, 2024
Merged

CI: Cache the earth_day_01d_p grid #2937

merged 3 commits into from
Jan 2, 2024

Conversation

seisman
Copy link
Member

@seisman seisman commented Jan 1, 2024

Description of proposed changes

The earth_day_01d_p.tif file is used in test_grdimage_image.py.

@seisman
Copy link
Member Author

seisman commented Jan 1, 2024

One quick thought when working on this PR.

Currently, the "Cache Data" workflow is disabled by default for PRs. Sometimes, when we add a new cache file, we need to manually enable the workflow in PRs to refresh the caches and also need to disable it before merging. It's tedious although it doesn't happen very often.

A better solution is:

  1. Move the download_test_data function to a separate source file, e.g., pygmt/helpers/caching.py.
  2. Enable the workflow if pygmt/helpers/caching.py changes:
pull_request:
  paths:
    - 'pygmt/helpers/caching.py'

@seisman seisman added this to the 0.11.0 milestone Jan 1, 2024
@seisman seisman added maintenance Boring but important stuff for the core devs needs review This PR has higher priority and needs review. labels Jan 1, 2024
@seisman seisman removed the needs review This PR has higher priority and needs review. label Jan 2, 2024
@seisman seisman merged commit 29f87b7 into main Jan 2, 2024
14 of 15 checks passed
@seisman seisman deleted the cache/earth_day branch January 2, 2024 00:32
Copy link

codspeed-hq bot commented Jan 2, 2024

CodSpeed Performance Report

Merging #2937 will degrade performances by 6.45%

⚠️ No base runs were found

Falling back to comparing cache/earth_day (2ceb6eb) with main (29f87b7)

Summary

❌ 1 regressions
✅ 63 untouched benchmarks

⚠️ Please fix the performance issues or acknowledge them on CodSpeed.

Benchmarks breakdown

Benchmark main cache/earth_day Change
test_grdlandmask_no_outgrid 2.3 s 2.4 s -6.45%

@seisman
Copy link
Member Author

seisman commented Jan 2, 2024

CodSpeed Performance Report

Merging #2937 will degrade performances by 6.45%

⚠️ No base runs were found

Falling back to comparing cache/earth_day (2ceb6eb) with main (29f87b7)

Summary

❌ 1 regressions ✅ 63 untouched benchmarks

⚠️ Please fix the performance issues or acknowledge them on CodSpeed.

Benchmarks breakdown

Benchmark main cache/earth_day Change
test_grdlandmask_no_outgrid 2.3 s 2.4 s -6.45%

FYI, I've changed the regression threshold back to 10% to silence false warnings like the above:

image

@weiji14
Copy link
Member

weiji14 commented Jan 2, 2024

FYI, I've changed the regression threshold back to 10% to silence false warnings like the above:

Thanks, I've opened an issue (#2942) to track why this benchmark test seems to have so many false warnings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Boring but important stuff for the core devs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants