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

ETOPO1: Distinguishing between negative elevation and bathymetry #105

Open
j0nes2k opened this issue Feb 3, 2025 · 1 comment
Open

ETOPO1: Distinguishing between negative elevation and bathymetry #105

j0nes2k opened this issue Feb 3, 2025 · 1 comment

Comments

@j0nes2k
Copy link

j0nes2k commented Feb 3, 2025

I am trying to get elevation information at this point:
https://api.opentopodata.org/v1/etopo1?locations=38.6920,2.7012

When using srtm30m, I get null values. Therefore I was looking at replacement models and came across ETOPO1. When using this dataset as per the URL above, I get an output of -1926.0. This makes sense, as this model should include both bathymetry as well as elevation.

But: how can I distinguish between those two? There are places on earth with negative elevation, and bathymetry by definition is always negative.

@ajnisbet
Copy link
Owner

ajnisbet commented Feb 3, 2025

Good question!

Yes, for a model that includes bathymetry, you can't be sure if negative values are land or ocean. As well as the elevation data, you need a second channel that is a water/land mask, and I'm not aware of any open global datasets that include both bathymetry and water mask.

You can use a second dataset to be the water mask. For example the Copernicus DEM comes with a raster water body mask (WBM) dataset that can be added to a self-hosted opentopodata instance. Then you could query both etopo1 for the elevation and Copernicus DEM WBM for the land/bathy data. Or you could use a coastline vector to classify land points.

The downside with mixing datasets (especially with differing resolutions) is that they may differ in their classification of the same point. For example, with the 30m resolution Copermicus water mask or the 10m resolution coastline vector, a point 500m offshore will reliably be classified as bathymetry. But due to etopo1's 1km resolution, that same point may have a positive elevation still! You may want to use some approximation like: if a point is classified as bathymetry, but has a positive ETOPO1 elevation, set the elevation to 0.


I also run GPXZ which does have a bathymetry toggle for point queries: https://www.gpxz.io/docs/api-reference-points#elevation-points

If you're working on a personal or academic project I'd be happy to give you a free account.

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

No branches or pull requests

2 participants