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

Visual clustering of POIs on map #8372

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

beasmm
Copy link
Contributor

@beasmm beasmm commented Jun 2, 2024

Closes #8291

We cerated a recursive function to cluster marks on the map to improve visibility while searching. We also created the code to give these mark clusters a symbol that shows the number o marks in each cluster. We did not, however, create the symbols themselves - we are using number symbols already present in the project as placeholders.

As mentioned in the title, the clusteringis purely visual: nothing happens when you click on them. Unfortunately, we did not have time to implement this...

Screenshots of changes

No Clustering With Clustering

Implemented a recursive function based on Hierarchical
Clustering, which clusters POIs together if the distance
between them is smaller than the 'threshold'. This
threshold is calculated using the Viewport's dimensions,
 changing everytime the users zooms in or out.

We also created the code to assign a mark symbols to these
clusters.

Co-authored-by: Dinis Caroço <[email protected]>

Signed-off-by: Beatriz Mendes <[email protected]>
@vng
Copy link
Member

vng commented Jun 2, 2024

Wow, it's a tricky implementation using our current icons without new entities. Nice job!

I'd like to get more UI/UX feedback here.

@vng vng requested review from biodranik, rtsisyk and pastk June 2, 2024 15:44
@vng
Copy link
Member

vng commented Jun 2, 2024

I haven't built it yet, but see a missing part of what happens when I tap on the "cluster".

@biodranik
Copy link
Member

There are crashes with zero-sized search results/clusters on the desktop with viewport search (e.g. food)

@cyber-toad
Copy link
Contributor

For now on non-clustered maps I can distinguish cafe/restaurant/fastfood by different icons. In clustered view it is not possible to see what is the type it until it is clicked.

@Osyotr
Copy link
Contributor

Osyotr commented Jun 2, 2024

This should be an option IMHO. I prefer "No Clustering" because I can clearly see exact locations and types of places.

@map-per
Copy link
Member

map-per commented Jun 5, 2024

For now on non-clustered maps I can distinguish cafe/restaurant/fastfood by different icons. In clustered view it is not possible to see what is the type it until it is clicked.

This should be an option IMHO. I prefer "No Clustering" because I can clearly see exact locations and types of places.

Keep in mind, that in the current public release implementation POIs that are too close to another POI are hidden until you zoom in further. So you can never be sure that the app displays all POIs.

@cyber-toad
Copy link
Contributor

cyber-toad commented Jun 5, 2024

Keep in mind, that in the current public release implementation POIs that are too close to another POI are hidden until you zoom in further. So you can never be sure that the app displays all POIs.

Maybe activate this merging only when some POIs are not displayed?
Here is an example when POI are displayed, distinguishable, clickable, but they are merged.

image

I remember how I tried to use one website with walking routes (don't remember it's name) where they merged all routes around a city to a single cluster "POI" placed to the city that need to be clicked and then routes are selected to be displayed one-by-one. So instead of convenient review and compare of multiple routes on the same map only one was visible each time - it was a nightmare.
It is not what we have in OM, just want to mention that this feature should be introduced very carefully because it reduces number of quickly accessible information and leads to additional clicks.

@pastk pastk marked this pull request as draft June 9, 2024 10:08
@pastk pastk marked this pull request as draft June 9, 2024 10:08
@pastk
Copy link
Contributor

pastk commented Jun 9, 2024

Beatriz and Dinis, thanks a lot for starting this PR!

I've tried to play with it (on a desktop) and got several crashes while searching for things.
ATM it looks very raw, so I took liberty to mark it as a "draft".

As mentioned above the chosen clustering thresholds seem to be too big.

IMO (and also mentioned above already) the current biggest issue is that OM just hides search results when they're too close / overlapping a lot.
This is the case when clustering might come actually useful.

Otherwise there is no point to cluster already visually distinguishable results.

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

Successfully merging this pull request may close these issues.

POI Clustering
7 participants