Bahia2D – Team Description
Marco A. C. Simões, Helder Guimarães Aragão, Victor Souza, Simon Viegas, Hugo da Luz Silva, Jessica Meyer
Computer Architecture and Operating Systems Group(ACSO), State University of Bahia (UNEB), Rua Silveira Martins, 2555, Cabula. Salvador – BA – Brazil; Intelligent Computing Research Group(GPCI), University Center of Bahia (FIB), Rua Xingu, nº. 179, Jardim Atalaia/STIEP. Salvador – BA – Brazil
Abstract This paper presents the initial research from Bahia Robotics Team. This is a new research group created to investigate the application of artificial intelligence methods in the standard problem of robotics soccer. In this work, fuzzy controllers are used to improve some abilities of the players. In the case of the attackers, the kick and the positioning ability were improved. The midfielders had their positioning and passing ability improved. The goalkeeper and the defenders had their positioning ability improved. The generated Bahia2D soccer team was tested in matches against some victorious teams from Robocup Brazil Open 2006 and from previous editions of the Robocup World Competition, validating that fuzzy controllers are a good solution for the robotics soccer. The positive results achieved and the ongoing works to improve the current limitations are also presented.
1. Introduction
The Bahia2D team is entering into its first year of competition. It has been developed by Bahia Robotics Team(BRT) consortium since the second semester of 2006. BRT represents the union of the Computer Architecture and Operating Systems Group(ACSO) and the Intelligent Computing Research Group(GPCI), in order to investigate the application of artificial intelligence methods to autonomous robots, as proposed by Robocup international research initiative.
At this moment, BRT is working on the development of a team for the 2D Soccer Simulation League. Our goal is to develop fuzzy controllers for specialized agents in the positions: goalkeeper, center defender, wing defender, defensive midfielder, offensive midfielder and attacker. As a first work, the focus is only at kicking, passing, positioning and decision taking abilities at the controllers. At this stage, the Bahia2D team is composed by reactive agents. Our study is not worried about environment modeling details. For this reason, a base team to treat environment modeling and communication details was chosen. The UvA Base source code is used as base team, it was chosen because of its availability, quality of its world model and good abstract interface to send commands to simulator.
The first problem handled was the attacker ability to kick to opponent goal. In the base code, there were no analysis of the opponent's goalkeeper position and kicker position. Fuzzy logic was used to deal with these variables. The second problem was the attackers positioning because these agents frequently became in offside position. To make it easier for attackers to receive the ball without staying in offside position, the base world model and fuzzy logic were used. Based on the experience with these two problems, solutions for the positioning of the other players were also proposed. The last focused problem was the decision taking. Players with ball possession, can decide whether to kick to opponent goal, to pass the ball to the best positioned teammate, or to keep the ball. Defenders area slightly different because when they can't pass, they always clear the ball. Solutions to deal with this decision taking problem are presented.
The next section describes the motivation to use fuzzy logic to deal with these problems. Section 3 describes our fuzzy models and solutions for each problem. And at last, section 4 presents the conclusions and future works.
2. Motivation to use Fuzzy Logic for Bahia2D Agents
Zadeh proposed Fuzzy Logic in 1965 to represent uncertain and imprecise knowledge [11]. Fuzzy Sets Theory is a way to specify how much an object satisfies a vacant description [9]. Fuzzy logic strengths come from its capacity to derive conclusions and answers based on vacant, ambiguous, incomplete and imprecise information [4].
Linguistic variables compose the Fuzzy sets with qualitative and quantitative values. Linguistic terms represent qualitative values that are translated to quantitative values by a belonging function [6]. Using these linguistic variables as inputs it is possible to build a rule base composed by rules like If
UvA Base code offers a world model that gets low level data from a simulator and translates it into high level information. However, this information still is precise. Reasoning over imprecise information is common in many robotic soccer problems. For example, an agent who will kick the ball to the opponent goal must decide whether to kick at the left, at the center or at the right of goal. If the goalkeeper is on the left and the agent is on the left too, it should kick at the center or at the right. If goalkeeper's position is 6 or 6.5, for example, he certainly is on the left. But, if his position is 5 or 4.5 he is partially on the left and partially on the center. This example illustrates the imprecise nature of information that the agent deals to decide where to kick.
Other problems focused in this paper, described shortly in section 1, have the same imprecise nature of information. For this reason, fuzzy logic has been used to model all imprecise information in linguistic terms and to build rule bases for controllers specialized for each player. Some rule bases are shared with more than one player type. For example, the kick ability must be shared between attackers and offensive midfielders' agents.
These arguments are the base of the motivation to use fuzzy controllers for the construction of this first version of Bahia2D team. The rest of this paper shows how we use it to develop our team intelligence and its results.
3. Fuzzy Controllers for Robotic Soccer Agents
This section describes the first fuzzy models built from scratch by BRT. After some tests, it was decided to use the 4-3-3 offensive formation. When this formation is used, Bahia2D gets its best results. Hence, Bahia2D has one goalkeeper, two wing defenders, two central defenders, one defensive central midfielder, two offensive wing midfielders, two wing attackers, and one central attacker.
For positioning controllers, it was used the suggestions illustrated on Table 1 at the lines home_x, home_y, min_x, and max_x. The positioning controller of the base team is based on attraction zones, with the fuzzy controllers we are improving the players positioning by using differentiated attraction rules. The next subsections describes the fuzzy models used by Bahia2D first version team to accomplish this task, as to improve some other players' skills.
Table 1. Complete specification of the 4-3-3 formation used by UvA Trilearn. The player type numbers (pl_type) denote the following types: 1-goalkeeper, 2-central defender, 3-wing defender, 4-central midfielder, 5-wing midfielder, 6-wing attacker, and 7-central attacker.
| Number in Formation | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | 2 | 3 | 4 | - 5 | - 6 | 7 | - 8 | 9 | 10 | . 11 | |
| $home_x$ | -50.0 | -13.0 | -14.0 | -14.0 | -13.0 | -5.0 | 0.0 | 0:0 | 15.0 | 18.0 | 18.0 |
| home_y | 0.0 | 16.0 | 5.0 | -5.0 | -16.0 | 0.5 | 11.0 | -11.0 | -0.5 | 20.0 | -20.0 |
| pl_type | 1 | 3 | 2 | 2 | 3 | 4 | 5 | 5 | 7 | 6 | 6 |
| attr_x | 0.1 | 0.6 | 0.6 | 0.6 | 0.6 | 0.6 | 0.6 | 0.6 | 0.6 | 0.5 | 0.5 |
| attr_y | 0.1 | 0.35 | 0.25 | 0.25 | 0.35 | 0.25 | 0.3 | 0.3 | 0.2 | 0.25 | 0.25 |
| beh ball | 1 | -0 | 1 | 1 | -0 | 0 | .0 | .0 | - 0 | - 0 | - 0 |
| min_x | 50.5 | 45.0 | 45.0 | -45.0 | -45.0 | 30.0 | 30.0 | 30.0 | 2.0 | 2.0 | 2.0 |
| max_x | 30.0 | 35.0 | 0.0 | 0.0 | 35.0 | 42.0 | 42.0 | 42.0 | 40.0 | 42.0 | 42.0 |
3.1 Controller for Kick Positioning
The main objective of this fuzzy controller is to find the position in the opponent goal to kick with the best chances to score. To decide where to kick, the agent will take in consideration the opponent goalkeeper position and his own position. The output variable is kickPosition, it has values between -7.0 and 7.0, which represents the y-coordinates of the opponent goal. The x-coordinate is the field limit, the same as the goal line, it will always be 52.5. Figure 1 represents the linguistic terms used for this variable during fuzzy reasoning process.
Input variables for this controller are goalkeeperPosition and kickerPosition. They also refers only to the y-coordinates, Figure 2 illustrates its linguistic terms. The min and max values ranges from -7,0 to 7,0 respectively.
The rule base for this controller was created using the combination of the input variables; it intends to find a position at the goal the farthest from the goalkeeper and the closest to the kicker as possible. At first, only the three attackers used this controller. Then, the offensive midfielders stated using it as well, when they are in a good position to kick to the goal.
3.2 Controller for Scoring Possibility Evaluation
This fuzzy controller has the objective to evaluate the success of a kick to the goal. The output of this controller is the variable Kick Possibility, which varies from 0 to 10. It has the following terms: Low (0 to 3.75), Average (3.75 to 7.5), High (7.5 to 10).
The agent make the decision whether to kick to the goal or not, based on the goal angle, his distance to the goal, and the number of opponents near the goal.
The goal angle varies from -180° to 180°. This definition is also used in the UvA Base, in which the 0° is in front of the agent. It is divided into: Bad Angle – negative (-180.0 to -90.0), Bad Angle – positive (90.0 to 180.0), Best Angle (-45.0 to 45.0), Good Angle – negative (-90.0 to -75.0), Good Angle – positive (75.0 to 90.0).
The distance from the goal varies from 0 to 67m, and it is based in the distance between two points: (0,-34) to (52.5,7) or (0,34) to (52.5,-7). That is the distance the attackers run and have to decide whether or not to kick to the goal. It has the following linguistic terms: Close (0.0 to 35.125), Average (35.125 to 50.25), Far (50.25 to 67.0).
The number of opponents near the goal that are in the triangle formed between the agent and the goal varies from 0 to 11. It has the following linguistic terms: Few (0 to 3), Average (3 to 6), Many (6 to 11).
When this controller informs that there is a low chance of scoring, it calls the Controller for Passing Possibility Evaluation for all the near teammates, except for the goalkeeper. This controller is being used by wing defenders, midfielders and attackers.
3.3 Controller for Passing Possibility Evaluation
This fuzzy controller has the objective to evaluate the success of a pass to a specific player. The output of this controller is the variable Pass Possibility, which varies from 0 to 10. It has the following terms: Low (0 to 3.75), Average (3.75 to 7.5), High (7.5 to 10).
The agent makes his decision based on his perception of the teammate that he intends to pass. It considers the distance to the teammate, the number of opponents near the teammate, and the position of the teammate.
The distance to the teammate varies from 0 to 30m. It has the following linguistic terms: Close (0.0 to 14.25), Average (14.25 to 25.5), Far (25.5 to 30.0).
The number of opponents in a range of 2 meters from the teammate varies from 0 to 11. It has the following linguistic terms: Few (0 to 3), Average (3 to 6), Many (6 to 11).
The teammate position in relation to the agent is calculated by posTeammate - posAgent. The result indicates if the teammate is before, at the same line, or after the agent. It varies from -30 to 30 and it has the following linguistic terms: Before (-30 to 0), Equal (0), After (0 to 30).
When this controller informs that there is a low possibility to a successful pass, the agent carries the ball. For this, it just takes the agent to dribble with 0° angle, because, no matter what position the agent is in the field, he will turn to the front and kick the ball near his body. All agents, except goalkeeper, are using this controller.
3.4 Controller for Attacker Positioning Without Ball
The objective of this fuzzy controller is to allow the attackers, without ball, to find a position in the opponent's field, based on his own position, on the offside line and on the ball position. There was used a field division approach adapted from Boer and Kok[1], where the opponent's field is divided into 9 zones. Figure 3 represents this division.
The XFuzzy tool allowed the modeling of two position controllers: one for the x-axis and the other for the y-axis. These two controllers were integrated into a system with two independent rule bases. This division made the rule creation easier, and there was no interference in the expected results, due the lack of connection between the input variables of the x-axis and the output variables of the y-axis, and viceversa. This way, the system functions as a single controller with five inputs and two outputs.
The output variables used by the controller are the x-axis position and y-axis position, which represent the final positions that the agents should go to. Figure 4 shows the linguistic terms used for the x-axis variables. Figure 2 shows the ones for the y-axis, within the range -34 to 34. The input variables are the player position, the ball position and the offside position on the x-axis.
The rules for this controller were created in a way that the agent could only move to adjacent quadrants. The movement occurs in shorts distances, because in each cycle the perceptions can change and so the direction that the agent should move. For example, an agents positioned at the 8 th quadrant can only move to the 4, 5, 6, 7, 8 or 9th quadrant, because he can't make to the 1, 2 nor 3rd quadrant within the next cycle. This was defined by creating rules that have the same values for inputs, but different outputs and weights. The rules that make the agent stay at his quadrant, when the ball is at another, have lower weights, making him always move into the ball direction.
3.5 Controller for Offensive Wing Midfielders Decision Taking
The original objective of the fuzzy controller for the offensive wing midfielders was to decide what he should do when in ball possession. The attacker should make a decision analyzing his global position, the distance to the closest opponent, the distance from the closest teammate to the opponent goal, the number of opponents near the closest teammate, and his distance to this teammate. The output variable is a value, and depending on its range, a decision to kick, dribble, pass, pass through or conduct is made. The domain of the output variable varies between 0 and 5, and each range represents a decision.
Figure 2, 5 and 6 represents the linguistic terms used for the x-axis and y-axis variables, as for the variable of the number of opponents. Figure 7 represents the linguistic terms used for the variables distance from agent to closest opponent, distance from agent to the goal, distance from the closest teammate to the goal and distance from agent to closest teammate. Figure 8 illustrates the domain of the output variable that represents the offensive wing midfielders' decision taking.
The rules for the controller were created from the combination of the input variables, always aiming to decrease the possibility of losing the ball and to increase the chances of scoring.
Unfortunately, the results of this modeling were not the ones expected, so these controllers will not be incorporated to the team until further researches. Our current team version uses no specific fuzzy controller for the offensive midfielders, only the ones applied for all the team players. The offensive midfielder fuzzy controllers are already being developed in order to include them in our team final version for the Robocup World Competition.
3.6 Controller for Defensive Center Midfielder Positioning
The defensive midfielder has a fuzzy controller, whose objective is to settle strategically the player in his actuation area, taking the ball and his own position in consideration. There were defined two rule bases: one for the x-axis and another for the y-axis.
The x-axis tactics is to move the player in the direction of the ball, its intensity depends on the ball and player global positions, that is, depending on the position of each object, the player will tend to get more, or less, close to the ball.
For the y-axis the movement occurs in a similar way as for the x-axis, but also taking the y-coordinate in consideration. Furthermore, the x-coordinate of the ball is added to the rule base and has an expressive weight over the final positioning decision. The farther the ball is from his field, the more the midfielder will tend to stay at the center, avoiding, then, unnecessary moves.
The defensive midfielder has not only the role of marking the opponent's player, but also to coordinate the team, acting as a support agent to the offensive midfielders and the attackers. The idea is to allow the agent to have different behaviors through fuzzy controllers.
The domain for the y-axis was defined between -40 and 0, as well as suggested at Table 1. However, when this model was implemented the agent's behavior was not the one desired, because the defensive midfielder has been positioned between the two center defenders. To correct this bad positioning, there was made an empirical adjustment of 15 meters to the right, modifying the domain within the range -30 to 15. For the x-coordinate variable, the presented linguistic terms in Figure 9 had been defined. For the y-axis the same terms of Figure 2 were used.
3.7 Controller for Wing Defenders Positioning
The objective of this fuzzy controller is to allow the wing defenders without ball to move along the defensive field laterals. The controller makes the wing defender always attracted to the ball. This way, when the ball goes to the opponent's field, the wing defender goes after it until almost half of the opponent's field. This behavior makes the wing defenders defend or attack, depending on the ball position.
The output variables used by the controller are the x-axis position and y-axis position, which represent the final position that the agents should go to. The x-axis variables have the following linguistic terms: Near (-45 to -15), Average (-15 to 15) and Far (15 to 45).
3.8 Controller for Central Defenders Positioning
The objective of this fuzzy controller is to allow the central defenders without ball to position themselves searching for the ball and staying at center of the defensive field. For this controller the y-axis was divided into two zones, LeftCenter and RightCenter, making him stay at the defensive center, leaving the laterals for the wing defenders.
The output variables used by the controller are the x-axis position and y-axis position, which represent the final position that the agents should go to. The x-axis variables have the following linguistic terms: Near (-45 to -28.125), Average (-28.125 to -11.25) and Far (-11.25 to 0). The y-axis variables have the following linguistic terms: Left (-34.0 to -19.428), LeftCenter (-19.428 to -4.85), Center (-4.85 to 9.71), RightCenter (9.71 to 24.28) and Right (24.28 to 34).
3.9 Controller for Goalkeeper Positioning
The goalkeeper moves to a certain position of the goal, as he notices that a player from another team is in a kickable distance from the goal. Depending on which direction comes the player and on his own position, the goalkeeper reacts according to a rule base defined with the XFuzzy, moving to a preestablished range of coordinates. In case the attacker is too close from the goal, he assumes a different pattern, more appropriated for the situation.
The PosGoalie and the PosPlayer are the input variables for the rule base Catch. According to these variables, the rule base provides an output variable called PosCatch, which is exactly the position that the goalkeeper should take to catch the ball.
After some tests, this model was considered incomplete, because it defines only the goalkeeper position into the y-axis. It lets the goalkeeper too ahead of the goal in situations when the ball comes from the lateral or fouls. Therefore, we developed also a controller for the x-axis. It makes the goalkeeper move closer of farther from the goal, according with the attacker current position. This way, the goalkeeper waits for the ball to approach in the most likable position of the goal.
As in the case of the offensive midfielder controller, the results of this modeling are still not the ones expected, these controllers will be incorporated to the team as soon as we solve the minor problems that are still occurring. It should certainly be ready for the Robocup World Competition.
The fuzzy controllers would allow to infer about the goalkeeper's best position to catch the ball. With the basic team, there is not enough intelligence to do it. With these new controllers, the goalkeeper will position himself better during the game, improving his performance and giving the team better results.
4. Conclusions and Future Work
We have performed several tests, through matches against victorious teams, to validate our results. They demonstrate that it is clearly possible to improve some abilities using fuzzy controllers.
As a first evaluation of the fuzzy controller for kicking, the results were considered positive. But there is strong evidence that it is necessary to develop a more sophisticated strategy using passes, for example, to win matches against higher level teams.
It should be noticed that pass quality of offensive midfielders, positioning of attackers and kicking quality were enhanced when compared to base team. It is clear that these abilities may be enhanced with future work in these controllers and some new controllers too.
Another important conclusion is that the pass quality is a fundamental ability to the entire team performance. The greatest difficulty of Bahia2D's players were to take the ball to its offensive field, because the defensive players don't have a good pass quality. After introduction of controller described in section 3.3, the passing quality were enhanced and the team now take the ball to its offensive more frequently.
Unfortunately, Bahia2D team still lacks a communication level in its agents that would make the players able to communicate to each other. This work will turn Bahia2D's agents in a complete multiagent system. Learning strategies should also be used to permit adaptation when faced to unexpected situations during the matches. A better strategy to deal with fouls is also desired in future works.
Currently, BRT is studying new enhancements in the pass quality as a priority task. To achieve this goal, we are improving the current fuzzy controllers and considering to use other methods such as, neural networks, reinforcement learning and evolutionary computing.
References
- BOER, Remco de, KOK, Jelle. The Incremental Development of a Synthetic Multi-Agent System: The UvA Trilearn 2001 Robotic Soccer Simulation Team. Amsterdam: Faculty of Science University of Amsterdam, Master Thesis. Amsterdam, Holland, 2002.
- COSTA, Augusto Loureiro da, JÚNIOR, Orivaldo Vieira Santana, SOUZA, João Paulo Rocha de, LINDER, Marcelo Santos. MecaTeam: Um sistema Multiagente para o futebol de robôs simulado baseado no Agente Autônomo Concorrente. ENRI - III Encontro de Robótica Inteligente, Campo Grande, Brazil, 2006.
- ENDERT, Holger. The Dainamite 2006 Team Description. Faculty of Electrical Engineering and Computer Science. Berlin, Germany, 2006.
- FABRI, José Augusto. Um Sistema Especialista Fuzzy Aplicado a Classificação de Arquiteturas de Computadores. Semana de Informática (SEMINFO) da Universidade Federal da Bahia realizado na Universidade Federal da Bahia (UFBA) – Salvador/Bahia/Brazil, Mai 9th to 12th, 2000. Available at: http://users.femanet.com.br/~fabri/trabcien.htm. Accessed in: Oct 20 th, 2006, 20:30.
- KOK, Jelle, VLASSIS, Nikos, GROEN, Frans. UvA Trilearn 2003 Team Description. Faculty of Science, University of Amsterdam, Amsterdam, Holland, 2003.
- ORTEGA, Neli Regina S. Application of Fuzzy Sets Theory to Biomedicine problems. PhD thesis. São Paulo University. São Paulo, Brazil, 2001.
- REIS, Luís Paulo. Coordenação em Sistemas Multi-Agente: Aplicações na Gestão Universitária e Futebol Robótico. Tese de PhD, FEUP - Faculdade de Engenharia da Universidade do Porto, Porto, Portugal, 2003.
- RIEDMILLER, Martin, GABEL, Thomas. Brainstormers 2D Team Description 2006. Universidade Osnabrück, Osnabrück, Germany, 2006.
- RUSSELL, Stuart, NORVIG, Peter. Inteligência Artificial: uma abordagem moderna. Ed. Campus, 2ª Edição. São Paulo, Brazil, 2003.
- SANDRI, Sandra, CORREA, Cláudio. Lógica Nebulosa. V Escola de Redes Neurais, ITA, São José dos Campos, Brazil, 1999.
- ZADEH, L. A. Fuzzy Sets Information and Control. University of California, Berkeley, California, United States, 1965.
- KYOGOKU, M. and TAKEUCHI, I. The Team Description of YowAI2005. University Ellectro-Communications, Tokyio, Japan, 2005.
- BASHIRI, H. RAFAIE-JOKANDAN, M., NOURI, A., MOKHTARI, A., JAFARI, N., FARAHMAND, F. RoboSina2006 Team Description, In Proceedings of the 10th International RoboCup Symposium (RoboCup'06),Bremen, Germany, July 2006.