Group project for Assignment #1 of the AIFA course [AI61005].
- Chirahg Gupta [20ME30016]
- Saksham Kumar Singh [20EE10065] @photon999
- Saumyadip Nandy [20EC10072] @Pagol1
- Vibhanshu Vaibhav [20EE30030] @Vibhanshu2803
Our project implements the A* and Dijkstra algorithms with different hueristics.
The project uses concepts related to the AI problem of search to minimize the path cost.
- Python 3
- opencv-python
- numpy
- heapq
Clone the repository and run the command python3 Run.py
to execute.
The parameters in the config.json file can be changed to used to switch between algorithms, heuristics etc. The parameters are:
height
: Height of the mapwidth
: Width of the mapstart_pose
: Start coordinatesgoal_pose
: Goal coordinatesgenerate_random_map
:
@Values:- 0: Skip map generation and use pre-existing map
- 1: Generate a new random map
@Note: Must be set to 1 in the initial run
num_random_obstacles
: Maximum number of obstaclesrand_obstacle_size
: Maximum ostacle dimension (length or breadth)clearance
: Minimum obstacle distance from start and end nodestype
: Specifies the algorithm and hueristic to be used. In the format[Algorithm]-[Hueristic]
@Values:- Algorithms:
Astar
@Hueristics:Manhattan
,Chessboard
,Euclidean
andDiagonal
Dijkstra
@Hueristics:Manhattan
,Euclidean
(Used to calculate path cost)
@Example:Astar-Euclidean
- Algorithms:
valid_moves
:
@Values:- 4: Square movement
- 8: Octagonal movement
@Note: For Dijkstra use the Euclidean hueristic for octagonal movement
show_process
: Set to 1 to see the current path, frontier and explored nodes; set to 0 otherwise.
@Note: Enabling this option heavily increases the execution time.