iVis-at-Bilkent / cytoscape.js-cise

An implementation of the circular layout algorithm by Dogrusoz et al. as a Cytoscape.js extension
MIT License
31 stars 13 forks source link

Performance issue #11

Open ugurdogrusoz opened 3 years ago

ugurdogrusoz commented 3 years ago

According to @canbax When there are no clusters or just a small one, the performance is laggy. See https://github.com/ugurdogrusoz/visuall/issues/308.

ugurdogrusoz commented 3 years ago

Related to this?

canbax commented 3 years ago

I think this problem is not related to layout-utilities. I made a performance test and I see the below image image

You can see that calcRepulsionForcestakes too much time here, not the layout-utilities. I also attached the Performance Test file Profile-20201228T105931.json.zip

ugurdogrusoz commented 3 years ago

Looks like the major problem with performance is due to not using the FR grid variant used by other force-directed layout algorithms we have like CoSE. Let's implement FR grid variant.

Let's also make sure repulsion forces are not redundantly (twice) calculated for in-circle nodes as we noticed.

herencalik commented 3 years ago

I fixed the in-circle node repulsion force calculation problem but because we developed the expanding circle model based on their moves, as it is approximately halved now, I decreased the escape limit to expand the circle, too. I tested the layouts, however, I'm not sure about the quality. @ugurdogrusoz hocam, could you check the quality?

ugurdogrusoz commented 3 years ago

Looks reasonable @herencalik. Let's evaluate more carefully after FR grid variant is implemented.

ugurdogrusoz commented 3 years ago

@canbax The performance should be improved now.

canbax commented 3 years ago

I see an improvement but I still see a lag around 900-1000 ms. It is not too bad. It just makes a small freezing in the browser. This lag is around 50-100 ms in fcose.

ugurdogrusoz commented 3 years ago

Can you please provide specific before & after numbers?

canbax commented 3 years ago

https://github.com/ugurdogrusoz/visuall/issues/308#issuecomment-735829171 here I see it was around 1400-1500 ms. Now it is around 1000 ms.

ugurdogrusoz commented 3 years ago

Let's sleep on this for a while and see the performance as is.