Coder Social home page Coder Social logo

traffic's People

Contributors

dependabot[bot] avatar donjpierce avatar jcorrado76 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

traffic's Issues

Performance

Simulating even a small number of cars (~30) requires too many calculations per time step. Adding traffic lights also increased simulation time. Simulating ~20 second flows takes about an hour.

Fixing this starts with optimizing how cars search for their obstacles. The present, inefficient schema is to determine if there are any obstacles in the car's field of view by looking through a list of all of the cars in the system and comparing their locations to the linspace in the field of view. A similar schema is used for finding red traffic lights. This is monumentally poor design. A more correct framework is for all cars in the system to be sorted by their position. Then each car can look for obstacles by only needing to consider a small subset of the total number of cars. Which subset is determined by the car's position and how the list is sorted.

Other performance issues could potentially be resolved by simply de-cluttering. There is probably excess data being stored that need not be stored, such as in unnecessary usage of indexed loops and indexed boolean statements. Also in the future of this base is to use data frames instead of lists and dictionaries.

All cars randomly stop simultaneously

Specifically when using sim.init_random_node_start_location() there is the problem of all cars simultaneously stopping in their tracks at around ~3.400 update iterations. This stoppage issue never occurs with sim.ini_culdesac_start_location().

Source of bug unknown.

Update 06/21/20:
Now this only happens with sim.init_culdesac_start_location() and not with the random node init.

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.