Page MenuHomePhabricator

multiple items with identical coordinates not discoverable in map view?
Closed, ResolvedPublic

Description

It seems when I click on dots, I can only get one item.

#defaultView:Map
SELECT ?item ?itemLabel ?coor ?layerLabel 
{
  	VALUES ?pob { wd:Q60 } 
  	?item wdt:P19 ?pob .
  	?pob wdt:P625 ?coor .
  	?item wdt:P21 ?layer .
  	SERVICE wikibase:label { bd:serviceParam wikibase:language "en" }
}
LIMIT 100

try it !

Possible workarounds:

  • add random additional digits to coordinates (Point(-73.940001 40.67) instead of Point(-73.94 40.67)?
  • calculate number of items per coordinate/concatenate results on location

Event Timeline

Esc3300 created this task.Nov 6 2016, 6:09 PM
Restricted Application added a project: Discovery. · View Herald TranscriptNov 6 2016, 6:09 PM
Restricted Application added a subscriber: Aklapper. · View Herald Transcript
Esc3300 updated the task description. (Show Details)Nov 6 2016, 6:17 PM
Esc3300 updated the task description. (Show Details)Nov 6 2016, 6:20 PM
debt added a project: Maps.Nov 7 2016, 6:12 PM
debt added a subscriber: Yurik.
Yurik moved this task from All map-related tasks to Tracking on the Maps board.Nov 7 2016, 7:19 PM
Esc3300 updated the task description. (Show Details)Nov 7 2016, 7:37 PM
Esc3300 updated the task description. (Show Details)Nov 17 2016, 10:35 AM

Unrelated to the Maps project.

Change 387298 had a related patch set uploaded (by Jonas Kress (WMDE); owner: Jonas Kress (WMDE)):
[wikidata/query/gui@master] Decrease fill opacity so overlaps are discoverable

https://gerrit.wikimedia.org/r/387298

Jonas moved this task from Backlog to Doing on the Wikidata Query UI board.Oct 30 2017, 5:28 PM

Does not completely fix the problem, but at least is an improvement for some situations...
Decreased fill opacity so overlaps are discoverable:

Change 387842 had a related patch set uploaded (by Lucas Werkmeister (WMDE); owner: Lucas Werkmeister (WMDE)):
[wikidata/query/gui@master] Optionally use leaflet.markercluster for map

https://gerrit.wikimedia.org/r/387842

thiemowmde triaged this task as Low priority.Nov 13 2017, 10:30 AM
thiemowmde moved this task from incoming to needs discussion or investigation on the Wikidata board.

I currently don't see this on any sprint board, but two patches are uploaded. Can you please fix this and move this to the appropriate columns?

Jonas moved this task from Doing to Done on the Wikidata Query UI board.Nov 16 2017, 12:45 PM

Change 387842 merged by jenkins-bot:
[wikidata/query/gui@master] Use leaflet.markercluster for single-layer maps

https://gerrit.wikimedia.org/r/387842

Change 387298 abandoned by Jonas Kress (WMDE):
Decrease fill opacity so overlaps are discoverable

https://gerrit.wikimedia.org/r/387298

Jonas closed this task as Resolved.Nov 20 2017, 10:17 AM
Salgo60 added a subscriber: Salgo60.EditedNov 21 2017, 12:28 PM

Looks like problem scaling .... see query query with +11000 items returned...

# Swedish National museum P195 wd:Q842858
#defaultView:Map
SELECT ?work  ?coord
WHERE {
?work wdt:P195/wdt:P361* wd:Q842858 .
?work wdt:P195/wdt:P625 ?coord . 	#Collection P195/Coordinates P625
}
ORDER BY DESC (?rank)

If you click in Stockholm at the National Museum then most of the items will be at the museum ==> tweet

Did a second test and then it was 4-5 sec which maybe is good enough see video

Hm, that was more intended for solutions with a few different results per identical coordinates… I’m not sure if there’s any good way to represent seven thousand results with the same coordinates on a map.

I agree its more than excellent for a few..... and maybe not as bad for 11000 when we look at performance but rather user unfriendly ;-)
getting +10000 dots to select from....

Maybe the person doing the query should use a "group by ?coord" and then let the user click to see an imageview of all paintings at this coordinates....

The user case is a museum that has given a lot of paintings and has the same coordinates for all paintings in the collection....

Salgo60 added a comment.EditedDec 4 2017, 4:03 PM

It stopped working for me today?!?!

Example query and click on Stockholm. It is 513 items...

Your query uses layers, and I couldn’t figure out how to make Leaflet.markercluster and layers interact nicely, so for now it’s disabled by default if the results have more than one layer. You can force-enable it with #defaultView:Map{"markercluster":true}.