Talk:Portia
How many call to sin & cos do you do each tick? If it is below 10,000, that isn't a reason, or you think it is slow while in fact it isn't. Oh I see... you have a lot of small classes, which is obfuscated I think (no one name the class a,aa,ab,...) » Nat | Talk » 10:15, 12 July 2009 (UTC)
- Hey Nat, I've tested it, and its speed is about half the speed of Shadow. I believe I'm using about 700 trigonometry functions and 200 sqrts each tick, depending on the situation. If that's not it, I'm not sure what is. Maybe its the simulated bullets, I'll have a look for a next version. I've speed and size optimized the .jar, that's why you see the "a,aa,ab,...". --Positive 18:23, 12 July 2009 (UTC)
- Just curious, what program are you using for the speed and size optimizations? I'd be interested in trying it on DrussGT to see if it solves my skipped turn problems =) Also, one way to speed up your bot quite a bit is to only aim your gun for the 4 ticks before you fire, and the rest of the time just point your gun straight at the enemy's location. --Skilgannon 21:23, 12 July 2009 (UTC)
- I used ProGuard 4.3 for the optimization. Tell me what it does for Druss. :) Just aiming your gun for the opponent is a good idea, and Portia already does it. :) 22:11, 12 July 2009 (UTC)
- I just noticed, Portia doesn't do it for the solo gun. Adding it now. :) --Positive 21:54, 16 July 2009 (UTC)
By the way, I'd like to hear your opinion about Portia (if you've played with him). I think the meleemovement is quite different from most bots, and it seems to be doing great (6th in the meleerumble at the moment). --Positive 22:11, 12 July 2009 (UTC)
Congrats on a really awesome debut, dude! The rating will still fluctuate quite a bit until you hit full pairings and ~2,000 battles, but I bet it stays at 5th or 6th. I've been easing back into work on Diamond -- now I'm even more motivated. ;) --Voidious 22:36, 12 July 2009 (UTC)
- Thank you. :) I'm glad my bot poses a new challenge to you. :P For the solo part, I've already spent many hours trying to defeat Dookious as well. Not very successfull though, at least not after he activates that damn flattener. ;)
Hi there, welcome to Robocode. Thanks for making me run some melee battles again, great movement you got there, congrats. I'm even thinking about making my own melee bullet detector now... --ABC 23:47, 13 July 2009 (UTC)
- ABC, are you checking the wiki all the time and make no comment? PS. Sorry if I get Portuguese wrong, result from Google Translate » Nat | Talk » 12:44, 14 July 2009 (UTC)
- Not all the time, but I still check the wiki and the RR server frequently. My life has been a bit too busy to participate actively, though. Your Portuguese was correct, and I didn't forget the email you sent me, btw. :) --ABC 14:28, 14 July 2009 (UTC)
- Thank you. :) --Positive 19:43, 14 July 2009 (UTC)
DC Pattern Matching or DC Play-it Forward? If it is really DC-PM, I'm really interested on how it works. » Nat | Talk » 13:11, 3 August 2009 (UTC)
- What's the difference? --Positive 13:27, 3 August 2009 (UTC)
- Well, I'm guessing you just mean a DC / "Tron's Gun" style gun, which used to be called a "forward pattern matcher" and was once generally considered PM. But the consensus is that it really isn't pattern matching at all, so I think Nat is wondering if you're doing some new type of DC gun that also uses pattern matching. --Voidious 13:30, 3 August 2009 (UTC)
- Yes, I based the gun on TronsGun page. So I guess that makes it a forward pattern matcher. Portia 1.12 makes a "pattern" based on the opponents: displacement vectors for roughly the last 30 ticks, current velocity, acceleration, and other variables like distance to wall. It then stores that "pattern" 100 turns later in the KD-tree, with a reference to the turn it was recorded, if the opponent is still alive. :) --Positive 13:53, 3 August 2009 (UTC)
- What do you do with those 30 displacement vectors? Do you have like 35 dimensions in your tree, or is it something else? Great job with the new gun, looks like you might snag 3rd (knock on wood). --Voidious 14:12, 3 August 2009 (UTC)
- Thanks (quickly knocks on wood as well)! :) It calculates 3 displacement vectors over those 30 turns, and takes 1 heading difference and 3 displacements from them for dimensions. I don't think 35 dimensions would be very managable. :P --Positive 14:41, 3 August 2009 (UTC)
- Wow, really amazing! Huge congrats on 3rd place with 1.12 - and closing in on Aleph! --Voidious 00:44, 4 August 2009 (UTC)
- Thankyou. I didn't dare hope such a jump. :) It's pretty exciting how much you can do, and is still possible in melee. :) --Positive 11:04, 4 August 2009 (UTC)
You really are amazing me - congrats on overtaking Aleph for the #2 spot! If I were ABC, I might start getting a little scared. =) But Shadow still has a pretty incredible lead (3.83 was about 1% APS higher than 3.84) ... for now. Best of luck in your quest for the throne! Hope to catch up sometime. --Voidious 16:55, 11 August 2009 (UTC)
Big congrats from me too, great work. Don't stop now, you are going places! ;) --ABC 17:04, 11 August 2009 (UTC)
Very nice job man. I don't know if there are differences on the 1v1 code of versions 1.0 and 1.13, if there are you should enter version 1.13 in the 1v1 competition to compare it to Shadow, maybe there is a chance to boost Portia by turning seconds to firsts? Although looking at their battles, would make me think that you should be improving you gun, check the bullet damage difference between them. Good luck, and congrats again. --zyx 17:18, 11 August 2009 (UTC)
Oh my... very nice stuff here! I really need to finish my accursed melee bot and see if I can at least overtake Diamond. Hmm... I wonder what you would get if you combined Gaff's 1v1 gun, DrussGT's 1v1 movement, Portia's melee movement, and Shadow's melee gun... :) --Rednaxela 18:13, 11 August 2009 (UTC)
- In terms of Melee performance... probably something a lot like the current Shadow. :-) --Voidious 18:19, 11 August 2009 (UTC)
Thank you. :) I'm as amazed as you guys. Don't worry, I still have some more ideas. :) Turning more seconds into firsts would be great. The thing is that 1v1 in the meleerumble is a lot different from in the solorumble, so I think something special is needed for that. Right now I'm thinking about perhaps extending the bullet simulation for 1v1, to combine with the Stop 'n go. Would you recommend any quick 1v1-gun technique? --Positive 20:30, 11 August 2009 (UTC)
Congrats from me too! For one-on-one, I think you should take a look into Wave Surfing. I know it isn't fast, but it's fun! And perhaps DC-GF gun will help you too. » Nat | Talk » 23:28, 11 August 2009 (UTC)
- A DC-GF gun is certainly not needed. Diamond, and even more so Shadow, have quite strong 1v1 guns that are non-GF DC. Keeping it simple and not using a second gun for 1v1 would probably be a more sensible approach. I'd recommend keeping Portia with the same DC-PIF gun it has now, but simply improving it's 1v1 performance. I recommend experimenting with the dimensions that are used in the KD-Tree, as well as the number of nearest neighbors returned from that at a time. --Rednaxela 00:18, 12 August 2009 (UTC)
I don't think 1v1 performance is even that important in Melee. How much energy you take into the final duel is usually way more important. Some really solid HOT-avoidance is useful, but it sounds like you already have that.
Have you benchmarked your gun at all? You might try some Targeting Challenges if you really think there are lots of points there. I agree you don't need any specific technique, e.g. GuessFactors. Making every aspect of your data collection as accurate as possible is really important. Make sure all your attributes are working right, try different weights and attributes and cluster sizes. Try removing attributes that you "know" are good, but that you've never considered removing, try the exact opposite of what you think should work... =) Good luck.
--Voidious 00:52, 12 August 2009 (UTC)
You're right, the 1v1 code isn't so important in melee. However, I often see Portia lose against robots like Infinity and Griezel because Portia misses most shots. I really like the the idea of somehow using the main DC gun in 1v1, that'd solve the Infinity "problem". :) I haven't done any benchmarking, mainly because I often delete and rewrite entire parts, and the benchmarks would be lost. But I can see how in this case it might be smart. In any case, those definitely are some great tips. Thank you. :) --Positive 12:15, 12 August 2009 (UTC)
Okay I was just buzy with making some screenshots for the Portia page, when I realized it would be cooler to put up a video on youtube for it. Now I've seen some video's on youtube, but there isn't much info on the wiki. I'm thinking to put a description like "For more info about this free programming game, visit robowiki.net" and tag "robocode". I was wondering if you agree and/or have some recommendations? --Positive 22:00, 13 August 2009 (UTC)
- I think that would be very cool. I've searched YouTube for Robocode vids a few times so that I could show people what Robocode is like, and while there are some videos there, not too many are showing high level / modern bots. And that's fine, but slightly less impressive when trying to attract newcomers. =) --Voidious 22:10, 13 August 2009 (UTC)
- Exactly. :) If more people like to do something like this, we could put a wiki page up for it as well. Do you suggest any tags or description? --Positive 22:14, 13 August 2009 (UTC)
I'm not sure how much it is affecting performance (your MeleeRumble score still seems OK), but I'm seeing a NullPointerException for Portia 1.14 (on both my systems):
java.lang.NullPointerException at positive.bd.a(Unknown Source) at positive.bf.a(Unknown Source) at positive.bf.a(Unknown Source) at positive.Portia.onScannedRobot(Unknown Source) at robocode.ScannedRobotEvent.dispatch(ScannedRobotEvent.java:297) at robocode.Event$HiddenEventHelper.dispatch(Event.java:249) at net.sf.robocode.security.HiddenAccess.dispatch(HiddenAccess.java:195) at net.sf.robocode.host.events.EventManager.dispatch(EventManager.java:486) at net.sf.robocode.host.events.EventManager.processEvents(EventManager.java:459) at net.sf.robocode.host.proxies.BasicRobotProxy.executeImpl(BasicRobotProxy.java:403) at net.sf.robocode.host.proxies.BasicRobotProxy.execute(BasicRobotProxy.java:119) at robocode.AdvancedRobot.execute(AdvancedRobot.java:565) at positive.Portia.run(Unknown Source) at net.sf.robocode.host.proxies.HostingRobotProxy.run(HostingRobotProxy.java:250) at java.lang.Thread.run(Thread.java:619)
--Voidious 20:52, 15 August 2009 (UTC)
Hrm, how much of it are you seeing? --Positive 21:03, 15 August 2009 (UTC)
I saw it a few times each battle on my Linux RoboRumble client, so I ran one battle on my Mac and saw it a couple of times there too (to get the stack trace). Once was right as Portia won the round, the other wasn't (but maybe was right before/after a kill). --Voidious 21:06, 15 August 2009 (UTC)