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

Integrating GPlately for Plate Reconstruction and Feature Extraction #810

Merged
merged 4 commits into from
Jan 26, 2025

Conversation

Minerallo
Copy link
Contributor

@Minerallo Minerallo commented Jan 21, 2025

Hi everyone,

I initially planned to use the GPlates Web Services OpenAPI, as discussed in issue #787. However, I realized that an alternative and potentially more efficient approach would be to leverage GPlately(https://github.com/GPlates/gplately), which already provides a wide range of features such as trenches, ridges, transform faults, continents, cratons, and many more accessible using a python script. GPlately also offers the capability to perform remote plate reconstructions and extract associated geological features seamlessly into geojson format.

Usage instructions for Gplate2gwb.ipynb
The script runs GPlately to import selected geological features based on a specified plate reconstruction model and geological time (Figure 1). Then we generates multiple GeoJSON files, each corresponding to a specific geological feature. Currently, the script supports the extraction of continents and ridges_and_transform_faults, with plans to include additional features such as trenches, passive margins, cratons etc.
I plan to adapt the script so the user can also decide to import its own local plate reconstruction model as it is currently possible using Geojson2json.py for continental plate.

Geojson2json.py is for now really simple and will probably be combine to Gplate2gwb, it converts GeoJSON files to the World Builder-compatible JSON format.
Using the Gplates GUI the users can locally extract features in geojson format (currently it only support continental plate geometry, and make it directly readable by the Geodynamic World Builder.

Usage Instructions for Geojson2json.py
Load a plate reconstruction in GPlates or define your own continental plates.
Export the data to GeoJSON format using the specified parameters (figure 2).
Once the GeoJSON files are generated, run the conversion script using the command:

figure 1
Geplately2gwb

figure 2
image

Copy link

github-actions bot commented Jan 22, 2025

Benchmark Main Feature Difference (99.9% CI)
Slab interpolation simple none 1.114 ± 0.010 (s=393) 1.115 ± 0.009 (s=417) -0.2% .. +0.2%
Slab interpolation curved simple none 1.120 ± 0.010 (s=411) 1.120 ± 0.011 (s=395) -0.2% .. +0.2%
Spherical slab interpolation simple none 1.092 ± 0.007 (s=420) 1.093 ± 0.008 (s=406) -0.1% .. +0.2%
Slab interpolation simple curved CMS 1.159 ± 0.013 (s=394) 1.158 ± 0.011 (s=385) -0.4% .. +0.1%
Spherical slab interpolation simple CMS 1.442 ± 0.012 (s=305) 1.442 ± 0.013 (s=322) -0.2% .. +0.3%
Spherical fault interpolation simple none 1.105 ± 0.008 (s=405) 1.106 ± 0.009 (s=412) -0.1% .. +0.3%
Cartesian min max surface 2.536 ± 0.014 (s=197) 2.538 ± 0.042 (s=160) -0.4% .. +0.6%
Spherical min max surface 7.182 ± 0.067 (s=61) 7.198 ± 0.074 (s=67) -0.4% .. +0.8%

@Minerallo Minerallo changed the title Integrating GPlately for Plate Reconstruction and Feature Extraction [WIP] [WIP] Integrating GPlately for Plate Reconstruction and Feature Extraction Jan 23, 2025
Copy link
Contributor

@gassmoeller gassmoeller left a comment

Choose a reason for hiding this comment

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

incomplete review. i will continue once you are done reorganizing the pr.

@Minerallo Minerallo force-pushed the gwb_gplate branch 2 times, most recently from bb1c0e2 to 140c0f8 Compare January 23, 2025 10:00
Copy link
Contributor

@gassmoeller gassmoeller left a comment

Choose a reason for hiding this comment

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

Looks good already. In addition to my earlier comments here are a few more. And one question: You checked in the gplately2gwb.ipynb including the outputs of the notebook (in particular the figure). Was that on purpose? It makes the notebook larger and less clean in the repository.

@MFraters
Copy link
Member

@Minerallo Is this still WIP? Is this ready to be merged?

@Minerallo
Copy link
Contributor Author

Minerallo commented Jan 25, 2025

@Minerallo Is this still WIP? Is this ready to be merged?

@MFraters, I had made all the changes in the last commit "reply to review" 👍

@MFraters MFraters changed the title [WIP] Integrating GPlately for Plate Reconstruction and Feature Extraction Integrating GPlately for Plate Reconstruction and Feature Extraction Jan 26, 2025
Copy link
Member

@MFraters MFraters left a comment

Choose a reason for hiding this comment

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

Ok, sound good. @gassmoeller thanks for doing the reviewing! I took a look a it and I would say that we get this merged in its current state and build from here.

@Minerallo Can you make a separate issue which contains the checklist with the Ongoing Work section in it? That way we have one place to keep track of this.

@MFraters MFraters merged commit dd7e959 into GeodynamicWorldBuilder:main Jan 26, 2025
37 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants