It is currently Sat May 10, 2025 11:37 pm

All times are UTC - 8 hours [ DST ]




Post new topic Reply to topic  [ 83 posts ]  Go to page Previous  1, 2, 3, 4, 5  Next
Author Message
Offline
 Post subject: Re: Ants
Post #41 Posted: Fri Nov 11, 2011 1:19 am 
Lives in gote
User avatar

Posts: 312
Liked others: 52
Was liked: 41
Rank: 7K KGS
KGS: tictac
still no submission from me... i am a bit stuck on combat. I should submit anyway to see the issues i got with my current code i guess.

But i found a nifty algo for exploring / harvesting:
I put a superlattice on the grid, each 10 square, and i treat my ants as particules on a hubbard model, and i move them by monte carlo :
a "move" means assigning one of the supersite as a goal for a given ant: it then go there by shortest path
i can direct them away from my hills byadding a long range repulsive potential (sort of like an anderson impurity model), and an on site repulsion to keep them spread out, i can also put an attractive potential near ennemy hills etc.. When a ant is idle, i just attach it to he nearest supersite and let it diffuse ,so new ants naturally starts to drift away from the hill.

: in the end the code is very simple,flexible and without corner case.

i cache all ancestor graph on each supersite so path computaion is cheap

My previous code was complicated and full of weird behavior in some edge cases.

Now back to combat :rambo: , monte carlo as lorill did sounds nice but i am not sure how to start. i ll stick to rul base for now i guess
i ll try to submit this WE

_________________
In theory, there is no difference between theory and practice. In practice, there is.

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #42 Posted: Fri Nov 11, 2011 4:54 am 
Gosei
User avatar

Posts: 1758
Liked others: 378
Was liked: 375
Rank: 4d
I just wanted to throw out there that I'm also working on this in between schoolwork. I don't have anything ready to submit yet, but it's getting there.

My profile (like I said, nothing to see yet): http://aichallenge.org/profile.php?user=7714

_________________
We don't know who we are; we don't know where we are.
Each of us woke up one moment and here we were in the darkness.
We're nameless things with no memory; no knowledge of what went before,
No understanding of what is now, no knowledge of what will be.

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #43 Posted: Fri Nov 11, 2011 9:24 am 
Gosei
User avatar

Posts: 2116
Location: Silicon Valley
Liked others: 152
Was liked: 330
Rank: 2d AGA
GD Posts: 1193
KGS: lavalamp
Tygem: imapenguin
IGS: lavalamp
OGS: daniel_the_smith
@perceval: Sounds cool!

@Dusk Eagle: Added you to my first post.

@everyone, Here's a cool image I made while writing my distance map making code.

_________________
That which can be destroyed by the truth should be.
--
My (sadly neglected, but not forgotten) project: http://dailyjoseki.com

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #44 Posted: Fri Nov 11, 2011 10:26 am 
Dies with sente

Posts: 92
Liked others: 48
Was liked: 6
This is me:

http://aichallenge.org/profile.php?user=2349

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #45 Posted: Fri Nov 11, 2011 12:40 pm 
Gosei
User avatar

Posts: 1758
Liked others: 378
Was liked: 375
Rank: 4d
Wow. Good job so far phrax! (Currently ranked 31st overall).

_________________
We don't know who we are; we don't know where we are.
Each of us woke up one moment and here we were in the darkness.
We're nameless things with no memory; no knowledge of what went before,
No understanding of what is now, no knowledge of what will be.

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #46 Posted: Fri Nov 11, 2011 1:26 pm 
Lives in gote
User avatar

Posts: 312
Liked others: 52
Was liked: 41
Rank: 7K KGS
KGS: tictac
Dusk Eagle wrote:
Wow. Good job so far phrax! (Currently ranked 31st overall).

indeed good job !

all good bots seems to have certain type of movment absent in weaker bots, a kind of jitter, and it involes much more small skirmishes 2vs 1 or 3 vs 1 that with weaker bots which typically rsuh toward the nearest hill; i must say that my bot does that for now :scratch:

_________________
In theory, there is no difference between theory and practice. In practice, there is.

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #47 Posted: Fri Nov 11, 2011 4:35 pm 
Dies with sente

Posts: 92
Liked others: 48
Was liked: 6
Thanks. I'm pretty psyched. Now if I can just figure out how to stop timing out without handicapping myself too much... I really hate these Mickey Mouse time-limits :)

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #48 Posted: Fri Nov 11, 2011 4:42 pm 
Gosei
User avatar

Posts: 2116
Location: Silicon Valley
Liked others: 152
Was liked: 330
Rank: 2d AGA
GD Posts: 1193
KGS: lavalamp
Tygem: imapenguin
IGS: lavalamp
OGS: daniel_the_smith
phrax wrote:
Thanks. I'm pretty psyched. Now if I can just figure out how to stop timing out without handicapping myself too much... I really hate these Mickey Mouse time-limits :)


Well, you can't blame your language! Good job, btw.

_________________
That which can be destroyed by the truth should be.
--
My (sadly neglected, but not forgotten) project: http://dailyjoseki.com

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #49 Posted: Fri Nov 11, 2011 4:48 pm 
Dies with sente

Posts: 92
Liked others: 48
Was liked: 6
daniel_the_smith wrote:
phrax wrote:
Thanks. I'm pretty psyched. Now if I can just figure out how to stop timing out without handicapping myself too much... I really hate these Mickey Mouse time-limits :)


Well, you can't blame your language! Good job, btw.


Heh, true. I'm more of a Perl guy. I had played with A* using Perl and the performance was awful (although that could've been me). It was at that point I realized I needed to get more raw; it seems to have worked out well for me so far.. Well, besides all the time I take tracking down memory issues now :)

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #50 Posted: Sat Nov 12, 2011 2:13 am 
Lives with ko

Posts: 281
Location: France
Liked others: 69
Was liked: 25
Rank: yes
phrax wrote:

nice :bow:

daniel> sorry for the last game ;)

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #51 Posted: Sat Nov 12, 2011 11:21 pm 
Beginner

Posts: 6
Liked others: 1
Was liked: 1
Rank: DGS 22k
KGS: jbergmark
I'm giving this a shot as well:

http://aichallenge.org/profile.php?user=8810

The bot above is in Ruby, but I think I've hit the limit of what I can do in Ruby given the time limits involved (#2 Ruby bot, so I don't think I'm alone in this regard). I've rewritten it in java, and its MUCH faster, but I hesitate to upload again and reset my ranking before I make some measurable improvements.

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #52 Posted: Mon Nov 14, 2011 3:40 pm 
Gosei
User avatar

Posts: 2116
Location: Silicon Valley
Liked others: 152
Was liked: 330
Rank: 2d AGA
GD Posts: 1193
KGS: lavalamp
Tygem: imapenguin
IGS: lavalamp
OGS: daniel_the_smith
Somehow my bot seems to have joined lorill and phrax in the top 100! #69 right now...

(It won't last, I just had an incredibly lucky win...)

_________________
That which can be destroyed by the truth should be.
--
My (sadly neglected, but not forgotten) project: http://dailyjoseki.com

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #53 Posted: Tue Nov 15, 2011 3:04 am 
Dies in gote

Posts: 32
Liked others: 10
Was liked: 1
Rank: KGS 1 dan
KGS: AVAVT
Gahh I think I'm at my wit's end with the things I know now. :scratch:
Really hope I can get my butt in the top 100 before the final tournament, but before that I must do something with my food gathering strategy... right now all that I'm employing can be described as: "OMG FOOD!!!!" :-?

Btw personally I don't... think the way most top players employing local combat and that movement are really that good. I don't even have nearly enough skill to make a bot like that, but I think if the Monte carlo simulation tells you to bounce back and forth in front of the enemy's hill for 500 turns when your force is 10 times their number, then you're doing something fundamentally wrong.
I myself saw a player in the top 20 employing kamikaze strategy and it worked well in the game I saw(sorry forgot who), and I think the reason xathis is currently 4 points above rank 2nd is because when his ants are overwhelming, he sometime just finish it.

Well that's just some bitching from a lowling though, I gotta get my a** into the top 100 to have any saying at all T_T

_________________
Image The similarity between Go and computing is the seemingly infinite number of possibilities.

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #54 Posted: Tue Nov 15, 2011 4:47 am 
Lives with ko

Posts: 281
Location: France
Liked others: 69
Was liked: 25
Rank: yes
daniel_the_smith wrote:
Somehow my bot seems to have joined lorill and phrax in the top 100! #69 right now...

(It won't last, I just had an incredibly lucky win...)

I went up to 18th, but it went back to a more reasonnable 33th for now.

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #55 Posted: Tue Nov 15, 2011 6:44 am 
Lives with ko
User avatar

Posts: 295
Location: Linz, Austria
Liked others: 21
Was liked: 44
Rank: EGF 4 kyu
GD Posts: 627
AVAVT wrote:
[...] bounce back and forth in front of the enemy's hill for 500 turns when your force is 10 times their number, then you're doing something fundamentally wrong.


Yes and no.

I have noticed that it is sometimes really possible to indefinitely block certain paths. That is, the defender can place a few ants in a way so the attacker can not make any progress. That is, every attacking ant that tries to enter the controlled zone immediately dies, but without killing any defender. In that kind of situation, where you are not even able to kill a single ant, it is irrelevant that you have 10 times as many forces.

But the problem lies elsewhere: In these situations, you don't really need 10 times as many forces to hold the line. That is, instead of trying to attack with a huge blob of ants, you could just accept that you can't break through, leave only a few ants there to hold the line, and use all other ants for something else (like searching for a back entrance).

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #56 Posted: Wed Nov 16, 2011 1:36 pm 
Beginner

Posts: 2
Liked others: 0
Was liked: 0
Rank: KGS 3 dan
KGS: saraneth
Wow, this is cool! Have a starter bot up, and think I will try to implement a Go-esque strategy (there seem to be obvious parodies for territory, influence, thickness etc).

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #57 Posted: Thu Nov 17, 2011 2:53 am 
Lives in gote
User avatar

Posts: 312
Liked others: 52
Was liked: 41
Rank: 7K KGS
KGS: tictac
i finally submitted something, i need input from some defeats to know where to improve . i might have been too cautions on time optimization:

i cache all ancestor graphs of all search i make, i restrict max depth of search etc.. in the end even with 200+ ants on a 200*200 map i run in less that 0.1 sec .. total pathfindinf time per turn is less than 10ms i goes to the point when the terrible input parsing of the java star package is noticeable ... and i was worried about java perf.

I could use extra time for more computation but computation of what ??
the game is also very different in maze vs more open map, i need to take that into account and alos balance exploring/food camping vs attacking. for now i send 80 % of my ants towards the nearest ennemy, its great to smash the starter bots but i expected issues against stronger ones :-? .

AVAVT wrote:
Gahh I think I'm at my wit's end with the things I know now. :scratch:
Really hope I can get my butt in the top 100 before the final tournament, but before that I must do something with my food gathering strategy... right now all that I'm employing can be described as: "OMG FOOD!!!!" :-?


does that mean that only the top 100 will be enterd in to the tournament at mif december ?

_________________
In theory, there is no difference between theory and practice. In practice, there is.

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #58 Posted: Thu Nov 17, 2011 7:36 am 
Gosei
User avatar

Posts: 2116
Location: Silicon Valley
Liked others: 152
Was liked: 330
Rank: 2d AGA
GD Posts: 1193
KGS: lavalamp
Tygem: imapenguin
IGS: lavalamp
OGS: daniel_the_smith
Perceval, the main server is a bit slow with the games. TCP servers are good if you want immediate feedback, e.g., http://ants.fluxid.pl --there's instructions up there...

Oh, and your bot looks pretty decent...

_________________
That which can be destroyed by the truth should be.
--
My (sadly neglected, but not forgotten) project: http://dailyjoseki.com

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #59 Posted: Thu Nov 17, 2011 2:00 pm 
Lives in gote
User avatar

Posts: 312
Liked others: 52
Was liked: 41
Rank: 7K KGS
KGS: tictac
daniel_the_smith wrote:
Perceval, the main server is a bit slow with the games. TCP servers are good if you want immediate feedback, e.g., http://ants.fluxid.pl --there's instructions up there...

Oh, and your bot looks pretty decent...

yeah thanks i need to try the tcp servers.
Yes my bot looks decent but obviously over aggresive and he plays too thin. I developped it against hunterbot after all and its strategy is to have its ant spreads as much as possible. Not so good when other bots knows what they do: my third game today is a good example; hopefully it will be easy to tweak.
Looking at the bots my current goal is to enter the top 200 or 300 but i don t think this version will make it

_________________
In theory, there is no difference between theory and practice. In practice, there is.

Top
 Profile  
 
Offline
 Post subject: Re: Ants
Post #60 Posted: Thu Nov 17, 2011 2:41 pm 
Gosei
User avatar

Posts: 2116
Location: Silicon Valley
Liked others: 152
Was liked: 330
Rank: 2d AGA
GD Posts: 1193
KGS: lavalamp
Tygem: imapenguin
IGS: lavalamp
OGS: daniel_the_smith
perceval wrote:
Looking at the bots my current goal is to enter the top 200 or 300 but i don t think this version will make it


I'm a little miffed that my current entry is better with its bugs than without. It got above 50 so I don't feel too bad that I can't beat it yet, though.

saraneth, good luck, added you to the first post...

Is anyone on 64 bit linux and interested in a binary exchange? (i.e., we trade binaries for local testing...)

_________________
That which can be destroyed by the truth should be.
--
My (sadly neglected, but not forgotten) project: http://dailyjoseki.com

Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 83 posts ]  Go to page Previous  1, 2, 3, 4, 5  Next

All times are UTC - 8 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group