GithubHelp home page GithubHelp logo

best-route's Introduction

Best-route

A web-app for finding the shortest route between two location in Liễu Giai Ward, Ba Đình District, Hà Nội, Việt Nam.

About the project

This work is a team project offered in course IT3160-Introduction to Artificial Intelligence of Hanoi University of Science and Technology. We used A* algorithm for finding the shortest route between two random location that user chose in Liễu Giai Ward, Ba Đình District, Hà Nội, Việt Nam.

Built with

  • React
  • Flask
  • Python

Getting Started

Prerequisites

npm install npm@latest -g

Installation

  1. Clone the repository
  2. Install NPM packages
$ cd front_end
$ npm ci
  1. Create a Virtual environment
$ cd back_end
$ python3 -m venv .venv
  1. Install python libraries in Virtual environment
$ cd back_end
$ . .venv/bin/activate
$ pip install numpy
$ pip install pandas
$ pip install scikit-learn
$ pip install haversine

Usage

  1. Activate the Virtual environment
$ cd back_end
$ . .venv/bin/activate
$ python3 server.py
  1. Run the React scripts
$ cd front_end
$ npm start
  1. Choose start and destination location
  2. Hit FIND THE WAY button to request finding way
  3. Result may be shown as follow

Contributing

Contributors

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

License

Distributed under the MIT License. See LICENSE.txt for more information.

Contact

Nguyen Duc Tai - [email protected]

Project Link: https://github.com/ductaingn/Best-route/

Acknowledgement

Materials: https://vi.wikipedia.org/wiki/Gi%E1%BA%A3i_thu%E1%BA%ADt_t%C3%ACm_ki%E1%BA%BFm_A*

https://www.youtube.com/watch?v=A60q6dcoCjw&t=776s

best-route's People

Contributors

ductaingn avatar ducchanhust avatar tonystark2306 avatar

Stargazers

 avatar

Watchers

 avatar

Forkers

tonystark2306

best-route's Issues

Display walk way

Display the walk way from markers points to their nearest nodes in the color different from the route color

The position of the markers can be extracted from {route} list (i.e route[0], route[route.length-1])
The position of the neareast node to the markers can also be extracted from {route} list (i.e route[1], route[route.length-2])

File: front_end/Features/Map/MapComponent.jsx

Show map

Show interactive map in which user can chose points by mouse click then mark the points with pin point icons.
Return an array of selected points' coordinates.

Generate tests and test cases

Generate tests and test cases to test the accuracy of a_star.py.


Generate 5 test cases by hand in this form:

Input: start_point_coordinates, end_point_coordinate

Output: path={start_node_id, node_1_id,..., node_k_id, end_node_id}
Correct Output: path={start_node_id, node_1_id,..., node_k_id, end_node_id}

Generate 1000 random test cases, compare a_star.py result path with other programs on the internet. Show:

Accuracy:= (Number of same result)/1000

Wrong cases: If accuracy < 1, show cases that their results differ in 2 program:

case's input: start_point_coordinates, end_point_coordinate
case's output of a_star.py: path={start_node_id, node_1_id,..., node_k_id, end_node_id}
case's output of the other program: path={start_node_id, node_1_id,..., node_k_id, end_node_id}

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.