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

Google Chrome Renderer 98% ! #32

Closed
gg4u opened this issue Apr 23, 2013 · 1 comment
Closed

Google Chrome Renderer 98% ! #32

gg4u opened this issue Apr 23, 2013 · 1 comment

Comments

@gg4u
Copy link

gg4u commented Apr 23, 2013

Hello!
so I've been playing around pretty much so far.
I've learnt how to use this amazing library and I am building a whole interface with it.

I maybe add to many features (and true, I've got still to optimize )

and indeed it is time to optimize:
I found google renderer consumes 98% of CPU when opening large graphs.
Probably because of the settings of the spring.
Or probably because labels are also split in multiple lines... i don't know yet
(please advice on how to debug efficiently)

Below, I'll post my settings for the spring-force layout.

Could you please elaborate more on how much each parameters is affecting on computation?
Alternatively, how to build a button that stop the computation and freeze the graph, and than if clicked again keeps on relaxing it?

tks for the advice and sharing of ideas!

this settings are the one i found to let graph relax smoothly.. pleae share also your ideas folks!

springLength : 270,
//springCoeff : 0.00055,
//springCoeff : 0.0000055,
springCoeff : 0.00001,
//dragCoeff : 0.09,
//dragCoeff : 0.01,
dragCoeff : 0.005,
//gravity : -1,
//gravity : -2.5,
gravity : -1.5

@anvaka
Copy link
Owner

anvaka commented May 3, 2013

You can user renderer.pause()/renderer.resume() methods to toggle layout calculation.

yasiv/graps allows you to play with each argument of the layout algorithm and see how it affects the layout in general. You can also hover over question mark there to read more. Even more information is available in the source code of forceDirected layout.

@anvaka anvaka closed this as completed May 3, 2013
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

2 participants