Skip to content
This repository has been archived by the owner on Jun 3, 2024. It is now read-only.

performance issues between 0.28.0 and 0.32.0 - support plotly.js immutable mode #343

Open
chriddyp opened this issue Oct 23, 2018 · 5 comments

Comments

@chriddyp
Copy link
Member

Repro example produced here: https://community.plot.ly/t/dash-core-component-performance-issues-on-mapbox-graphs-between-versions/14821/6

@chriddyp
Copy link
Member Author

@rockg
Copy link

rockg commented Jan 16, 2019

I was able to pinpoint this performance regression between dcc versions 30.1 and 30.2 which narrows it down considerably. I believe that this line is the culprit which is creating a deep copy of the layout which can be large when one has a lot of geojson data. I see that this was put in to solve a resize issue and wonder if there are other alternatives. Curious to hear your thoughts @valentijnnieman and @chriddyp.

@rockg
Copy link

rockg commented Jan 16, 2019

I built master and removed clone and the performance is back to 30.1 levels so the root cause is verified.

@alexcjohnson
Copy link
Collaborator

A full deep clone is certainly overkill for the intended fix (original PR #279), though considering data #287 and all the other places plotly.js might mutate layout, I suspect it would be easier to just implement a plotly.js immutable mode plotly/plotly.js#2389 than to figure out (and maintain) a safe-yet-fast copy operation here.

@chriddyp
Copy link
Member Author

Another community post to follow-up on when this gets fixed one way or another https://community.plot.ly/t/mapbox-map-loads-quickly-in-older-version-of-dash-but-not-on-latest-version/31722/2
cc @nicolaskruchten as well

@chriddyp chriddyp added this to the Dash Q1/2020 milestone Jan 24, 2020
@chriddyp chriddyp changed the title performance issues between 0.28.0 and 0.32.0? performance issues between 0.28.0 and 0.32.0 - support plotly.js immutable mode Jan 31, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants