diff --git a/Notebooks/06-Rasters.ipynb b/Notebooks/06-Rasters.ipynb index 6be44ecf..10238941 100644 --- a/Notebooks/06-Rasters.ipynb +++ b/Notebooks/06-Rasters.ipynb @@ -376,14 +376,15 @@ "reverse_reconstructed = reconstructed.reconstruct(0, fill_value=\"white\", threads=4)\n", "\n", "# plot\n", - "fig, axs = plt.subplots(3, 1, figsize=(8, 12), subplot_kw={\"projection\": ccrs.Mollweide(central_longitude=0)})\n", - "etopo.imshow(ax=axs[0])\n", - "reconstructed.imshow(ax=axs[1])\n", - "reverse_reconstructed.imshow(ax=axs[2])\n", - "\n", - "axs[0].set_title(\"Original image (present day)\")\n", - "axs[1].set_title(\"Reconstructed to 50 Ma\")\n", - "axs[2].set_title(\"Reverse reconstructed back to present day\")\n", + "fig, axs = plt.subplots(2, 2, figsize=(12, 6), subplot_kw={\"projection\": ccrs.Mollweide(central_longitude=0)})\n", + "etopo.imshow(ax=axs[0][0])\n", + "reconstructed.imshow(ax=axs[0][1])\n", + "reverse_reconstructed.imshow(ax=axs[1][0])\n", + "axs[1][1].set_visible(False)\n", + "\n", + "axs[0][0].set_title(\"Original image (present day)\")\n", + "axs[0][1].set_title(\"Reconstructed to 50 Ma\")\n", + "axs[1][0].set_title(\"Reverse reconstructed back to present day\")\n", "plt.show()" ] }, diff --git a/Notebooks/10-SeafloorGrids.ipynb b/Notebooks/10-SeafloorGrids.ipynb index 64f18aed..208ebb0c 100644 --- a/Notebooks/10-SeafloorGrids.ipynb +++ b/Notebooks/10-SeafloorGrids.ipynb @@ -9,6 +9,10 @@ "\n", "An adaptation of [agegrid-01](https://github.com/siwill22/agegrid-0.1) written by Simon Williams, Nicky Wright and John Cannon for gridding general z-values onto seafloor basin points using GPlately.\n", "\n", + "This notebook demonstrates how to generate seafloor age and spreading-rate grids through time. The figure below, generated by this notebook, shows seafloor age and spreading rates at 200 Ma. You may adjust the time parameter to generate grids at different geological times.\n", + "\n", + "![Figure: age-and-spreading-rate-200ma.png](https://raw.githubusercontent.com/GPlates/gplately/refs/heads/master/Notebooks/NotebookFiles/age-and-spreading-rate-200ma.png)\n", + "\n", "### Citation:\n", "Simon Williams, Nicky M. Wright, John Cannon, Nicolas Flament, R. Dietmar Müller, Reconstructing seafloor age distributions in lost ocean basins, Geoscience Frontiers, Volume 12, Issue 2, 2021, Pages 769-780, ISSN 1674-9871,\n", "https://doi.org/10.1016/j.gsf.2020.06.004." @@ -23,7 +27,6 @@ "source": [ "import gplately\n", "\n", - "import pygplates\n", "import glob, os\n", "import matplotlib.pyplot as plt\n", "import cartopy.crs as ccrs\n", @@ -36,7 +39,7 @@ "metadata": {}, "source": [ "### Define a rotation model, topology features and continents for the `PlateReconstruction` model\n", - "There are two ways to do this. To use local files, pass `use_local_files = True`. To use gplately's `PlateModelManager`, use `use_local_files = False`." + "There are two ways to do this. To use local files, set `use_local_files = True`. To use `PlateModelManager`, set `use_local_files = False`." ] }, { @@ -66,26 +69,30 @@ "source": [ "if use_local_files:\n", " # Method 1: manually point to files\n", - " input_directory = \"/Users/laurenilano/Downloads/SM2-Merdith_et_al_1_Ga_reconstruction_v1.1\"\n", - " rotation_filenames = glob.glob(os.path.join(input_directory, '*.rot'))\n", - " rotation_model = pygplates.RotationModel(rotation_filenames)\n", - "\n", + " # you can download the model files at \n", + " # https://www.earthbyte.org/webdav/ftp/Data_Collections/Merdith_etal_2021_ESR/SM2-Merdith_et_al_1_Ga_reconstruction_v1.2.4.zip\n", + " input_directory = \"./SM2-Merdith_et_al_1_Ga_reconstruction_v1.2.4\"\n", + " \n", + " rotation_model = glob.glob(os.path.join(input_directory, '*.rot'))\n", " static_polygons = input_directory+\"/shapes_static_polygons_Merdith_et_al.gpml\"\n", - "\n", - " topology_filenames = [\n", + " topology_features = [\n", " input_directory+\"/250-0_plate_boundaries_Merdith_et_al.gpml\",\n", " input_directory+\"/410-250_plate_boundaries_Merdith_et_al.gpml\",\n", " input_directory+\"/1000-410-Convergence_Merdith_et_al.gpml\",\n", " input_directory+\"/1000-410-Divergence_Merdith_et_al.gpml\",\n", " input_directory+\"/1000-410-Topologies_Merdith_et_al.gpml\",\n", - " input_directory+\"/1000-410-Transforms_Merdith_et_al.gpml\"\n", + " input_directory+\"/1000-410-Transforms_Merdith_et_al.gpml\",\n", + " input_directory+\"/TopologyBuildingBlocks_Merdith_et_al.gpml\"\n", " ]\n", - " topology_features = pygplates.FeatureCollection()\n", - " for topology_filename in topology_filenames:\n", - " topology_features.add( pygplates.FeatureCollection(topology_filename) )\n", - " \n", + " \n", + " continents = input_directory+\"/shapes_continents.gpml\"\n", + " coastlines = input_directory+\"/shapes_coastlines_Merdith_et_al_v2.gpmlz\"\n", + " COBs = None\n", "\n", - " continents = input_directory+\"/shapes_continents_Merdith_et_al.gpml\"" + " from pathlib import Path\n", + " if not Path(input_directory).is_dir():\n", + " raise FileNotFoundError(f\"The input directory does not exist: {input_directory}. Ensure your files are in the correct locations or download the example input files at https://www.earthbyte.org/webdav/ftp/Data_Collections/Merdith_etal_2021_ESR/SM2-Merdith_et_al_1_Ga_reconstruction_v1.2.4.zip\")\n", + " " ] }, { @@ -93,7 +100,7 @@ "id": "1519da7c", "metadata": {}, "source": [ - "#### 2) Using GPlately's `PlateModelManager`" + "#### 2) Using `PlateModelManager`" ] }, { @@ -104,7 +111,7 @@ "outputs": [], "source": [ "if not use_local_files:\n", - " # Method 2: GPlately's PlateModelManager\n", + " # Method 2: use PlateModelManager\n", " pm_manager = PlateModelManager()\n", " plate_model = pm_manager.get_model(\"Merdith2021\", data_dir=\"plate-model-repo\")\n", " \n", @@ -132,8 +139,7 @@ "* **`PlateReconstruction_object`**: The gplately `PlateReconstruction` object defined in the cell below. This object is a collection of methods for calculating plate tectonic stats through geological time.\n", "* **`PlotTopologies_object`**: The gplately `PlotTopologies` object defined in the cell below. This object is a collection of methods for resolving geological features needed for gridding to a certain geological time.\n", "\n", - "#### Define the `PlateReconstruction` and `PlotTopologies` objects\n", - "...using the outputs of Method 1 OR Method 2." + "#### Define the `PlateReconstruction` and `PlotTopologies` objects" ] }, { @@ -267,6 +273,7 @@ " output_parent_directory,\n", " \"seafloor_grid_output\",\n", ")\n", + "print(f\"The ouput files created by this notebook will be saved in folder {save_directory}.\" )\n", "\n", "# A string to help name files according to a plate model \"Merdith2021\"\n", "file_collection = \"Merdith2021\"\n" @@ -425,7 +432,6 @@ "import datetime\n", "import time\n", "\n", - "\n", "start = time.time()\n", "seafloorgrid.reconstruct_by_topologies()\n", "end = time.time()\n", @@ -499,7 +505,6 @@ "srgrid_unmasked_filename = \"{}/SPREADING_RATE/{}_SPREADING_RATE_grid_unmasked_{:0.2f}Ma.nc\".format(seafloorgrid.save_directory, seafloorgrid.file_collection, time)\n", "unmasked_sr_grid = gplately.grids.Raster(srgrid_unmasked_filename)\n", "\n", - "\n", "# Prepare plots\n", "fig = plt.figure(figsize=(18,10), dpi=300, linewidth=2)\n", "plt.subplots_adjust(wspace=.05, hspace=0) # spacing between subplots \n", @@ -508,14 +513,39 @@ "ax = fig.add_subplot(221, projection=ccrs.Mollweide(central_longitude=20))\n", "gplot.time = time\n", "plt.title(\"{} age grid (myr), {} Ma\".format(seafloorgrid.file_collection, time))\n", + "\n", + "agegrid_cmap = \"YlGnBu\"\n", + "spreading_rate_cmap = \"magma\"\n", + "spreading_rate_cpt_file = \"NotebookFiles/spreading_full_rate.cpt\"\n", + "agegrid_cpt_file = \"NotebookFiles/agegrid.cpt\"\n", + "if not os.path.isfile(agegrid_cpt_file):\n", + " print(f\"The file {agegrid_cpt_file} does not exist locally. It can be found at https://raw.githubusercontent.com/GPlates/gplately/refs/heads/master/Notebooks/NotebookFiles/agegrid.cpt\")\n", + " print(f\"The '{agegrid_cmap}' will be used to plot the age grid.\")\n", + " agegrid_cpt_file = None\n", + "if not os.path.isfile(spreading_rate_cpt_file):\n", + " print(f\"The file {spreading_rate_cpt_file} does not exist locally. It can be found at https://raw.githubusercontent.com/GPlates/gplately/refs/heads/master/Notebooks/NotebookFiles/spreading_full_rate.cpt\")\n", + " print(f\"The '{spreading_rate_cmap}' will be used to plot the spreading rate grid.\")\n", + " spreading_rate_cpt_file = None\n", + "if agegrid_cpt_file or spreading_rate_cpt_file:\n", + " try:\n", + " from gplately.mapping.gmt_cpt import get_cmap_from_gmt_cpt\n", + " if agegrid_cpt_file:\n", + " agegrid_cmap=get_cmap_from_gmt_cpt(agegrid_cpt_file)\n", + " if spreading_rate_cpt_file:\n", + " spreading_rate_cmap=get_cmap_from_gmt_cpt(spreading_rate_cpt_file)\n", + " except ImportError as e:\n", + " print(\"To use GMT cpt file, ensure you are using GPlately version 2.1 or higher.\")\n", + " print(e)\n", + "\n", "im = gplot.plot_grid(\n", " ax, \n", " age_grid.data, \n", - " cmap=\"YlGnBu\",\n", + " cmap = agegrid_cmap,\n", " vmin = 0, \n", " vmax =410,\n", ")\n", "gplot.plot_ridges(ax)\n", + "gplot.plot_continents(ax, edgecolor=\"grey\", facecolor=\"lightgrey\", linewidth=0.5)\n", "plt.colorbar(im, label=\"Age (Ma)\", shrink=0.5, pad=0.05)\n", "\n", "# Unmasked agegrid\n", @@ -525,14 +555,13 @@ "im = gplot.plot_grid(\n", " ax, \n", " unmasked_age_grid.data, \n", - " cmap=\"YlGnBu\",\n", + " cmap=agegrid_cmap,\n", " vmin = 0, \n", " vmax =410,\n", ")\n", "gplot.plot_ridges(ax)\n", "plt.colorbar(im, label=\"Age (Ma)\", shrink=0.5, pad=0.05)\n", "\n", - "\n", "# Masked spreading rate grid\n", "ax1 = fig.add_subplot(223, projection=ccrs.Mollweide(central_longitude=20))\n", "gplot.time = time\n", @@ -540,10 +569,11 @@ "im1 = gplot.plot_grid(\n", " ax1, \n", " sr_grid.data, \n", - " cmap=\"magma\",\n", + " cmap=spreading_rate_cmap,\n", " alpha=0.7,\n", ")\n", "gplot.plot_ridges(ax1)\n", + "gplot.plot_continents(ax1, edgecolor=\"grey\", facecolor=\"lightgrey\", linewidth=0.5)\n", "plt.colorbar(im1, label=\"Spreading rate (mm/yr)\", shrink=0.5, pad=0.05)\n", "\n", "# Unmasked spreading rate grid\n", @@ -553,7 +583,7 @@ "im1 = gplot.plot_grid(\n", " ax1, \n", " unmasked_sr_grid.data, \n", - " cmap=\"magma\",\n", + " cmap=spreading_rate_cmap,\n", " alpha=0.7,\n", ")\n", "gplot.plot_ridges(ax1)\n", diff --git a/Notebooks/NotebookFiles/age-and-spreading-rate-200ma.png b/Notebooks/NotebookFiles/age-and-spreading-rate-200ma.png new file mode 100644 index 00000000..543eee6f Binary files /dev/null and b/Notebooks/NotebookFiles/age-and-spreading-rate-200ma.png differ diff --git a/Notebooks/NotebookFiles/age-grid-200ma.png b/Notebooks/NotebookFiles/age-grid-200ma.png new file mode 100644 index 00000000..f7dd1fca Binary files /dev/null and b/Notebooks/NotebookFiles/age-grid-200ma.png differ diff --git a/Notebooks/NotebookFiles/agegrid.cpt b/Notebooks/NotebookFiles/agegrid.cpt new file mode 100644 index 00000000..f05a48ca --- /dev/null +++ b/Notebooks/NotebookFiles/agegrid.cpt @@ -0,0 +1,39 @@ +0 135/42/43 5 135/42/43 +5 164/38/44 10 164/38/44 +10 194/35/45 15 194/35/45 +15 219/30/38 20 219/30/38 +20 241/71/28 25 241/71/28 +25 245/107/29 30 245/107/29 +30 245/134/28 35 245/134/28 +35 250/147/21 40 250/147/21 +40 248/157/14 45 248/157/14 +45 250/179/12 50 250/179/12 +50 252/199/7 55 252/199/7 +55 254/215/23 60 254/215/23 +60 254/222/39 65 254/222/39 +65 245/227/35 70 245/227/35 +70 243/240/29 75 243/240/29 +75 233/240/53 80 233/240/53 +80 220/240/67 85 220/240/67 +85 204/230/75 90 204/230/75 +90 162/224/157 95 162/224/157 +95 153/219/184 100 153/219/184 +100 123/212/195 105 123/212/195 +105 102/204/206 110 102/204/206 +110 72/198/208 115 72/198/208 +115 51/188/207 120 51/188/207 +120 38/188/224 125 38/188/224 +125 25/181/241 130 25/181/241 +130 4/161/230 135 4/161/230 +135 11/142/216 140 11/142/216 +140 23/111/193 145 23/111/193 +145 30/92/179 150 30/92/179 +150 29/63/163 155 29/63/163 +155 27/41/153 160 27/41/153 +160 35/24/144 165 35/24/144 +165 53/19/143 170 53/19/143 +170 65/0/135 200 65/0/135 +200 92/0/125 350 92/0/125 +B white +F black +N 128 diff --git a/Notebooks/NotebookFiles/spreading-rate-200m.png b/Notebooks/NotebookFiles/spreading-rate-200m.png new file mode 100644 index 00000000..6b38dbc4 Binary files /dev/null and b/Notebooks/NotebookFiles/spreading-rate-200m.png differ diff --git a/Notebooks/NotebookFiles/spreading_full_rate.cpt b/Notebooks/NotebookFiles/spreading_full_rate.cpt new file mode 100644 index 00000000..2039b874 --- /dev/null +++ b/Notebooks/NotebookFiles/spreading_full_rate.cpt @@ -0,0 +1,23 @@ +0 255 0 255 10 255 0 255 +10 234 0 255 20 234 0 255 +20 142 0 255 30 142 0 255 +30 35 0 255 40 35 0 255 +40 0 85 255 50 0 85 255 +50 0 216 255 60 0 216 255 +60 0 255 168 70 0 255 168 +70 0 255 32 80 0 255 32 +80 73 255 0 90 73 255 0 +90 149 255 0 100 149 255 0 +100 195 255 0 110 195 255 0 +110 228 255 0 120 228 255 0 +120 255 247 0 130 255 247 0 +130 255 213 0 140 255 213 0 +140 255 183 0 150 255 183 0 +150 255 146 0 160 255 146 0 +160 255 120 0 170 255 120 0 +170 255 100 0 180 255 100 0 +180 255 85 0 190 255 85 0 +190 255 73 0 200 255 73 0 +B 255 0 255 +F 255 73 0 +N 125 125 125 diff --git a/README.md b/README.md index 6d66ac5b..30cb911d 100644 --- a/README.md +++ b/README.md @@ -42,6 +42,19 @@ eprint = {https://rmets.onlinelibrary.wiley.com/doi/pdf/10.1002/gdj3.185}, } ``` +## Common Use Cases + +- Generating Seafloor Age and Spreading Rate Grids Through Time + ![Figure: age-and-spreading-rate-200ma.png](https://raw.githubusercontent.com/GPlates/gplately/375-update-main-readme-and-seafloorgridsipynb/Notebooks/NotebookFiles/age-and-spreading-rate-200ma.png) +- Plotting Paleomaps with Cartopy + ![Figure: plottopologies.png](https://gplates.github.io/gplately/latest/sphinx/html/_images/plottopologies.png) +- Rasters Reconstruction + ![Figure: etopo_reconstruction.png](https://gplates.github.io/gplately/latest/sphinx/html/_images/etopo_reconstruction.png) +- Locations Reconstruction + ![Figure: Reconstructed-Jurassic-Foraminifera-locations-min.png](https://gplates.github.io/gplately/latest/sphinx/html/_images/Reconstructed-Jurassic-Foraminifera-locations-min.png) +- Calculating Motion Path + ![Figure: Hawaii_Emperor_motion_path.png](https://gplates.github.io/gplately/latest/sphinx/html/_images/Hawaii_Emperor_motion_path.png) + ## Documentation - [latest stable](https://gplates.github.io/gplately/stable/sphinx/html/index.html) diff --git a/gplately/mapping/cartopy_plot.py b/gplately/mapping/cartopy_plot.py index dcccfdea..ebadc23d 100644 --- a/gplately/mapping/cartopy_plot.py +++ b/gplately/mapping/cartopy_plot.py @@ -1,5 +1,5 @@ # -# Copyright (C) 2024-2025 The University of Sydney, Australia +# Copyright (C) 2024-2026 The University of Sydney, Australia # # This program is free software; you can redistribute it and/or modify it under # the terms of the GNU General Public License, version 2, as published by diff --git a/gplately/mapping/gmt_cpt.py b/gplately/mapping/gmt_cpt.py new file mode 100644 index 00000000..cfc53473 --- /dev/null +++ b/gplately/mapping/gmt_cpt.py @@ -0,0 +1,144 @@ +# +# Copyright (C) 2024-2026 The University of Sydney, Australia +# +# This program is free software; you can redistribute it and/or modify it under +# the terms of the GNU General Public License, version 2, as published by +# the Free Software Foundation. +# +# This program is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# for more details. +# +# You should have received a copy of the GNU General Public License along +# with this program; if not, write to Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# +from matplotlib.colors import LinearSegmentedColormap, hsv_to_rgb + + +def _parse_old_cpt_row(row, color_model="RGB"): + """parse one row of text from a cpt file in old format, such as the four rows below from a cpt file + + 0 210 0 0 10 210 0 0 + 10 230 40 0 20 230 40 0 + 20 245 60 0 30 245 60 0 + 30 255 98 0 40 255 98 0 + + Parameters + ---------- + row : a list of strings + A list of strings representing a line from a cpt file in old format, + such as ["0", "210", "0", "0", "10", "210", "0", "0"]. + color_model : str, optional + The color model to use, either "RGB" or "HSV". Default is "RGB". + + Returns + ------- + tuple of list of float and list of list of float + A tuple containing the values and colors(RGB values in a closed interval [0, 1]) parsed from the row. + """ + + values = [] + colors = [] + values.append(float(row[0])) + values.append(float(row[4])) + if color_model == "RGB": + colors.append( + [ + float(row[1]) / 255.0, + float(row[2]) / 255.0, + float(row[3]) / 255.0, + ] + ) + colors.append( + [ + float(row[5]) / 255.0, + float(row[6]) / 255.0, + float(row[7]) / 255.0, + ] + ) + else: + colors.append( + list(hsv_to_rgb([float(row[1]) / 360.0, float(row[2]), float(row[3])])) + ) + colors.append( + list(hsv_to_rgb([float(row[5]) / 360.0, float(row[6]), float(row[7])])) + ) + return values, colors + + +def _parse_new_cpt_row(row, color_model="RGB"): + """parse one row of text from a cpt file in new format, such as the four rows below from a cpt file + + 0 64/0/64 0.052632 64/0/192 L + 0.052632 64/0/192 0.105263 0/64/255 L + 0.105263 0/64/255 0.157895 0/128/255 L + 0.157895 0/128/255 0.210526 0/160/255 L + + Parameters + ---------- + row : a list of strings + A list of strings representing a line from a cpt file in new format, + such as ["0", "64/0/64", "0.052632", "64/0/192", "L"]. + color_model : str, optional + The color model to use, either "RGB" or "HSV". Default is "RGB + + Returns + ------- + tuple of list of float and list of list of float + A tuple containing the values and colors(RGB values in a closed interval [0, 1]) parsed from the row. + """ + # convert the new format into old format + color_1 = row[1].split("/") + color_2 = row[3].split("/") + return _parse_old_cpt_row( + [row[0]] + color_1 + [row[2]] + color_2, color_model=color_model + ) + + +def get_cmap_from_gmt_cpt(cpt_file): + """given a gmt cpt file path, return a `matplotlib.colors.LinearSegmentedColormap` object. + + Parameters + ---------- + cpt_file : str + The path to the gmt cpt file. + + Returns + ------- + matplotlib.colors.LinearSegmentedColormap + A matplotlib colormap object. + """ + values = [] + colors = [] + color_model = "RGB" + with open(cpt_file, "r") as f: + for line in f: + line = line.strip() + if not line: + continue + if "COLOR_MODEL" in line and "HSV" in line: + color_model = "HSV" + if line[0] in ["#", "B", "F", "N"]: + continue + vals = line.split() + if len(vals) == 8: + vs, cs = _parse_old_cpt_row(vals, color_model=color_model) + values.extend(vs) + colors.extend(cs) + elif len(vals) == 5 or len(vals) == 4: + vs, cs = _parse_new_cpt_row(vals, color_model=color_model) + values.extend(vs) + colors.extend(cs) + + if values is None or colors is None: + raise ValueError(f"No valid colour data found in cpt file: {cpt_file}") + + colour_list = [] + for i in range(len(values)): + colour_list.append( + ((values[i] - values[0]) / (values[-1] - values[0]), [x for x in colors[i]]) + ) + + return LinearSegmentedColormap.from_list("gmt-cpt-cmap", colour_list) diff --git a/gplately/mapping/plot_engine.py b/gplately/mapping/plot_engine.py index e21964b5..2e0d6536 100644 --- a/gplately/mapping/plot_engine.py +++ b/gplately/mapping/plot_engine.py @@ -1,5 +1,5 @@ # -# Copyright (C) 2024-2025 The University of Sydney, Australia +# Copyright (C) 2024-2026 The University of Sydney, Australia # # This program is free software; you can redistribute it and/or modify it under # the terms of the GNU General Public License, version 2, as published by diff --git a/gplately/mapping/pygmt_plot.py b/gplately/mapping/pygmt_plot.py index 5cdbc613..694b7f51 100644 --- a/gplately/mapping/pygmt_plot.py +++ b/gplately/mapping/pygmt_plot.py @@ -1,5 +1,5 @@ # -# Copyright (C) 2024-2025 The University of Sydney, Australia +# Copyright (C) 2024-2026 The University of Sydney, Australia # # This program is free software; you can redistribute it and/or modify it under # the terms of the GNU General Public License, version 2, as published by diff --git a/sphinx-doc/source/images/Hawaii_Emperor_motion_path.png b/sphinx-doc/source/images/Hawaii_Emperor_motion_path.png index 6bd05dbf..68905fdf 100644 Binary files a/sphinx-doc/source/images/Hawaii_Emperor_motion_path.png and b/sphinx-doc/source/images/Hawaii_Emperor_motion_path.png differ diff --git a/sphinx-doc/source/images/etopo_reconstruction.png b/sphinx-doc/source/images/etopo_reconstruction.png index 79e409c8..a0b497ef 100644 Binary files a/sphinx-doc/source/images/etopo_reconstruction.png and b/sphinx-doc/source/images/etopo_reconstruction.png differ diff --git a/sphinx-doc/source/images/plottopologies.png b/sphinx-doc/source/images/plottopologies.png index 371026cd..4275a7cb 100644 Binary files a/sphinx-doc/source/images/plottopologies.png and b/sphinx-doc/source/images/plottopologies.png differ diff --git a/sphinx-doc/source/use_cases.rst b/sphinx-doc/source/use_cases.rst index 74054f4d..f005bd86 100644 --- a/sphinx-doc/source/use_cases.rst +++ b/sphinx-doc/source/use_cases.rst @@ -80,10 +80,10 @@ Alternatively, you may use the auxiliary functions to create a :py:class:`gplate The `PlateReconstructions example`_ demonstrates in detail how to use the :py:class:`gplately.PlateReconstruction` class. -The `02-PlateReconstructions.ipynb`_ Jupyter Notebook is available in the GitHub GPlately repository. +The latest `02-PlateReconstructions.ipynb`_ Jupyter Notebook is available in the GitHub GPlately repository. .. _`02-PlateReconstructions.ipynb`: https://github.com/GPlates/gplately/blob/master/Notebooks/02-PlateReconstructions.ipynb -.. _`PlateReconstructions example`: https://gplates.github.io/gplately/stable/02-PlateReconstructions.html +.. _`PlateReconstructions example`: ../../notebook-html/02-PlateReconstructions.html Points ------ @@ -113,9 +113,9 @@ through geologic time. This motion can be visualised using flowlines or motion p The `WorkingWithPoints example`_ demonstrates in detail how to use the Points class. -The `03-WorkingWithPoints.ipynb`_ Jupyter Notebook is available in the GitHub GPlately repository. +The latest `03-WorkingWithPoints.ipynb`_ Jupyter Notebook is available in the GitHub GPlately repository. -.. _`WorkingWithPoints example`: https://gplates.github.io/gplately/stable/03-WorkingWithPoints.html +.. _`WorkingWithPoints example`: ../../notebook-html/03-WorkingWithPoints.html .. _`03-WorkingWithPoints.ipynb`: https://github.com/GPlates/gplately/blob/master/Notebooks/03-WorkingWithPoints.ipynb .. image:: images/Reconstructed-Jurassic-Foraminifera-locations-min.png @@ -123,9 +123,9 @@ The `03-WorkingWithPoints.ipynb`_ Jupyter Notebook is available in the GitHub GP :alt: PointsDemo The `CreatingMotionPathsAndFlowlines example`_ demonstrates how to create motion paths and flowlines. -The `09-CreatingMotionPathsAndFlowlines.ipynb`_ Jupyter Notebook is available in the GitHub GPlately repository. +The latest `09-CreatingMotionPathsAndFlowlines.ipynb`_ Jupyter Notebook is available in the GitHub GPlately repository. -.. _`CreatingMotionPathsAndFlowlines example`: +.. _`CreatingMotionPathsAndFlowlines example`: ../../notebook-html/09-CreatingMotionPathsAndFlowlines.html .. _`09-CreatingMotionPathsAndFlowlines.ipynb`: https://github.com/GPlates/gplately/blob/master/Notebooks/09-CreatingMotionPathsAndFlowlines.ipynb .. image:: images/Hawaii_Emperor_motion_path.png @@ -167,10 +167,10 @@ interpolated onto Raster grids. The `Rasters example`_ demonstrates in detail how to use the :py:class:`gplately.Raster` class. -The `06-Rasters.ipynb`_ Jupyter Notebook is available in the GitHub GPlately repository. +The latest `06-Rasters.ipynb`_ Jupyter Notebook is available in the GitHub GPlately repository. .. _`06-Rasters.ipynb`: https://github.com/GPlates/gplately/blob/master/Notebooks/06-Rasters.ipynb -.. _`Rasters example`: https://gplates.github.io/gplately/stable/06-Rasters.html +.. _`Rasters example`: ../../notebook-html/06-Rasters.html .. image:: images/etopo_reconstruction.png :width: 600 @@ -251,9 +251,9 @@ as encoded by a plate reconstruction model. The `SeafloorGrids example`_ is a tutorial notebook that demonstrates how to set up and use the :py:class:`gplately.SeafloorGrid` object, and shows a sample set of output grids. -The `10-SeafloorGrids.ipynb`_ Jupyter Notebook is available in the GitHub GPlately repository. +The latest `10-SeafloorGrids.ipynb`_ Jupyter Notebook is available in the GitHub GPlately repository. -.. _`SeafloorGrids example`: https://gplates.github.io/gplately/dev-doc/10-SeafloorGrids.html +.. _`SeafloorGrids example`: ../../notebook-html//10-SeafloorGrids.html .. _`10-SeafloorGrids.ipynb`: https://github.com/GPlates/gplately/blob/master/Notebooks/10-SeafloorGrids.ipynb .. image:: images/seafloorgrid.gif