Code Monkey home page Code Monkey logo

sb-graph's People

Contributors

joaquinffernandez avatar kalashnikovni avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

sb-graph's Issues

SBG parser

Currently, the SBG library doesn't count with a parser, which leads to a huge test suit (GraphTest).

It would be nice to define DSL for intervals, multi-intervals, etc. Then, define its parser. A big bonus would be a graphic interface to draw graphs.

SCC Algorithm

Develop an SCC algorithm for SBG, using minReach function.

SBG refactor

The current implementation makes use of the boost graph library to represent SBG. In the implementation of algorithms we use the defined maps (ignoring the boost module) or else we have to make two calls (one to boost and another to the SBG functions).
Also many modules of structures such as intervals, multi_intervals, etc. were in an experimental stage, and as such their implementation is pretty messy.
A complete refactor of these modules is proposed, adding the optimizations described in iss-18.

Real's representation

The current implementation of maps uses double to represent real numbers. This can be a problem when working with big numbers (main application of ModelicaCC), where the distribution of floating point numbers is sparse. With such numbers, the application of a map to a domain leads to an incorrect result.

Suggestion: use fractional numbers. Check if BOOST supports them.

Fix Eval System tests.

Currently disable pw_map and map eval system tests because they are failing consistently. Either fix or update them so we can add them back to the test-suite.

Minimum Reachable optimization

Currently the minimum reachable operation composes many times different maps. By profiling some examples, this last operation proved to be one of the most costly in regards to execution time. A very brief sketch of the proposed new implementation to be testes is as follows:

  1. Keep track of MRV (minimum reachable vertex) with a representative's map Rmap, and the distance to each of them with a distance map Dmap. Also, a successor map Smap will indicate the path used to reach each MRV.
  2. Calculate a new Rmap with adjacent vertices using minAdj.
  3. Between all the possible successors that lead to the MRV, choose the one with minimum distance to the MRV according to Dmap. The distance is necessary for the case in which the graph contains cycles.

Canonize sets, maps

Currently, sets are implemented without order. We think that canonizing them through order can be an improvement to the cost of the operations.

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.