From 8967edfb6c659864ffffacc519034927aeea2727 Mon Sep 17 00:00:00 2001 From: Toby Vincent Date: Fri, 3 Sep 2021 21:35:38 -0500 Subject: implemented cornersAgent and its heuristic Co-authored-by: Andreas1282 --- .vscode/launch.json | 70 ++++++++++++++++++++++++++++++++++++++++------------- 1 file changed, 53 insertions(+), 17 deletions(-) (limited to '.vscode') diff --git a/.vscode/launch.json b/.vscode/launch.json index 2c0f7aa..4788109 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -17,7 +17,6 @@ "program": "pacman.py", "args": [ "--frameTime=0.02", - "--catchExceptions", "--pacman=SearchAgent", "--agentArgs=fn=tinyMazeSearch", "--layout=${input:mazeLayout}", @@ -30,7 +29,6 @@ "program": "pacman.py", "args": [ "--frameTime=0.02", - "--catchExceptions", "--pacman=SearchAgent", "--agentArgs=fn=depthFirstSearch", "--layout=${input:mazeLayout}", @@ -43,7 +41,6 @@ "program": "pacman.py", "args": [ "--frameTime=0.02", - "--catchExceptions", "--pacman=SearchAgent", "--agentArgs=fn=breadthFirstSearch", "--layout=${input:mazeLayout}", @@ -56,39 +53,69 @@ "program": "pacman.py", "args": [ "--frameTime=0.02", - "--catchExceptions", "--pacman=SearchAgent", "--agentArgs=fn=uniformCostSearch", "--layout=${input:mazeLayout}", ] }, { - "name": "aStarSearch", + "name": "AStarSearch", "type": "python", "request": "launch", "program": "pacman.py", "args": [ "--frameTime=0.02", - "--catchExceptions", "--pacman=SearchAgent", "--agentArgs=fn=aStarSearch,heuristic=${input:heuristic}", "--layout=${input:mazeLayout}", ] + }, + { + "name": "UCSCorners", + "type": "python", + "request": "launch", + "program": "pacman.py", + "args": [ + "--frameTime=0.02", + "--pacman=SearchAgent", + "--agentArgs=fn=uniformCostSearch,prob=CornersProblem", + "--layout=${input:corners_mazeLayout}", + ] + }, + { + "name": "AStarCorners", + "type": "python", + "request": "launch", + "program": "pacman.py", + "args": [ + "--frameTime=0.02", + "--pacman=AStarCornersAgent", + "--layout=${input:corners_mazeLayout}", + ] + }, + { + "name": "AStarFoodSearchAgent", + "type": "python", + "request": "launch", + "program": "pacman.py", + "args": [ + "--frameTime=0.02", + "--pacman=AStarFoodSearchAgent", + "--layout=${input:corners_mazeLayout}", + ] } ], "inputs": [ { - "id": "searchAlgorithm", + "id": "mazeLayout", "type": "pickString", - "description": "Select the search algorithm", + "description": "Select the maze layout", "options": [ - "tinyMazeSearch", - "depthFirstSearch", - "breadthFirstSearch", - "uniformCostSearch", - "aStarSearch" + "tinyMaze", + "mediumMaze", + "bigMaze" ], - "default": "aStarSearch" + "default": "tinyMaze" }, { "id": "heuristic", @@ -97,11 +124,20 @@ "options": [ "nullHeuristic", "manhattanHeuristic", - "euclideanHeuristic", - "cornersHeuristic", - "foodHeuristic" + "euclideanHeuristic" ], "default": "nullHeuristic" + }, + { + "id": "corners_mazeLayout", + "type": "pickString", + "description": "Select the maze layout", + "options": [ + "tinyCorners", + "mediumCorners", + "bigCorners" + ], + "default": "tinyCorners" } ] } \ No newline at end of file -- cgit v1.2.3-70-g09d2