Closed duuliy closed 3 years ago
@duuliy Thanks for using fCoSE. fCoSE is designed for small to medium-sized graphs (up to a few thousand of nodes and edges), so depending on the graph topology closing to or exceeding these numbers may cause a decrease in the performance of the algorithm. Here are some ways we can suggest for a better performance:
uniformNodeDimensions
option to true
. This saves important amount of force-related calculations.packComponents
option. This option enables fCoSE to lay out each component separately and then pack them in a pleasing way. Laying out smaller portions instead of the whole graph also increases the performance. Please note that this option requires cytoscape-layout-utilities extension to be registered in your app.I also suggest using the latest version of fCoSE, since it includes new features and miscellaneous bug fixes.
@duuliy感谢您使用 fCoSE。fCoSE 是为中小型图(最多几千个节点和边)设计的,因此根据接近或超过这些数字的图拓扑,可能会导致算法性能下降。我们可以建议以下一些方法以获得更好的性能:
- 如果您的节点尺寸统一或接近统一,您可以将
uniformNodeDimensions
选项设置为true
。这节省了大量与力相关的计算。- 如果您的图形由断开连接的组件组成,那么您可以激活
packComponents
选项。此选项使 fCoSE 能够单独布置每个组件,然后以令人满意的方式将它们打包。布置较小的部分而不是整个图形也可以提高性能。请注意,此选项需要在您的应用程序中注册cytoscape-layout-utilities扩展。如果图很大,我们建议使用复杂性管理技术。这些技术包括:
- 将图形聚类为复合节点(如果当前没有),然后在必要时折叠/展开。请参阅cytoscape-expand-collapse扩展。
- 隐藏当前不必要的细节并逐渐按需显示。请参阅cytoscape-view-utilities扩展。
我还建议使用最新版本的 fCoSE,因为它包含新功能和各种错误修复。
OK, thank you for your reply
My configuration is as follows "cytoscape-fcose": "^1.2.3" ,Is there a better optimization plan
name: 'fcose', fit: true, padding: 30, animate: false, nodeSeparation: 225, piTol: 0.0000001, nodeRepulsion: 18000, idealEdgeLength: 100, edgeElasticity: 0.45, nestingFactor: 0.1, tile: false, tilingPaddingVertical: 30, tilingPaddingHorizontal: 30,