Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
19 changes: 4 additions & 15 deletions data/102/555/091/102555091.geojson
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"mz:categories":[],
"mz:hierarchy_label":1,
"mz:is_current":1,
"mz:min_zoom":13.0,
"mz:min_zoom":13,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Our zoom values should remain floats (13.0, rather than 13).

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

The docs were run through 'exportify' so I don't have any control over how they are serialised 🤷

"name:ara_x_preferred":[
"\u0645\u0637\u0627\u0631 \u062a\u0648\u0631\u0648\u0646\u062a\u0648 \u0628\u064a\u0631\u0633\u0648\u0646 \u0627\u0644\u062f\u0648\u0644\u064a"
],
Expand Down Expand Up @@ -163,10 +163,9 @@
85895633,
102191575,
85633041,
101740755,
101735893,
890456343,
85682057,
101735893
85682057
],
"wof:breaches":[],
"wof:concordances":{
Expand All @@ -181,16 +180,6 @@
],
"wof:geomhash":"131d17c4a99435510ef6e2b02e5cc478",
"wof:hierarchy":[
{
"campus_id":102555091,
"continent_id":102191575,
"country_id":85633041,
"county_id":890456343,
"locality_id":101740755,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

So, in this case, the record currently has a dual hierarchy, but only one of the hierarchies is valid.. we should remove this entire hierarchy set so this feature only has one hierarchy (the one below, with "locality_id":101735893).

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

How do I detect an valid/invalid hierarchy?

@missinglink missinglink Jul 8, 2020

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

I added a56eabe which I think is the correct fix.

// deduplicate hierarchies
// remove any hierarchies which are duplicates of, or a subset of another hierarchy
const deduplicatedHierarchies = hierarchies.filter((h1, b1) => {
  return !hierarchies.some((h2, b2) => (b1 != b2) && _.isMatch(h2, h1))
})

[edit] this deduplication algo was improved further and tested in pelias/wof#25

"microhood_id":1108905413,
"neighbourhood_id":85895633,
"region_id":85682057
},
{
"campus_id":102555091,
"continent_id":102191575,
Expand All @@ -203,7 +192,7 @@
}
],
"wof:id":102555091,
"wof:lastmodified":1582309536,
"wof:lastmodified":1594246593,
"wof:name":"Toronto Lester B Pearson International Airport",
"wof:parent_id":1108905413,
"wof:placetype":"campus",
Expand Down
22 changes: 6 additions & 16 deletions data/110/890/541/3/1108905413.geojson
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@
"iso:country":"CA",
"lbl:latitude":43.676352,
"lbl:longitude":-79.628342,
"lbl:max_zoom":18.0,
"lbl:max_zoom":18,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Same goes for lbl zooms, let's keep them float values (18.0, rather than 18).

"mps:latitude":43.676352,
"mps:longitude":-79.628342,
"mz:hierarchy_label":1,
"mz:is_current":1,
"mz:is_funky":0,
"mz:is_landuse_aoi":1,
"mz:max_zoom":18.0,
"mz:min_zoom":16.0,
"mz:max_zoom":18,
"mz:min_zoom":16,
"name:eng_x_variant":[
"YYZ",
"CYYZ"
Expand All @@ -32,26 +32,16 @@
85895633,
102191575,
85633041,
101740755,
101735893,
890456343,
85682057,
101735893
85682057
],
"wof:breaches":[],
"wof:concordances":{},
"wof:controlled":[],
"wof:country":"CA",
"wof:geomhash":"94f6fdf261d52145bfa08ee05579cec6",
"wof:hierarchy":[
{
"continent_id":102191575,
"country_id":85633041,
"county_id":890456343,
"locality_id":101740755,
"microhood_id":1108905413,
"neighbourhood_id":85895633,
"region_id":85682057
},
{
"continent_id":102191575,
"country_id":85633041,
Expand All @@ -63,7 +53,7 @@
}
],
"wof:id":1108905413,
"wof:lastmodified":1566519299,
"wof:lastmodified":1594246594,
"wof:name":"Toronto Lester B Pearson International Airport District",
"wof:parent_id":85895633,
"wof:placetype":"microhood",
Expand Down
20 changes: 9 additions & 11 deletions data/110/895/282/5/1108952825.geojson
Original file line number Diff line number Diff line change
Expand Up @@ -5,33 +5,32 @@
"edtf:cessation":"uuuu",
"edtf:inception":"uuuu",
"geom:area":0.000392,
"geom:area_square_m":3158685.521674,
"geom:area_square_m":3158685.521678,
"geom:bbox":"-123.056198612,49.2903227,-123.001769986,49.3046702",
"geom:latitude":49.296361,
"geom:longitude":-123.032296,
"iso:country":"CA",
"lbl:latitude":49.29406,
"lbl:longitude":-123.035848,
"lbl:max_zoom":18.0,
"lbl:max_zoom":18,
"mps:latitude":49.29406,
"mps:longitude":-123.035848,
"mz:hierarchy_label":1,
"mz:is_current":1,
"mz:is_funky":0,
"mz:is_landuse_aoi":1,
"mz:max_zoom":18.0,
"mz:min_zoom":16.0,
"mz:max_zoom":18,
"mz:min_zoom":16,
"reversegeo:latitude":49.29406,
"reversegeo:longitude":-123.035848,
"src:geom":"mz",
"wof:belongsto":[
85682117,
102191575,
85633041,
101741075,
85874397,
85633041,
85682117,
101741055,
85894953,
85894937,
1108952753
],
"wof:breaches":[],
Expand All @@ -47,15 +46,14 @@
"country_id":85633041,
"locality_id":101741075,
"microhood_id":1108952825,
"neighbourhood_id":85874397,
"region_id":85682117
},
{
"continent_id":102191575,
"country_id":85633041,
"locality_id":101741055,
"microhood_id":1108952825,
"neighbourhood_id":85894953,
"neighbourhood_id":85894937,
"region_id":85682117
},
{
Expand All @@ -68,7 +66,7 @@
}
],
"wof:id":1108952825,
"wof:lastmodified":1566519254,
"wof:lastmodified":1594246594,
"wof:name":"Second Narrows",
"wof:parent_id":1108952753,
"wof:placetype":"microhood",
Expand Down
19 changes: 5 additions & 14 deletions data/112/606/087/7/1126060877.geojson
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"edtf:cessation":"uuuu",
"edtf:inception":"uuuu",
"geom:area":0.0,
"geom:area_square_m":0.0,
"geom:area_square_m":0,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

hmmm... exportify tool?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

this is the command I'm using to run exportify in docker:
https://github.com/pelias/wof/blob/master/whosonfirst/exportify.js

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

I'm a bit confuddled by this, why was geom:area_square_m converted to 0 but the line above geom:area remained 0.0 😕

"geom:bbox":"-76.95069,44.24832,-76.95069,44.24832",
"geom:latitude":44.24832,
"geom:longitude":-76.95069,
Expand All @@ -16,10 +16,10 @@
"lbl:bbox":"-76.95569,44.24332,-76.94569,44.25332",
"lbl:latitude":44.24832,
"lbl:longitude":-76.95069,
"lbl:max_zoom":18.0,
"lbl:max_zoom":18,
"mz:hierarchy_label":1,
"mz:is_current":1,
"mz:min_zoom":15.0,
"mz:min_zoom":15,
"mz:note":"Quattroshapes Point Gazetteer import 20170519",
"qs_pg:aaroncc":"CA",
"qs_pg:gn_country":"CA",
Expand All @@ -40,8 +40,7 @@
102191575,
85633041,
101736227,
890457185,
101740731
890457185
],
"wof:breaches":[],
"wof:concordances":{
Expand All @@ -59,18 +58,10 @@
"locality_id":101736227,
"neighbourhood_id":1126060877,
"region_id":85682057
},
{
"continent_id":102191575,
"country_id":85633041,
"county_id":890457185,
"locality_id":101740731,
"neighbourhood_id":1126060877,
"region_id":85682057
}
],
"wof:id":1126060877,
"wof:lastmodified":1566520339,
"wof:lastmodified":1594246595,
"wof:name":"Napanee Downtown",
"wof:parent_id":-1,
"wof:placetype":"neighbourhood",
Expand Down
19 changes: 5 additions & 14 deletions data/112/606/087/9/1126060879.geojson
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"edtf:cessation":"uuuu",
"edtf:inception":"uuuu",
"geom:area":0.0,
"geom:area_square_m":0.0,
"geom:area_square_m":0,
"geom:bbox":"-76.94424,44.25122,-76.94424,44.25122",
"geom:latitude":44.25122,
"geom:longitude":-76.94424,
Expand All @@ -16,10 +16,10 @@
"lbl:bbox":"-76.94924,44.24622,-76.93924,44.25622",
"lbl:latitude":44.25122,
"lbl:longitude":-76.94424,
"lbl:max_zoom":18.0,
"lbl:max_zoom":18,
"mz:hierarchy_label":1,
"mz:is_current":1,
"mz:min_zoom":15.0,
"mz:min_zoom":15,
"mz:note":"Quattroshapes Point Gazetteer import 20170519",
"name:bul_x_preferred":[
"\u0421\u043a\u0435\u0439\u0442 \u043f\u0430\u0440\u043a"
Expand Down Expand Up @@ -91,8 +91,7 @@
102191575,
85633041,
101736227,
890457185,
101740731
890457185
],
"wof:breaches":[],
"wof:concordances":{
Expand All @@ -110,18 +109,10 @@
"locality_id":101736227,
"neighbourhood_id":1126060879,
"region_id":85682057
},
{
"continent_id":102191575,
"country_id":85633041,
"county_id":890457185,
"locality_id":101740731,
"neighbourhood_id":1126060879,
"region_id":85682057
}
],
"wof:id":1126060879,
"wof:lastmodified":1566520339,
"wof:lastmodified":1594246596,
"wof:name":"Skatepark",
"wof:parent_id":-1,
"wof:placetype":"neighbourhood",
Expand Down
21 changes: 6 additions & 15 deletions data/112/606/115/3/1126061153.geojson
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"edtf:cessation":"uuuu",
"edtf:inception":"uuuu",
"geom:area":0.0,
"geom:area_square_m":0.0,
"geom:area_square_m":0,
"geom:bbox":"-80.480099,43.430624,-80.480099,43.430624",
"geom:latitude":43.430624,
"geom:longitude":-80.480099,
Expand All @@ -14,10 +14,10 @@
"lbl:bbox":"-80.485099,43.425624,-80.475099,43.435624",
"lbl:latitude":43.430624,
"lbl:longitude":-80.480099,
"lbl:max_zoom":18.0,
"lbl:max_zoom":18,
"mz:hierarchy_label":1,
"mz:is_current":1,
"mz:min_zoom":15.0,
"mz:min_zoom":15,
"mz:note":"Quattroshapes Point Gazetteer import 20170519",
"name:fra_x_preferred":[
"Southdale"
Expand Down Expand Up @@ -49,9 +49,8 @@
85682057,
102191575,
85633041,
101740709,
890456483,
101735989
101735989,
890456483
],
"wof:breaches":[],
"wof:concordances":{
Expand All @@ -62,14 +61,6 @@
"wof:created":1497308154,
"wof:geomhash":"74803e7d10c4af0caeec7372a936a2c7",
"wof:hierarchy":[
{
"continent_id":102191575,
"country_id":85633041,
"county_id":890456483,
"locality_id":101740709,
"neighbourhood_id":1126061153,
"region_id":85682057
},
{
"continent_id":102191575,
"country_id":85633041,
Expand All @@ -80,7 +71,7 @@
}
],
"wof:id":1126061153,
"wof:lastmodified":1566520339,
"wof:lastmodified":1594246597,
"wof:name":"Southdale",
"wof:parent_id":-1,
"wof:placetype":"neighbourhood",
Expand Down
19 changes: 5 additions & 14 deletions data/112/606/616/5/1126066165.geojson
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"edtf:cessation":"uuuu",
"edtf:inception":"uuuu",
"geom:area":0.0,
"geom:area_square_m":0.0,
"geom:area_square_m":0,
"geom:bbox":"-80.16938,43.92943,-80.16938,43.92943",
"geom:latitude":43.92943,
"geom:longitude":-80.16938,
Expand All @@ -16,10 +16,10 @@
"lbl:bbox":"-80.17438,43.92443,-80.16438,43.93443",
"lbl:latitude":43.92943,
"lbl:longitude":-80.16938,
"lbl:max_zoom":18.0,
"lbl:max_zoom":18,
"mz:hierarchy_label":1,
"mz:is_current":1,
"mz:min_zoom":15.0,
"mz:min_zoom":15,
"mz:note":"Quattroshapes Point Gazetteer import 20170519",
"name:cat_x_preferred":[
"Farmington"
Expand Down Expand Up @@ -112,8 +112,7 @@
102191575,
85633041,
101736211,
890456799,
101740765
890456799
],
"wof:breaches":[],
"wof:concordances":{
Expand All @@ -132,18 +131,10 @@
"locality_id":101736211,
"neighbourhood_id":1126066165,
"region_id":85682057
},
{
"continent_id":102191575,
"country_id":85633041,
"county_id":890456799,
"locality_id":101740765,
"neighbourhood_id":1126066165,
"region_id":85682057
}
],
"wof:id":1126066165,
"wof:lastmodified":1566520338,
"wof:lastmodified":1594246598,
"wof:name":"Farmington",
"wof:parent_id":-1,
"wof:placetype":"neighbourhood",
Expand Down
Loading