Changeset 183 for 06/libkombilo/testhash.py
- Timestamp:
- 09/22/06 20:53:40 (2 years ago)
- Files:
-
- 1 modified
-
06/libkombilo/testhash.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
06/libkombilo/testhash.py
r182 r183 9 9 print gl.size(), 'games in the database' 10 10 11 p = Pattern(FULLBOARD_PATTERN, 19, 19, 19, 12 '...................' + \ 13 '...................' + \ 14 '...O...............' + \ 15 '................X..' + \ 16 '...................' + \ 17 '...................' + \ 18 '...................' + \ 19 '...................' + \ 20 '...................' + \ 21 '...................' + \ 22 '...................' + \ 23 '...................' + \ 24 '...................' + \ 25 '...................' + \ 26 '...................' + \ 27 '....X..............' + \ 28 '...................' + \ 29 '...................' + \ 30 '...................') 11 contList = vectorMNC() # this is a little awkward at the moment ... 12 for m in [MoveNC(6,15,'X'), MoveNC(6,13,'O'), MoveNC(4,15,'X')]: contList.push_back(m) 31 13 32 14 p = Pattern(FULLBOARD_PATTERN, 19, 19, 19, … … 49 31 '........X.O.X......' + \ 50 32 '...................' + \ 51 '...................' )33 '...................', contList) 52 34 53 35 54 pl = PatternList(p, 0, 0, 19)55 # for p in range(pl.size()):56 # pl.get(p).printPattern()57 36 start = time.time() 58 gl.search(p l, SearchOptions())37 gl.search(p, SearchOptions()) 59 38 end = time.time() 60 39 print '\n'.join(gl.currentEntriesAsStrings()) 61 40 print gl.size(), 'games, ', gl.numHits(), 'hits.' 62 print gl.labels 41 for i in range(19): 42 print ' '.join(gl.labels[19*i:19*i+19]) 63 43 print 'This search took %.2f seconds.' % (end - start) 64 44
