Poker-AI.org

Poker AI and Botting Discussion Forum
It is currently Mon Nov 13, 2023 2:23 pm

All times are UTC




Post new topic Reply to topic  [ 5 posts ] 
Author Message
PostPosted: Fri Oct 04, 2013 10:56 am 
Offline
Junior Member

Joined: Wed Sep 04, 2013 6:05 pm
Posts: 47
Hi Guyz,

I just wondering on which type of structure do you store you gametree when you are using it ? vector, list, ?

I'm working with obecjts that have pointers to the 2 or 3 next nodes and 1 pointer to the previous node...

Regards,

MrNice


Top
 Profile  
 
PostPosted: Fri Oct 04, 2013 12:16 pm 
Offline
Site Admin
User avatar

Joined: Sun Feb 24, 2013 9:39 pm
Posts: 642
- Don't use vectors or lists as they generally quite slow.
- Use arrays instead.
- http://www.poker-ai.org/archive/www.pok ... ml?p=39384


Top
 Profile  
 
PostPosted: Mon Nov 04, 2013 6:37 pm 
Offline
Junior Member

Joined: Wed Sep 04, 2013 6:05 pm
Posts: 47
Hi Spears,

Thanks for your input.

Right now I see why I have to work with array :D

Just to save pointer on a data file it's a bit tricky :D


Top
 Profile  
 
PostPosted: Tue Nov 05, 2013 12:59 am 
Offline
Regular Member
User avatar

Joined: Sat May 25, 2013 7:36 am
Posts: 73
MrNice wrote:
Hi Guyz,

I just wondering on which type of structure do you store you gametree when you are using it ? vector, list, ?

I'm working with obecjts that have pointers to the 2 or 3 next nodes and 1 pointer to the previous node...

Regards,

MrNice


I am using the same approach. Each node-object keeps track of all of its childnodes in an array of pointers.
Just for curiosity: Why do you need the pointers to the parents?

Edit: To store the strategy I create two files: one index file containing the offsets to the frequencies of each node in the second (the actual strategy) file. Obviously you then need node-IDs for addressing the offsets in the index file.


Top
 Profile  
 
PostPosted: Thu Nov 14, 2013 1:42 pm 
Offline
Junior Member

Joined: Wed Sep 04, 2013 6:05 pm
Posts: 47
Hi Nose,


I'm using a pointer to the parent during the game tree creation phase...

MrNice


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC


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:
Powered by phpBB® Forum Software © phpBB Group