Difference between revisions of "SimpleBot/Understanding SimpleBot"

From Robowiki
Jump to navigation Jump to search
m (fix)
(→‎Gun: more details)
Line 11: Line 11:
  
 
SimpleBot is using only one gun, which is a traditional kNN gun with gaussian kernel density. The attributes I use are BulletFlightTime, LateralVelocity, Acceleration, ForwardPreciseMEA, ReversePreciseMEA, TimeSinceDeceleration, and CurrentGuessFactor. Those attributes are the most useful attributes I've found in the past years, and they are also used by a lot of bots, etc. DrussGT, Gaff. Credit will give to [[User:Skilgannon|Skilgannon]] in his great [[DrussGT/Understanding DrussGT]], where I first see those attributes a few years ago.
 
SimpleBot is using only one gun, which is a traditional kNN gun with gaussian kernel density. The attributes I use are BulletFlightTime, LateralVelocity, Acceleration, ForwardPreciseMEA, ReversePreciseMEA, TimeSinceDeceleration, and CurrentGuessFactor. Those attributes are the most useful attributes I've found in the past years, and they are also used by a lot of bots, etc. DrussGT, Gaff. Credit will give to [[User:Skilgannon|Skilgannon]] in his great [[DrussGT/Understanding DrussGT]], where I first see those attributes a few years ago.
 +
 +
In kernel density (which affects the performance a lot) I use max overlay area, say, I extend every recorded GuessFactor to a GuessFactor range, based on bot width at current distance, then see where they overlap the most. This is different from DrussGT, as I don't record precise bot width at wave intersection (which may decrease performance, but it's simple ;)). I use these approach as it's faster than iterating through every pair of two GuessFactors. And it's closer to robocode physics as well.
 +
 +
To eliminate the effect of irrelevant situations, I use gaussian distribution as weights and give the most weights to those within the average distance of the cluster. Cluster size is simply sqrt(totalSize), as this will make my gun a statistical gun when there's not so much data (when I don't know its movement well), and a pattern matcher when there's enough data. Using gaussian distribution greatly helps these process as well, as the average distance would be great when there's not so much precise match, whereas the average distance will be tiny when the situation is already faced a lot of time.
 +
 +
Currently I don't use any manual decay, as with so many attributes, it's already hard for a new situation to be the same as an old situation (and newer situations are easier to match newer situations, if its movement is adaptive), which works like some hash algorithm.

Revision as of 18:00, 28 August 2017

SimpleBot Sub-pages:
SimpleBotVersion History - Understanding SimpleBot

SimpleBot is originally a bot created to test other bots, therefore everything is made as simple as possible. But soon I found myself in love with SimpleBot for its cleanness and simplicity. Then I decided to stay with SimpleBot, and always keep everything simple.

Gun

SimpleBot is using only one gun, which is a traditional kNN gun with gaussian kernel density. The attributes I use are BulletFlightTime, LateralVelocity, Acceleration, ForwardPreciseMEA, ReversePreciseMEA, TimeSinceDeceleration, and CurrentGuessFactor. Those attributes are the most useful attributes I've found in the past years, and they are also used by a lot of bots, etc. DrussGT, Gaff. Credit will give to Skilgannon in his great DrussGT/Understanding DrussGT, where I first see those attributes a few years ago.

In kernel density (which affects the performance a lot) I use max overlay area, say, I extend every recorded GuessFactor to a GuessFactor range, based on bot width at current distance, then see where they overlap the most. This is different from DrussGT, as I don't record precise bot width at wave intersection (which may decrease performance, but it's simple ;)). I use these approach as it's faster than iterating through every pair of two GuessFactors. And it's closer to robocode physics as well.

To eliminate the effect of irrelevant situations, I use gaussian distribution as weights and give the most weights to those within the average distance of the cluster. Cluster size is simply sqrt(totalSize), as this will make my gun a statistical gun when there's not so much data (when I don't know its movement well), and a pattern matcher when there's enough data. Using gaussian distribution greatly helps these process as well, as the average distance would be great when there's not so much precise match, whereas the average distance will be tiny when the situation is already faced a lot of time.

Currently I don't use any manual decay, as with so many attributes, it's already hard for a new situation to be the same as an old situation (and newer situations are easier to match newer situations, if its movement is adaptive), which works like some hash algorithm.