|
—
本帖被 棋中论坛 从 完整软件 移动到本区(2010-09-17)
—
Search: hash, interpretation, set Unknown number of fellow chess player soft white stones set, is the summary about the principles and methods for use of reference. Hash table (hash) method of reading and chess software settings 1. What is a hash table (Transposition / Hash tables), what settings? Yi-start the engine when the chess analysis of a situation, it is often "test" to go in a different order to reach the same situation, but chess, the program was to this situation and the situation of the evaluation value stored in memory, once the encounter to other's move to reach the same order but the situation changes, in other words, when calculating the "other" changes, but get there before the situation actually out of date, the program will save the re-valuation of the time. Hash table is a data structure to speed up search, its own principles or models to do a little math to understand the basis of programming. (Yi-chess engine is not as engaged in writing can be both) Yi-hash table with the chess programs, play a significant role. For example, when calculating how to take the chess, I might go after the first cursory car may go first car cursory, if their opponents should be a corresponding change, then finish the two-step move behind different order to reach exactly the same situation is . If I have calculated estimates of the situation, that's great. If I have calculated that the situation would have to re-calculate the estimated bad, and if so the computer to do so, it will take up a lot of time. The use of hash table is in this case prior to rapidly find the work has been completed (the valuation has been calculated). I can put a valuation with an "index" (hash key) stored in the table, that the purpose is to create a "unique identity", while the implementation process is very fast. I created the current situation an "index", and then see whether the index in the table have been saved. If it is, it depends on how much the value of the table. The valuation of the table so I do not need in-depth enough to re-calculate it? If so, then I just take the value out from the table, instead of calculating it again. This greatly saves time. Hash table is a non-specific data structures, it can easily be as Yi-chess program for other purposes. Speed of its implementation of the procedures is very large, we believe that a good hash table is a very necessary program functions. According to the procedure of the different types of this table there are several. First of all, there are pieces Kuha Xi table [original note: Actually, more accurately called a cache more], according to the designer Dieter Buerssner Yace explanation, it is ", and similar working principle of the disk cache, to avoid excessive disk access movement, so the pieces paragraph improve the speed after the procedure. " Some chess Yi-program [such as Goliath] In addition to the pieces Kuha Xi table outside the main hash table is only one, while other [such as Crafty] in the main table structure in addition to using soldiers hash table. Yi-Bringer chess program there is in addition to the table outside the library there are three pieces, namely, soldiers, valuation and situation of hash table. . 2. That I should give how much memory space allocated hash table? Allocate more memory for the hash table space in general to improve the quality of chess. A Game for a long time and the faster your CPU, the hash table was quickly filled, it is set too large some help. However, if the bureau for a short time, set over a large space not only did not help, but may reduce the thinking depth, because there is too much access to action. Even if these negative did not happen for some of the engine (such as some versions of Crafty, and Chessmaster8000), they are clear every step chess hash table, so the hash table is large or even result in a delay of several seconds ( hit a patch of Chessmaster8000 and Chessmaster9000 do not have this problem.) If you are under the bureau quickly, of course, negative. 【Yi Zhu: Chessmaster8000/9000 can not be said, strictly speaking the "engine", but should be "software", or "procedure" is required. But the authors assume that the reader should clearly understand these basic concepts, not so strict So how much is too much? Writing for the chessbase • Steve Lopez, he recommended formula is: 2xCPU speed (in Mhz calculated) x average number of seconds the bureau each step, the outcome of the 1000 and then converted to M divided by the number of identified size, is that you allocate the memory for the hash table space. For example, if you let the engine 5 minutes walk 40 steps of the blitz, the use of the CPU speed is 1 Ghz (or 1000Mhz), according to the formula should be allocated for the hash table is the number of memory = 2x1000x (5x60/40) = 15000 K , divided by the 1000 conversion is 15M. But the question then comes, so the engine for each different figure out the size of the hash table are the same, without taking into account the speed of different search engines per second even if they 【similar level, the search speed may vary greatly in the】. Search engine to calculate how many per second, "nodes" (Node) to measure. Chessmaster Writing John • Merino proposed another formula, hash table size = 2x engine search nodes per second (NPS) x average number of seconds per step. Although this is only recommended for the Chessmaster while, but seems to be well adapted most of the engine, because it points directly to the section have been searching and therefore need to be assessed against the hash table size. However, this is still a rough proposal, I found it is usually higher than the result of a formula for the low, but do not know if This is more accurate. 【Yi Zhu: but if by the last two formulas, the result is smaller than the default even smaller lot. In addition it is also easy to set with the following methods are contradictory, so just for reference】 Also, if you do not let the engine play against the engine, you could set the hash table up to half of your memory. The rest is left to use the Windows operating system, and the rest can not be too small, so that the system itself is not enough and frequent hard disk access occurred. If you let the engine play against the engine, put them in the hash table and set the memory size of half. But I must say, this is the low memory constraints of users, for example less than 256M memory of the user. Memory resources used by Windows itself has a limited number, so if you have a great memory, you do not comply with "50%" rule. For example you have 512M memory, probably can be set to the total number of 420M. If there are two or more hash table at the same time also add pieces Kuha Xi table, then each hash table to be assigned more difficult to determine how much memory. I think that there is no absolute shortcut through the engine again and again in different experiments and the experience gained, OK. We must note that different engines are not the same. Some engines even mandatory fixed-size hash table can not be changed. The other, many of them may be allowed to modify the size and distribution of any value will do. While Crafty is somewhere between the two, it allows modification of the size of the hash table, but only by integer increments (decrease). Cyclones set the meaning of simple Cyclone engine configuration file for the cyclone.ini, you can use a text editor to open, such as "Notepad." Commonly used to set parameters for the hash and threads. Cyclones set (with a simple translation) hash = 256 (hash value) Threads = 2 (number of threads) clear hash = flase BookFile = cyclone.bin Speeded Alwaysvar = 100 Ponder = false (contemplation = false blitz select false) NullMove Pruning = Always (empty pruning) NullMove Reduction = 3 (empty decrease) History Pruning = true (historical trim, high-end low-end elections election true false) History Threshold = 70 (the historical threshold, the value of low-security, high value of sharpness) Delta Pruning = flase (incremental pruning, the Board elected to accelerate selection false true) Futility Pruning = true (in vain pruning, try different combinations) Futility Margin1 = 150 (incremental margin 1) Futility Margin2 = 300 (incremental margin 2) Verification Reduction = 5 (verification decrease) Verification Search = Always (verification search = always) Verification Search = Endgame (verification search = mess) Quiescence Check Plies = 1 (static checking layer) Delta Margin = 50 (incremental capacity limits) zevaluation options = 100 (evaluation of options) Note: Modify the cyclone.ini file, you must restart the "Chess Tornado" software to take effect. Set the contents of this post 1G memory, dual-core machine friends like more appropriate under the slow chess, in which the value can be changed according to the situation of their choice! ! Last edited by tuangod; 13-09-2010 at 15:45.
|