Skip to content

Bypassing most of the heavy lifting in the rAF for when there's no interaction #731

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

Merged
merged 2 commits into from
Jul 11, 2016

Conversation

monfera
Copy link
Contributor

@monfera monfera commented Jul 9, 2016

Solves the symptoms of #730 in that it reduces idle CPU utilization from 100% to around 5% at 500k-1m data points (as measured even for non-fancy 2d WebGL scatterplot)

var selection = this.lastPickResult = nextSelection;
var selection = nextSelection;
this.lastPickResult = {
trace: nextSelection.trace, // could we just retain/compare the trace uid?
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could we just retain/compare the trace uid?

I think so. @monfera can you try?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@etpinard Yes it works. Made the change, checked tooltip and CPU behavior (all OK), pushed.

@etpinard
Copy link
Contributor

that it reduces idle CPU utilization from 100% to around 5% at 500k-1m data points

Great work. Thanks very much.

… lastPickResults

(cherry picked from commit a2efeb4)
@etpinard
Copy link
Contributor

@monfera thanks!

@etpinard etpinard merged commit d96e5e1 into plotly:master Jul 11, 2016
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.

2 participants