libkombilo  0.8
Public Member Functions | Data Fields
Algo_hash_full Class Reference

Hashing for full board patterns. More...

#include <algos.h>

Inheritance diagram for Algo_hash_full:
Algorithm

Public Member Functions

 Algo_hash_full (int bsize, SnapshotVector DATA, const string OS_DATA_NAME, int MAXNUMSTONES=50)
 
void initialize_process ()
 Called by GameList::start_processing.
 
void newgame_process (int game_id)
 Called when a new game is about to be GameList::process'ed.
 
void AB_process (int x, int y)
 Called during processing, for each AB SGF tag.
 
void AW_process (int x, int y)
 Called during processing, for each AW SGF tag.
 
void AE_process (int x, int y, char removed)
 Called during processing, for each AE SGF tag.
 
void endOfNode_process ()
 Called during processing, after fully processing a node (which might contain several AB, AW tags)
 
void move_process (Move m)
 Called during processing, for each move (B, W tags)
 
void pass_process ()
 Called during processing, for each pass.
 
void branchpoint_process ()
 Called during processing, for each node where a variation starts.
 
void endOfVariation_process ()
 Called during processing, when reaching the end of variation ("jump back to most recent branchpoint")
 
void endgame_process (bool commit=true)
 Called during processing, when the end of the game is reached.
 
void finalize_process ()
 Called by GameList::finalize_processing.
 
int search (PatternList &patternList, GameList &gl, SearchOptions &options)
 pattern search
 
void process_lfc (int x, int y, char color)
 
hashtype compute_hashkey (Pattern &pattern)
 
SnapshotVector get_data ()
 Extract the relevant data from file at Kombilo startup.
 
- Public Member Functions inherited from Algorithm
 Algorithm (int bsize)
 

Data Fields

int maxNumStones
 
int numStones
 
vector< pair< hashtype, int > > data
 
boost::unordered_multimap< hashtype, HashhitFdata_p
 
fstream os_data
 
- Data Fields inherited from Algorithm
int gid
 store the game id during processing
 
int boardsize
 board size
 

Detailed Description

Hashing for full board patterns.

Constructor & Destructor Documentation

Algo_hash_full::Algo_hash_full ( int  bsize,
SnapshotVector  DATA,
const string  OS_DATA_NAME,
int  MAXNUMSTONES = 50 
)

Basic notes:

For searches, data is used. It maps hashCodes to positions in the file os_data. At the specified position of the file, all game ids etc. where a position with this hashCode occurs are listed.

During processing, a multimap data_p is used which maps hashCodes to single hits. This data is written to os_data (together with the data previously available, if any) in get_data.


The documentation for this class was generated from the following files: