GithubHelp home page GithubHelp logo

Tips for improving efficiency about klayjs HOT 2 OPEN

kieler avatar kieler commented on July 30, 2024
Tips for improving efficiency

from klayjs.

Comments (2)

le-cds avatar le-cds commented on July 30, 2024

I'm not exactly the JavaScript person in the project, so I'll answer the question from a non-JavaScript point of view.

Are there ways of only laying out certain parts?

No, we currently don't have any layout algorithms that support this kind of thing.

Which of the layout options is the most efficient?

The following settings should improve the algorithm's performance:

de.cau.cs.kieler.klay.layered.nodeLayering: LONGEST_PATH
de.cau.cs.kieler.klay.layered.greedySwitch: OFF

You can also try the following setting, but I'm not sure if that will actually improve performance since the default setting should already be quite fast:

de.cau.cs.kieler.klay.layered.nodePlacement: LINEAR_SEGMENTS

How big a graph would you expect to have calculation time of less than half a second?

That's a bit hard to answer. In general, layout performance not only depends on the number of nodes, but also on the number of edges and the graph's general structure. Having said that, I would expect layout to take less than half a second for up to a couple of hundred nodes with a reasonable number of connections. On desktop computers, that is. I don't have any point of reference for mobile devices. See ticket #15 for another discussion on algorithm performance.

from klayjs.

forresto avatar forresto commented on July 30, 2024

@robclouth Have you tried running klay in a worker? https://github.com/OpenKieler/klayjs#web-worker

from klayjs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.