Skip to content

Implementation of different search algorithms for the Pacman game.

Notifications You must be signed in to change notification settings

ChiragRadhakrishna43-7/Pacman

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

55 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pacman

Implementation of different search algorithms for the Pacman game.

Credit for the code goes to http://ai.berkeley.edu.
Attribution Information: The Pacman AI projects were developed at UC Berkeley.
# The core projects and autograders were primarily created by John DeNero (denero@cs.berkeley.edu) and Dan Klein (klein@cs.berkeley.edu).
# Student side autograding was added by Brad Miller, Nick Hay, and Pieter Abbeel (pabbeel@cs.berkeley.edu).

To run and play the Pacman Game, type the following command in the Anaconda terminal:

Python Pacman Game

To run the Python Pacman game, use the following command:

Click to reveal the command
python pacman.py

interactive

Two specific search algorithms implemented are:
1. Breadth First Search (BFS)
2. A Star Search (A*)

Breadth First Search

To run Breadth First Search (BFS) Algorithm, use the following commands:

python pacman.py -l mediumMaze -p SearchAgent -a fn=bfs
python pacman.py -l bigMaze -p SearchAgent -a fn=bfs -z .5

tiny_bfs

A Star (A*) Search

To run A* Algorithm, use the command below. By default, the heuristic function is nullHeuristic. You can set the heuristic function to manhattanHeuristic by specifying the heuristic parameter during run time.

python pacman.py -l bigMaze -z .5 -p SearchAgent -a fn=astar,heuristic=manhattanHeuristic

About

Implementation of different search algorithms for the Pacman game.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages