Skip to content

Plotly react performance plummets with large number of traces #3227

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

Closed
rhamner opened this issue Nov 8, 2018 · 4 comments
Closed

Plotly react performance plummets with large number of traces #3227

rhamner opened this issue Nov 8, 2018 · 4 comments

Comments

@rhamner
Copy link

rhamner commented Nov 8, 2018

I found one conversation about this in issue 1535 and it was referenced as the achilles heell in plotly in the comments but that was over a year ago so I wanted to include a new example to see if anything can be done.

A contrived, reproducing example is here:

example

On my machine in chrome and plotly 1.42.4, I'm getting the following results for rendering 10k total points:

  • 1 trace: ~80 ms/call
  • 10 traces: ~90 ms/call
  • 100 traces: ~140 ms/call
  • 1000 traces: ~650 ms/call

The real-life example that made me notice this is 15k points going from <200 ms/call to ~15 seconds/call over the range of trace numbers. This is really impactful in our use case. We are already trying to minimize the total number of traces so I'm not sure if there's anything we can do to improve this on our end.

@rhamner
Copy link
Author

rhamner commented Nov 16, 2018

I am also seeing something unexpected that's maybe related to this. I'm not sure if this is a bug or if this is just how plotly.js works, but each call to Plotly.react with many traces shows up as multiple calls to react and/or newplot when I track performance.

image

That is the result of two calls to Plotly.react. Here is the codepen I used:

https://codepen.io/rhamner/pen/NEvNeO?editors=1010

@Shmew
Copy link

Shmew commented Nov 26, 2019

Any progress on this? Having this issue when adapting the python version's gantt component.

@lokeshmajji
Copy link

lokeshmajji commented Nov 20, 2020

I see this issue when plotting more than 500 traces with plotlyjs/plotlyjs angular , Python Plotly doesn't have this issue though.

@gvwilson
Copy link
Contributor

Hi - this issue has been sitting for a while, so as part of our effort to tidy up our public repositories I'm going to close it. If it's still a concern, we'd be grateful if you could open a new issue (with a short reproducible example if appropriate) so that we can add it to our stack. Cheers - @gvwilson

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

No branches or pull requests

5 participants