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
Fix use of schema:GeoShape #159
Comments
Thinking something like: "geo": {
"@type": "schema:GeoShape",
"schema:polygon": "wkt 1234567890",
"seeAlso": "https://opengeospatial.github.io/ELFIE/usgs/nhdplusflowline/huc12obs/070900020601.geojson"
} |
I'd rather use gsp properties for declaring wkt literals for the sake of compatibility with GeoSparql. |
@afeliachi : Schema only recognizes the following DataType : http://schema.org/DataType. WKT is not one of them. We considered somehow that WKT was 'a subtype of Text'. |
@sgrellet : double typing would be a good solution. like: "geo": {
"@type": [ "schema:GeoShape", "gsp:Geometry" ],
"gsp:asWKT": "POLYGON(12 34, 56 78, ....)",
"seeAlso": "https://opengeospatial.github.io/ELFIE/usgs/nhdplusflowline/huc12obs/070900020601.geojson"
} @dblodgett-usgs: I have I question though. Am not very familiar with geojson, what does (or can) the geojson file contain? The whole description of the feature or only the geometry or possibly many geometries? |
@afeliachi: My knowledge of GeoJSON is not very precise, but from using http://geojsonlint.com/ -- it appears that you can do all of the above. All of the files that I generated in my latest work are FeatureCollections because the standard GDAL GeoJSON export creates FeatureCollections as far as I know. I would rather just do the geometry of one feature though... maybe in my next round of what I'll export with GDAL then open the result and remove the FeatureCollection wrapper. In general, I'm actually leaning toward implementing schema:geoShape exactly as the schema.org description says:
If you made me interpret this given common practice, I'd use the GPS lat/lon datum (WGS84), I'd use X/Y axis order, and I'd follow the right hand rule. Se we'd have like: "geo": {
"@type": "GeoShape",
"polygon": "-91 40 -91 41 -90 41 -90 40 -91 40"
} Looking at one of the comments here: schemaorg/schemaorg#113 it sounds like there is actually a test tool. Will look into that too. Still not sure exactly where we should land with this, but I think a gsp:hasGeometry with the asWKT seperate from schema.org is going to be the way to go... I would rather not double type a single shema:geo element. Further thoughts anyone? |
Dave, apologies if this is irrelevant, but are you considering inner rings? And knowing which polygon of a feature is the outer ring? That’s settled in OGC simple features, just checking.
dka
|
We would include interior rings in a WKT represetnation and/or a geojson representation. |
Maybe I'm late to the part, but for the record, this thread is really topical. geojson/geojson-ld#28 I suggest we all go over there and read what was discussed (7 years ago!!!) @dr-shorthair even makes an appearance. And it continues here: geojson/geojson-ld#31 ... and, it's dead. |
For the record, the argument over literals versus distinct coordinate entities for geometries is much older than that, and hasn’t changed much over the years.
… On Feb 27, 2018, at 8:37 AM, David Blodgett ***@***.***> wrote:
Maybe I'm late to the part, but for the record, this thread is really topical. geojson/geojson-ld#28 <geojson/geojson-ld#28>
I suggest we all go over there and read what was discussed (7 years ago!!!) @dr-shorthair <https://github.com/dr-shorthair> even makes an appearance.
And it continues here: geojson/geojson-ld#31 <geojson/geojson-ld#31>
... and, it's dead.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub <#159 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AExWhiJjjWH6dFKzbTIsNe6X7Z4uN6DJks5tZAUugaJpZM4SOY-w>.
|
I've implemented a suite of solutions to this now.
So the relevant section of a json-ld looks like: (lots of coordinates dropped) "geo": [
{
"@type": "schema:GeoCoordinates",
"schema:latitude": 43.2114,
"schema:longitude": -89.521
},
{
"@type": "schema:GeoShape",
"schema:url": "https://opengeospatial.github.io/ELFIE/usgs/hucboundary/huc12obs/070900020601.geojson",
"schema:polygon": "-89.42488760601 43.216595418436 -89.4252467539262 43.2168434934356 -89.4257269883004 ... -89.42488760601 43.216595418436"
}
],
"gsp:hasGeometry": {
"@type": "gsp:Geometry",
"gsp:asWKT": "MULTIPOLYGON (((-89.42489 43.2166, -89.42525 43.21684, -89.42573 43.21715, ... -89.42532 43.21637, -89.42489 43.2166)))"
} side note -- for multilinestring, I used a convex hull instead of trying to choose one line for the GeoShape but the WKT represents it fine. I also dropped any holes from the GeoShape. I think this is in the spirit of the schema:GeoShape being a preview and the gsp:hasGeometry being a more rigorous representation. Maybe the schema:url, which has a richer description of the feature is the solution to "where's the geometry" of a schema:GeoShape? |
I think this is a totally solid final approach |
Should be doing something like:
Have:
Need to determine the best way to encode the link to the geojson document. @abhritchie @jkreft-usgs will drop ideas in here.
The text was updated successfully, but these errors were encountered: