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

Please add Folium pane #1192

Closed
MarcSkovMadsen opened this issue Mar 26, 2020 · 6 comments
Closed

Please add Folium pane #1192

MarcSkovMadsen opened this issue Mar 26, 2020 · 6 comments
Labels
type: enhancement Minor feature or improvement to an existing feature

Comments

@MarcSkovMadsen
Copy link
Collaborator

My Pain

I would like Panel to be great and support the most common python visualization libraries and associated js libraries.

One such Python Package is Folium. You can use a Folium map in Panel using pn.pane.HTML but if you try to make the map interactive it redraws the whole _repr_html_ from scratch every time making the screen flickr.

Solution

Add panel Folium pane based on a Folium Bokeh model.

Additional Context

You can experience the flickr via this contribution #1189

panel_folium_example

@MarcSkovMadsen MarcSkovMadsen added the TRIAGE Default label for untriaged issues label Mar 26, 2020
@jbednar
Copy link
Member

jbednar commented Mar 26, 2020

At the 2018 SciPy conference, l believe that the main author of Folium (https://github.com/ocefpaf) suggested that it was not something he was recommending that people use anymore; has that changed?

@MarcSkovMadsen
Copy link
Collaborator Author

MarcSkovMadsen commented Mar 26, 2020

Hi @jbednar . I did not attend and have not heard about that. Its not stated on Github or the web site either.

What I can see is that it is 7 times more starred than Panel and there is activity

image

@MarcSkovMadsen
Copy link
Collaborator Author

But @jbednar I guess the feature request should be extended to a Folium + Leaflet.js pane?

@philippjfr
Copy link
Member

Doesn't seem to be stopping people:

Screen Shot 2020-03-26 at 5 10 32 AM

@jbednar
Copy link
Member

jbednar commented Mar 26, 2020

Ok, I've talked to Filipe, who clarified that Folium has a strong future as long as people realize that it is expected to remain a one-way street, constructing JS artifacts from Python without providing a pathway to return data back to Python/Jupyter/JupyterLab. If users need two-way communication of that sort, Filipe suggests they look to other tools like Bokeh or ipyleaflet.

With that in mind, providing a Folium Pane sounds very reasonable, so that people can make use of all the Folium examples that are out there! Filipe also clarified that Frank Conengmo (https://github.com/Conengmo) is the new Folium maintainer, and so we should follow up with him if we want to chat about the Folium roadmap.

@philippjfr philippjfr added type: enhancement Minor feature or improvement to an existing feature and removed TRIAGE Default label for untriaged issues labels Apr 1, 2020
@philippjfr
Copy link
Member

A basic Folium pane was merged, and I don't think the flicker is actually avoidable because Folium does not have JS bindings which would allow us to update the map/plot incrementally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement Minor feature or improvement to an existing feature
Projects
None yet
Development

No branches or pull requests

3 participants