public:t-622-arti-12-1:lab_1_-_agents
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| public:t-622-arti-12-1:lab_1_-_agents [2012/01/19 15:13] – stephan | public:t-622-arti-12-1:lab_1_-_agents [2024/04/29 13:33] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 18: | Line 18: | ||
| - Develop a model-based reflex agent that is able to clean every cell. Is it rational? | - Develop a model-based reflex agent that is able to clean every cell. Is it rational? | ||
| + | |||
| + | To make it a bit easier you can use the following assumptions: | ||
| + | * The room is rectangular. It has only 4 straight walls that meet at right angles. There are no obstacles in the room. That is, the strategy "Go until you bump into a wall then turn right and repeat" | ||
| + | * The room is fairly small, so that 100 actions are enough to visit every cell, suck all the dirt and return home given a halfway decent algorithm. | ||
| ===== Material ===== | ===== Material ===== | ||
| * {{: | * {{: | ||
| + | * {{: | ||
| The file contains code for implementing an agent in the src directory. The agent is actually a server process which listens on some port and waits for the real robot or a simulator to send a message. It will then reply with the next action the robot is supposed to execute. | The file contains code for implementing an agent in the src directory. The agent is actually a server process which listens on some port and waits for the real robot or a simulator to send a message. It will then reply with the next action the robot is supposed to execute. | ||
| Line 28: | Line 33: | ||
| - Setup the simulator as shown in this picture: | - Setup the simulator as shown in this picture: | ||
| {{: | {{: | ||
| + | - Run the " | ||
| + | The output of the agent should say " | ||
| + | - Now push the " | ||
| + | |||
| + | You can see [[http:// | ||
| + | |||
| + | [[http:// | ||
| ===== Hints ===== | ===== Hints ===== | ||
| For implementing your agent: | For implementing your agent: | ||
| * Add a new class that implements the " | * Add a new class that implements the " | ||
| - | * You have to implement the method " | + | * You have to implement the method " |
| * Before you start programming a complicated strategy, think about it. The things your agent has to do are: | * Before you start programming a complicated strategy, think about it. The things your agent has to do are: | ||
| - execute TURN_ON | - execute TURN_ON | ||
| Line 38: | Line 50: | ||
| - return to the initial location | - return to the initial location | ||
| - TURN_OFF | - TURN_OFF | ||
| + | * For this your agent needs an internal model of the world. Figure out, what you need to remember about the current state of the world. Ideally, you create an object " | ||
| + | |||
| + | As a last and general hint: "Days of programming can save you minutes of thinking." | ||
/var/www/cadia.ru.is/wiki/data/attic/public/t-622-arti-12-1/lab_1_-_agents.1326985981.txt.gz · Last modified: 2024/04/29 13:32 (external edit)