python-visualization / python-visualization/folium

Heatmap scalability

Ouverte
#1,430 1 commentaire 1 réaction 0 personnes assignées Voir sur GitHub

Personne n'a encore pris cette issue.

enhancement
Langage dominant
Python
Étoiles
7.4k
Forks
2.3k
Merge moyen
17 h 22 min
PR mergées (30 j)
11

Description

The heatmap plugin is not very scalable at the moment. For millions few data points, the map is "laggy" when moving the maps around (at a reasonable zoom level, when most of the data points are hidden).

From what I've investigated, it comes from the fact the, when the _redraw function is called, the code iterates over all data points to check if it is or not in the bounds of the map being shown.
It seems very inefficient since there exists data structure such as R-Tree that can efficiently retrieve the data points inside a box.

Now it seems that the Leaftlet.heat plugin is not maintained anymore (as noted in #1282 ). As far as I can tell, there is only the .min.js file on this repository, what are the plans for this plugin?
Host it completely on this organization so it can be modified and maintained?

For the problem of the performances, I wrote a quick POC using rbush and it improves the performance when we zoom on a specific area (and fewer points are actually shown on the map). I can contribute to this issue if necessary.

Guide de contribution

Ouvrir le guide de contribution

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Piste de recherche

Commencez par localiser le JavaScript minifié du plugin de heatmap et son chemin _redraw, puis examinez la preuve de concept rbush signalée ainsi que les préoccupations liées à la maintenance de Leaflet.heat. La tâche sera considérée comme terminée lorsqu’un périmètre convenu pour la maintenance du plugin aura été défini et qu’il aura été démontré que la heatmap offre de meilleures performances lors du rendu de millions de points.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
javascript
Domaine
data-visualization
Type d'issue
Fonctionnalité
Difficulté
5/5
Temps estimé
Plus d'une semaine
Activité
À l'abandon
Clarté
À clarifier
Accessibilité débutants
25/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.