There are many architectures used in deep learning - you can check out a few here. For AI Arena, we focus on feedforward neural networks. In general they have fewer parameters than convolutional neural networks (CNNs) or recurrent neural networks (RNNs).
We performed feature engineering to reduce the size of the network needed to train a good policy. Below we outline all of the features groups in the advanced configuration and the features that are contained within those groups.
Feature Groups
‣
- Description: There are 16 rays that get projected out from your fighter to identify platforms around it. If a ray intersects then it will calculate a score between 0 and 1 depending on how close it is to your fighter. A value of 1 means it’s overlapping your fighter and a value of 0 means it’s at the other end of the map. If a ray does not intersect then it gets a value of 0.
- Range: [0, 1]
‣
- Description: There are 16 rays that get projected out from your fighter to identify platforms around it. If a ray intersects then it will get assigned a value depending on the type of platform that it intersects with. If a ray does not intersect then it gets a value of -1.
- Hard Platform and Wall: 1
- Soft Platform: 0.5
- Ledge: 1.5
- Range: {-1, 0.5, 1, 1.5}
‣
- Description: There are 16 rays that get projected out from your fighter to identify projectiles around it. If a ray intersects then it will calculate a score between 0 and 1 depending on how close it is to your fighter. A value of 1 means it’s hitting your fighter and a value of 0 means it’s at the other end of the map. If a ray does not intersect then it gets a value of 0.
- Range: [0, 1]
‣
- Description: There are 16 rays that get projected out from your fighter to identify projectiles around it. If a ray intersects then it will calculate a score between 0 and 1 depending on if it’s travelling towards your fighter or not. If the projectile is heading in your direction then the value will be close to 1. If it is travelling in the opposite direction then it will get a score of 0. This value then gets multiplied by -1 if it’s your opponent’s projectile and 1 if it’s your fighter’s projectile. If a ray does not intersect then it gets a value of 0.
- Range: [-1, 1]
‣
- Description: There are 16 rays that get projected out from your fighter to identify projectiles around it. If a ray intersects then it will get a value of 1, 0, or -1 depending on the projectile’s elemental advantage (relative to your fighter). To learn more about what this means, refer to the “Elemental Advantage” feature group below. If a ray does not intersect then it gets a value of 0.
- Range: {-1, 0, 1}
‣
- Description: Binary encoding of your action and your opponent’s action. This tells the AI what it is currently doing and what the opponent is doing. The encoding comprises of three parts:
- Direction being pressed
- Action being done (jump, shield, grab, attack, or special)
- Whether the fighter is in a vulnerable state (i.e. hitstun)
- Range: [0, 1]
‣
- Description: Your position on the map. This includes both the X and Y position, rescale between -1 and 1. For the x-axis, a -1 means it’s all the way to the left and a value of 1 means it’s all the way to the right. For the y-axis, a -1 means it’s all the way to the top and a value of 1 means it’s all the way to the bottom.
- Range: [-1, 1]
‣
- Description: The opponent’s position on the map. This includes both the X and Y position, rescale between -1 and 1. For the x-axis, a -1 means it’s all the way to the left and a value of 1 means it’s all the way to the right. For the y-axis, a -1 means it’s all the way to the top and a value of 1 means it’s all the way to the bottom.
- Range: [-1, 1]
‣
- Description: The direction of your fighter and your opponent. A value of 1 means the fighter is facing towards the right and a value of -1 means the fighter is facing towards the left.
- Range: {-1, 1}
‣
- Description: The distance between your fighter and your opponent. We then scale down the distance to be between 0 and 1. The larger the value, the farther away the opponent is.
- Range: [0, 1]
‣
- Description: Angle between your fighter and your opponent. This feature informs your AI whether you’re to the left, right, above, or below the opponent. We use two features to solve the problem of discontinuity with a single value for the angle. We use the sin and cos of the radian.
- Range: [-1, 1]
‣
- Description: The amount of stocks remaining for your fighter and your opponent. The value is divided by 3, which keeps the range between 0 and 1.
- Range: [0, 1]
‣
- Description: The amount of percentage damage for your fighter and your opponent. The percentage is divided by 200. Most value should be between 0 and 1.5, but can get as high as 3 if someone’s percentage goes up to 600%.
- Range: [0, 3]
‣
- Description: The value of the elemental gauge for your fighter and your opponent. A value of 1 means that it is full and the special is ready to use.
- Range: [0, 1]
‣
- Description: If your fighter has an elemental advantage then this value will be 1. If it is at an elemental disadvantage then it will have a value of -1. Otherwise, the value is 0. The advantages work as follows:
- Fire > Electric
- Electric > Water
- Water > Fire
- Range: {-1, 0, 1}
‣
- Description: Your fighter’s weight minus the opponent’s weight, then rescaled to be within the range below. A value of -1 means your fighter is the lightest weight and your opponent is the heaviest. A value of 1 means your fighter is the heaviest weight and your opponent is the lightest. Anything in between is a linear interpolation.
- Range: [-1, 1]
‣
- Description: Binary encoding of whether you and/or your opponent is in the death state. This is the state where you are being teleported back to stage after you die.
- Range: [0, 1]
‣
- Description: How much of the state’s animation has been completed. For states that loop forever (such as idle and falling), the value gets defaulted to -1. For all other states that have a beginning and an ending, the value ranges from 0 (the start of the state) to 1 (the end of the state). This can inform your AI whether it is able to cancel out of a move, whether the opponent is in end lag, or even when its within range of a hitbox.
- Range: [-1, 1]
‣
- Description: How much health your fighter and your opponent have remaining in their shields.
- Range: [0, 1]
‣
- Description: Binary encoding of how many recoveries your fighter and your opponent have remaining.
- Range: [0, 1]
‣
- Description: How much time is remaining in the match. A value of 1 means the match just started, and a value of 0 means it just ended.
- Range: [0, 1]