Skip to content
GitLab
  • Menu
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • S shakyground2
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 10
    • Issues 10
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Shakemap
  • shakyground2
  • Merge requests
  • !22

(Potentially) Fixes bug of shakemaps not working across antimeridian

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Graeme Weatherill requested to merge gweather/shakyground2:bug/dateline_error into master May 27, 2021
  • Overview 12
  • Commits 8
  • Pipelines 5
  • Changes 7

Addresses #18 (closed)

when the bounding box of the shakemap region crossed the antimeridian (not the "international date line" - I have been corrected on that terminology!) the shakemap could not be built. There were several steps in the calculation that prevented it, but it ultimately originates from the ulon of the bounding box being lower than the llon and thus no valid site model was built. This MR makes the necessary fixes in the shakemap code to ensure that the ground motion values are calculated at the sites correctly when the earthquake is near the antimeridian.

In the second modification, the generation of the raster and contours has been modified. For the contours these are re-centred such that longitudes in the western hemisphere (-180˚E to 0˚E) are shifted to an antimeridian centred system (i.e. 180˚E to 360˚E). Thus the contour can now contain longitudes greater than 180˚E. For the raster we use rasterio's reproject functionality to transform the raster passing the CENTER LONG = 180 keyword to the GDAL backend. This does not raise an error and seems to export complete rasters.

Here is an example of the shakemap in QGIS:

Screen_Shot_2021-05-27_at_16.58.53

@nils @eggi Honestly, I have no idea whether this has worked or not. The results seem OK in QGIS when I set the basemap projection to EPSG:4326, but if I switch to another project (e.g. EPSG:3857) then it only shows me the portion of the raster in the eastern hemisphere. This could be just a QGIS issue, though, and it might be fine on the Earthquake Explorer server. I will keep issue #18 (closed) open after merging this MR until there is confirmation that this either i) works directly or ii) can be integrated into the pipeline.

An antimeridian crossing workflow has also been added to the workflow test cases.

Assignee
Assign to
Reviewer
Request review from
Time tracking
Source branch: bug/dateline_error