Virtual Guns with Swarm Targeting?
I thought that Diamond is also using virtual guns in melee (for he is using DisplacementVector in melee for his ASGun, while using GF in 1v1). But the code shows that the VGs is only used when there is only one opponent.
I've been long thinking about melee virtual guns, as nowadays, melee wave surfing is growing in popularity. However, the first difficulty to solve is to make VGs work with Targeting.
Here are the choices I've came up with:
- Keep track of VG ratings for each opponent, and aim with the best gun respectively. Then combine the results as if they were from the same gun, not very different guns. The problem is that swarm targeting may not work properly when internal data from two quite different guns is combined.
- Keep track of an overall rating, considering every opponent. However this method doesn't scale well when the opponents changes, e.g. going from 3 bots melee to 2 bots duel, the rating will remain irrelevant for a while.
- Keep track of VG ratings for each opponent, but aim with the same gun for every opponent (for better swarm targeting). The gun used to aim is chosen so that the overall hit-rate is maxed. This should be the most versatile approach, but not easy to implement.
Any thoughts here?
I think the best would be having individual guns, and using leave-one-out cross validation to test which gun actually gives better results on the historical data at fire time. This would skip needing to track separate hitrates for guns that you don't know where they would fire.
If I understand correctly, for n firing waves w = {w1..wn}, LOOCV involves training the gun with w - {wi}, then test with wi, for all i. For knn guns, this means doing n “(k+1)nn” searches (then exclude wi from result), and for neural networks, this means feeding the network n(n-1) waves in total. Isn’t that costly for robocode? Or may there be some faster ways?
For KNN I think this is fine. I know personally I use a very fast kernel density function (square), so these kind of tests aren't expensive. That said, I haven't tried this technique yet. It might not work well due to other things we haven't spoken of yet.
Agreed though for NN, it is already pushing the limit of what can be processed in a single tick, so there is no way you can take 2x or 3x the processing power.
Medina currently implements the third approach, but it only uses a HOT and a PIF gun, which implies in no improvement, but is meant to be a place to work on in the future. It uses different ratings depending on the number of enemies alive.
You do not have permission to edit this page, for the following reasons:
You can view and copy the source of this page.
Return to Thread:Talk:Virtual Guns/Virtual Gun with Swarm Targeting?/reply (5).
Well, I see many bots treating disabled bots differently, and that’s not hard to be implemented with swarm targeting.
While PIF guns play a dominant role in melee, similar to 1v1, there are two types of PIF guns, one tuned to hit the majarity, the other tuned to hit adaptive movement.
Although there are not so many adpative bots in melee comparing to 1v1, they still contribute more score diff per bot than those you can easily hit. So if we were able to hit adaptive movement better, in melee, the score improvements should be noticeable.
Also melee adaptive movement is growing in popularity — virtual guns with swarm targeting will one day be an essential part of state-the-art bot.
Combat uses oldskool GF with swarm targeting in melee.
Uses a disabled dimension to account for disabled bots. And uses data decay to account for adaptive movement.
I am thinking about implementation of hit rate time derivative metric against adaptive bots. What I see that at the beginning the circular gun is quite good against plenty of good and even top bots. But then it contaminates hit stats, i.e. adaptive bots are not hit by the circular gun anymore but other guns still have low but steadily improving hit rates.
Hit rates can be compared only among the last N tics, which would somewhat mitigates this. But it has no predictive power to see the gun which would be the best in the next round.