112 #include <boost/unordered_map.hpp> 134 virtual void AE_process(
int x,
int y,
char removed);
174 char* get_current_signature();
175 std::vector<int> search_signature(
char* sig);
178 boost::unordered_multimap<string, int> data;
219 hashtype get_current_fphash();
220 hashtype get_fphash(
int index);
226 std::vector<pair<int, char* > > data;
236 const int ENDOFNODE = 128;
237 const int BRANCHPOINT = 64;
238 const int ENDOFVARIATION = 32;
241 const int REMOVE = 128;
242 const int BLACK = 64;
243 const int WHITE = 32;
254 bool node_changes_relevant_region;
255 bool dictsFoundInitial;
258 std::vector<MoveNC> contList;
267 char dictsget(
char x,
char y);
268 void dictsset(
char x,
char y,
char d);
269 bool in_relevant_region(
char x,
char y);
270 char contlistgetX(
int i);
271 char contlistgetY(
int i);
272 char contlistgetCO(
int i);
275 class VecMC :
public std::vector<MovelistCand* > {
317 std::vector<char> movelist;
319 std::map<int, char* > data1;
320 std::map<int, char* > data2;
321 std::map<int, int> data1l;
339 HashhitF(
int GAMEID,
char ORIENTATION,
char* blob);
347 typedef vector<HashhitF* >* vpsip;
354 HashhitCS(
int GAMEID,
int POSITION,
bool CS);
361 std::vector<std::pair<hashtype, ExtendedMoveNumber> > * lfc;
398 void process_lfc(
int x,
int y,
char color);
399 hashtype compute_hashkey(
Pattern& pattern);
403 vector<pair<hashtype, int> > data;
404 boost::unordered_multimap<hashtype, HashhitF> data_p;
409 hashtype currentHashCode;
411 std::vector<std::pair<hashtype, ExtendedMoveNumber> > *lfc;
412 std::stack<HashVarInfo>* branchpoints;
413 boost::unordered_multimap<hashtype, HashhitF> hash_vector;
414 void get_HHF(
int ptr, vpsip results,
int orientation);
427 HashInstance(
char X,
char Y,
char SIZEX,
char SIZEY,
int BOARDSIZE);
429 bool inRelevantRegion(
char X,
char Y);
441 void addB(
char x,
char y);
442 void removeB(
char x,
char y);
443 void addW(
char x,
char y);
444 void removeW(
char x,
char y);
447 std::pair<hashtype,int> cHC();
448 hashtype* currentHashCode;
449 std::stack<std::pair<hashtype*,int> >* branchpoints;
465 virtual void AE_process(
int x,
int y,
char removed);
493 virtual void get_HHCS(
int ptr, vector<HashhitCS* >* results,
bool cs);
495 virtual std::pair<hashtype,std::vector<int> > compute_hashkey(
PatternList& pl,
int CS);
496 static const hashtype hashCodes[];
497 std::vector<HashInstance>* hi;
498 std::vector<std::pair<hashtype, int> > hash_vector;
500 vector<pair<hashtype, int> > data;
501 boost::unordered_multimap<hashtype, pair<int,int> > data_p;
515 std::pair<hashtype,std::vector<int> > compute_hashkey(
PatternList& pl,
int CS);
Definition: abstractboard.h:49
int gid
store the game id during processing
Definition: algos.h:147
virtual void pass_process()
Called during processing, for each pass.
Definition: algos.cpp:74
Definition: pattern.h:189
virtual void endOfNode_process()
Called during processing, after fully processing a node (which might contain several AB...
Definition: algos.cpp:72
int boardsize
board size
Definition: algos.h:148
virtual void endOfVariation_process()
Called during processing, when reaching the end of variation ("jump back to most recent branchpoint")...
Definition: algos.cpp:76
virtual void AW_process(int x, int y)
Called during processing, for each AW SGF tag.
Definition: algos.cpp:70
Definition: pattern.h:293
virtual void AB_process(int x, int y)
Called during processing, for each AB SGF tag.
Definition: algos.cpp:69
Definition: sgfparser.h:42
The GameList class is the main interface to the libkombilo functionality.
Definition: search.h:187
Definition: abstractboard.h:61
This algorithm computes the symmetrized Dyer signature of each game.
Definition: algos.h:155
virtual void branchpoint_process()
Called during processing, for each node where a variation starts.
Definition: algos.cpp:75
virtual int search(PatternList &patternList, GameList &gl, SearchOptions &options)
pattern search
Definition: algos.cpp:80
virtual void endgame_process(bool commit=true)
Called during processing, when the end of the game is reached.
Definition: algos.cpp:77
int size
size of the region used for hashing (the region is a square with side-length size, located at a corner of the board)
Definition: algos.h:518
virtual SnapshotVector get_data()
Extract the relevant data from file at Kombilo startup.
Definition: algos.cpp:79
Base class for hashing for general type patterns (currently works only for corner patterns)...
Definition: algos.h:454
virtual void AE_process(int x, int y, char removed)
Called during processing, for each AE SGF tag.
Definition: algos.cpp:71
virtual void move_process(Move m)
Called during processing, for each move (B, W tags)
Definition: algos.cpp:73
Hashing for full board patterns.
Definition: algos.h:369
virtual void initialize_process()
Called by GameList::start_processing.
Definition: algos.cpp:67
Hashing for corner patterns.
Definition: algos.h:506
virtual void newgame_process(int game_id)
Called when a new game is about to be GameList::process'ed.
Definition: algos.cpp:68
virtual void finalize_process()
Called by GameList::finalize_processing.
Definition: algos.cpp:78