Genghis: One of the first robots controlled by subsumption architecture.
setup63to create a git repository for the lab. If you want to work alone do:
setup63 labs/07 noneIf you want to work with a partner, then one of you needs to run the following while the other one waits until it finishes.
setup63 labs/07 partnerUsernameOnce the script finishes, the other partner should run it on their account.
cd ~/cs63/labs/07 cp -r ~meeden/public/cs63/labs/07/* ./This will copy over the starting point files for this lab.
git add * git commit -m "lab7 start" git push
cd ~/cs63/labs/07 git pull
Begin by familiarizing yourself with pyrobot, a python library for experimenting with both physical and simulated robots. Go through the pyrobot overview. Start by invoking pyrobot and experiment with it using the command line. (You can skip the sections on the camera, gripper, and simulation devices since you won't be using these for this lab.)
Once you have familiarized yourself with the interface via the command line, edit the basicBrain.py file. Experiment with using this brain to control the robot. Modify the file in various ways, reload the brain in the robot, and retest it.
You will write a single subsumption-style brain that can find a light in the series of increasingly more difficult worlds shown below. These worlds are named:
The file findLight.py contains an example of how to implement a form of the subsumption architecture. It creates a set of layered behaviors which are then added to a brain in priority order (from lowest to highest). For each time step, the highest priority behavior that is triggered will control the robot. To test this file on the LightBehindWall world do:
pyrobot -s PyrobotSimulator -w LightBehindWall.py -r PyrobotRobot60000.py -b findLight.pyBe sure you understand how this example works before moving on to creating your own subsumption brain. An illustration of the subsumption framework, taken from one of Rodney Brooks' early papers, is shown below.
You will create your own subsumption-style controller in the file subsumption.py. You are welcome to use/modify the behaviors provided in the findLight.py file. In order to solve this problem you will need to add behaviors that push the robot to explore the world more effectively. Some options you may want to consider are:
Be sure to comment each of your behaviors. Your subsumption program should be able to find the light in all of the worlds depicted above, even if it may take awhile.
There are four additional worlds called Challenge1-Challenge4, on which you can test your subsumption controller. If your controller can consistently solve these, well done! I will demo some of the best student controllers in class.