-
Notifications
You must be signed in to change notification settings - Fork 163
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
Animation performance #367
Comments
@trvrb am going to do a branch for requestAnimationFrame now that we know we want animations with fixed times, I would expect this to be an improvement. |
Excellent. |
Cool. For what it's worth, I think the fixed times should be faster. |
Flu animation render stack time (i.e. the code executed during each |
I'm getting 220ms frames (4 FPS) for default Ebola animation on production. This looks to be about 100 ms for tree and 100 ms for map. This more what I'm expecting. 3y flu is about as big as Ebola and I'm getting 410ms frames on production. Moving forward I see two obvious ideas:
There may be internal logic that can get cleaned up as well. |
Commit e405742 fixes the duplicate |
Digging in more I see two avenues for substantial improvement. Slow calls are -
|
After merge of PR #377 the code execution of map is much improved: EDIT: this may or may not be the truth.... performance tools paints a very different story - see below comment
As noted by @trvrb, |
Current status of flu @ 006b892 Putting console log statements in the Tick compute time: 475ms
|
This is excellent. Thanks James. I believe |
Summary of things to do now:
|
|
Profile as of EDIT: updated to use non-development builds (very, very different!) Profile in development mode: A single action is always being dispatched through the reducer (confirmed, to the best of my ability, via console logs -- see #389 (comment)). It's harder to see what functions are being called, as they are renamed in the production code, but on the development builds, Testing at http://localhost:8080/flu/h3n2/ha/6y?c=region&dmin=2013-09-20&r=region, ticks take between 180 and 200ms plus around 25ms to recalculate CSS styles. It appears that
At http://localhost:8080/zika?dmin=2015-10-03 ticks take around 40ms 🎉 🎉 , plus around 10ms to recalculate CSS styles. It appears that
|
I've been investigating React Peformance Tools - https://facebook.github.io/react/docs/perf.html - and have implemented on the branch Time spent during each animation tick (on flu, link above): Not sure if I can get it to break |
Cool. Thanks for adding this James. Do you have a TLDR version of getting this readout? |
don't forget to run |
As of 69158da the animation speed is much improved - now it really looks as if the tree is the bottleneck |
Commit 4e1119b has Current animation has Ebola with 15ms render (plus 15ms repaint): So, we just need to clean up the |
Check if there's low hanging fruit to improve animation performance. The 100ms tick can probably be improved for Zika. @colinmegill: How was 100ms tick chosen? Ideally, we want this to tick as fast as render works but no faster.
The text was updated successfully, but these errors were encountered: