Version 1.24 reached position #97 in the rumble.
The cornering and simple orbital movement have a bit of randomness mixed in, plus the bullet prediction/dodging code from Leon. The random orbit makes no attempt to predict or dodge.
Uses a single neural-network with
one hidden layer no hidden layers. The code still assumes a virtual gun array and is nicely pluggable so that I can test different combinations if I feel the need to go back to multiple guns.
Woah there! You sure got a crazy-good score against Shadow in TC2K7! I'd be really curious about what kind of inputs nodes are getting heavy strong weights in Gaff's targeting NN there. Congrats! -- Rednaxela
Thanks -- now I just have to improve the score against the other 9 bots! I haven't dumped the weights, so I'm not sure which inputs are key to hitting Shadow. The biggest improvement (based on the 50+ tests/tweaks since version 1.00) seems to be from limiting the GuessFactor range: unlike most other implementations I've read about on the wiki, Gaff always considers GF+1 = asin(8/bvel) but limits the output to where the enemy could actually move. So if the enemy can only reach -0.4 to +0.7 then it'll take the peak value in that range, even though the biggest peak might lie outside it.
The network is using distance, speed (absolute), lateral accel, advancing accel, ticks since velocity change, ticks since CCW/CW change and straight-line distance to the wall as inputs. All of them are split up into smaller feature ranges so there are 4-10 inputs for each of those variables. I'm playing around with splitting them up into even finer features right now. -- Darkcanuck
Hmm, that sounds like an interesting. So, based on the how you're looking for peaks and such, I presume you have multiple neural net output nodes arranged in a fashion similar to the bins in 'traditional' VisitCountStats? Overall, from what you describe of it, I'd say this net is set up and used in a way far more like 'traditional' segmented VCS than other NeuralTargeting that I've taken note of, due to how it sorts the inputs/outputs in to bins/buckets. Actually, I think this has inspired me to look into neural net approaches more, perhaps integrating it into DynamicClustering, by using it in the calculation of differences between situations to create a form of DynamicWeighting?. My previous neural experiments haven't went too great (neural pattern matching and neural situation-readjustment) but this weighting via neural nets might be more promising. In any case, I'm quite impressed and wish you and Gaff well. It would be nice to see some more Canadians bots ascend the ranks :) -- Rednaxela
Yep, there are 31 output nodes, each corresponding to a slice of the GF spectrum. I originally started with a single output node which gave the GF to aim at, but performance was pretty lousy. Neural nets are very strong in classification problems, so Gaff's targeting takes that approach instead. I've also tried using a net to do predictive pattern matching (see Leon) with decent results, but nowhere near good enough to hit surfers. There's probably a lot of room for improvement in the latter if I rearranged it as a classifier too.
If you're curious, add "debuglevel=2" (or was it 3?) to Gaff's properties file, turn on painting and you'll see the net's outputs graphed in real time at the bottom left of the screen. -- Darkcanuck
Ahh yes, "debuglevel=2" indeed, and quite pretty graphics. One thing I noticed with it facing RougeDC Gamma6, is that it's bullet prediction seems able to predict where RougeDC is firing to a degree I find somewhat bothersome, of course the gun in Gamma6 isn't meant for performing against adaptive movement anyways. Despite it's good prediction though it does seems hit it's own predictions of the bullet fairly often and may be something you might want to consider looking at making it more cautious of. You may already be aware of it, but it also looks like you sometimes miss detecting the enemy firing at all. That's a very interesting cornering movement you have there by the way, it seems quite good at forcing fairly close combat as well without needing to chase. -- Rednaxela
Nice work with Gaff, keep it up! Hitting Shadow well is like a lifetime goal of mine - up there with becoming an astronaut and climbing Mount Everest. =) So it's good to see someone making progress. Just as an FYI, Engineer also outputs an array of GuessFactor bins like this (and even uses the same type of setup for surfing!). Good luck with the other 9 reference bots ;), cheers, -- Voidious
By the way, out of curiosity, I ran a anti-surfer challenge I made for my own testing on Gaff. It appears it's power against Shadow doesn't hold true against Dookious, but in general isn't too bad against surfers. One interesting thing, is that it doesn't manage to hit the surfers I've found to be weaker like Komarious or MatchupWS much better than the stronger surfers.
|Gaff 1.04||Darkcanuck||63.52||80.64||69.22||82.22||78.13||74.74||54.37||70.19||74.43||66.33||88.37||81.53||82.08||83.99||75.02||16.0 seasons|
That's an ugly score against Dookius -- and I thought CC was hard to hit!
Good catch regarding the bullet dodging: one of the fixes I made in 1.04 broke the dodging code for reverse travel. Fixed now, just running through some more targeting iterations. Still stuck around 76 on the TC2K7, each new test brings up the score against 1 bot at the expense of the 9 others. Interestingly, smoothing the net outputs brought down the Shadow score quite a bit. Oh, and I did dump the network weights but it didn't reveal anything. That's the irony of NN, they can solve difficult problems but you can't reverse-engineer the solution. -- Darkcanuck
Well, I doubt anyone could score that great against Dookious. Actually, I find it slightly ironic that Voidious has a lifelong goal of hitting Shadow when Dookious appears to be much harder to hit. Perhaps I'll make it my lifelong goal to hit Dookious well... ;)
I think for NNs with few inputs one can create a visual map of what inputs result in what outputs, but that gets tricky when you have more than 2 or 3 input dimensions to deal with. If all one is looking at is "importance" of a dimension though, it might be possible to get a useful statistic by getting the maximum theoretical amount an output node could be affected by a single lone input node were all other input nodes 0, and average what that value was for all of the different output nodes, to get a rough comparative measure of how much the network "cares" about that input. Of course, I'm not an expert on NNs but to me that would make sense as a way to get at least marginally useful information out of a dump of the weights. -- Rednaxela
Are you offering to do the analysis for me? ;) With 45 inputs, 20 hidden nodes and 31 outputs, there are a lot of weights to pore over. Out of my last 20 tests (RoboResearch is an amazing tool) the targeting released in 1.04 is still the best. Too many variables to tweak: inputs, network size/structure, learning rates, training methods... just not enough processor time to try them all. Right now I'm trying to figure out how to build an AntiSurfer method but I'm not sure how to do fast rolling in a NN. Next test is experimenting with weight decay. Somewhere in there lies a way to hit Dookius better... -- Darkcanuck
Excellent! Rednaxela, you provided the key to the TC2k7 score breakthrough I was looking for. Mostly out of laziness (and probably due to the way Leon's NN works) I was only training the net once for each firing wave hit -- I already had the learning rate cranked up to compensate. By retraining the last 5 firing waves each time a new firing wave hit and dialing down the learning rate, Gaff scores almost 2pts higher overall. 9 out of the 10 bot scores are up, including a modest gain against Shadow (71.61). I'm playing with the retraining count and learning rate now to get an idea if there's more value still hidden in this approach. Look for a new release soon with a couple of new movement modes to increase survival against the big guys. -- Darkcanuck
Nice stuff there! Looks like Gaff will be on it's way up. Cheers! :) -- Rednaxela