So B underpromotion is an illegal move for Rybka? what happens if you underpromote to B. Will Rybka accept it or will it crash?
Anyway, you can fit a move in 12 bits if you want.
Miguel
It will not crash the program. It just does not generate or search anything but knight and queen promotions within its search. It is one of those litmus test issues for programmers. Most folks understand that you will get a couple ELO out of doing this, and choose to support under-promotion anyway because the extra strength is not worth the unasthetic aspect of not implementing all the rules of chess within their move generation.
Matthias Gemuh wrote:
An engine that is 100% faster is 50 Elo stronger.
An engine that is 10% faster is 5 Elo stronger.
Skipping bishop promotions makes Rybka 10% faster and gains 5 Elo points.
Matthias.
I don't believe it is worth 10%, I'll measure this later this afternoon and report actual results.
I tried this. Had to delete something like 9 lines of code to get rid of bishop underpromotions. I could measure absolutely no speed difference with or without. Even on positions like fine 70 which has massive promotion branches, the NPS did not vary by even 1%. I saw a few thousand nodes in a 1 minute search, typically, which did not produce a measurable speed increase.
I believe he actually meant there was a slight reduction in search time for a ply, mostly due to reduced tree size. It is not really a NPS issue.
-Sam
Right. As I explained in one post, it is about a 10% smaller search tree, not 10% higher nps.
10% is a difficult-to-prove figure, except one really plays 100000 unique games or more.
I was measuring _time_ to complete a fixed depth search. I could not measure the improvement, it was so tiny. The tree sizes reduce, but by almost nothing. Think about this...
You just tried e8=Q, and it fails most of the time because it is immediately captured. What happens on any other under-promotion? They fail for the same reason, and after one move at the next ply, you get a hash hit. By eliminating the e8=B, you eliminate making one move and then one move at the next ply. This is such a tiny reduction it really doesn't matter. If you do a 60 second search and the difference with and without the =B move is < 0.01 seconds (that is the resolution of the timer in Crafty) then I think you can safely conclude that there is _zero_ Elo gain by eliminating the B under-promotion.
So B underpromotion is an illegal move for Rybka? what happens if you underpromote to B. Will Rybka accept it or will it crash?
Anyway, you can fit a move in 12 bits if you want.
Miguel
There is a trivial way to fit a move into 8 bits. You simply generate all legal moves in a static canonical order, and then the move becomes the index into this list. Since, for a given position, you always generate moves in a static order, the index into this list will always be consistent for a given move.
Matthias Gemuh wrote:
An engine that is 100% faster is 50 Elo stronger.
An engine that is 10% faster is 5 Elo stronger.
Skipping bishop promotions makes Rybka 10% faster and gains 5 Elo points.
Matthias.
I don't believe it is worth 10%, I'll measure this later this afternoon and report actual results.
I tried this. Had to delete something like 9 lines of code to get rid of bishop underpromotions. I could measure absolutely no speed difference with or without. Even on positions like fine 70 which has massive promotion branches, the NPS did not vary by even 1%. I saw a few thousand nodes in a 1 minute search, typically, which did not produce a measurable speed increase.
I believe he actually meant there was a slight reduction in search time for a ply, mostly due to reduced tree size. It is not really a NPS issue.
-Sam
Right. As I explained in one post, it is about a 10% smaller search tree, not 10% higher nps.
10% is a difficult-to-prove figure, except one really plays 100000 unique games or more.
I was measuring _time_ to complete a fixed depth search. I could not measure the improvement, it was so tiny. The tree sizes reduce, but by almost nothing. Think about this...
You just tried e8=Q, and it fails most of the time because it is immediately captured. What happens on any other under-promotion? They fail for the same reason, and after one move at the next ply, you get a hash hit. By eliminating the e8=B, you eliminate making one move and then one move at the next ply. This is such a tiny reduction it really doesn't matter. If you do a 60 second search and the difference with and without the =B move is < 0.01 seconds (that is the resolution of the timer in Crafty) then I think you can safely conclude that there is _zero_ Elo gain by eliminating the B under-promotion.
I agree that the difference is probably very small but you cannot be sure of zero elo without testing and it may be also 1 elo or 2 elo points or 3 elo.
I have the following comments.
1)Most of the time is not all the time.
There are cases when you cannot capture the bishop and you still fail low because the opponent promotes to a queen and it contradicts the underpromotion so you do not get hash hit.
2)eliminating tiny reductions may be important if the elimination happen often.
Promotions can happen near the leaves and not in the root
and if they happen often enough you can save significant number of nodes.
If 2% of the moves that you make in the search of some endgame are underpromotions to bishop then you can get at least 2% speed improvement in that endgame.
So B underpromotion is an illegal move for Rybka? what happens if you underpromote to B. Will Rybka accept it or will it crash?
Anyway, you can fit a move in 12 bits if you want.
Miguel
It will not crash the program. It just does not generate or search anything but knight and queen promotions within its search. It is one of those litmus test issues for programmers. Most folks understand that you will get a couple ELO out of doing this, and choose to support under-promotion anyway because the extra strength is not worth the unasthetic aspect of not implementing all the rules of chess within their move generation.
-Sam
It also generates rook promotions in the search.
Miguel,
Rybka will accept promotion to bishop by the opponent because it has a function to make a bishop underpromotion(she simply does not use it during the search)
bob wrote:
I was measuring _time_ to complete a fixed depth search. I could not measure the improvement, it was so tiny. The tree sizes reduce, but by almost nothing. Think about this...
You just tried e8=Q, and it fails most of the time because it is immediately captured. What happens on any other under-promotion? They fail for the same reason, and after one move at the next ply, you get a hash hit. By eliminating the e8=B, you eliminate making one move and then one move at the next ply. This is such a tiny reduction it really doesn't matter. If you do a 60 second search and the difference with and without the =B move is < 0.01 seconds (that is the resolution of the timer in Crafty) then I think you can safely conclude that there is _zero_ Elo gain by eliminating the B under-promotion.
I too had the feeling that the 5 Elo gain I estimated are really too high.
Matthias Gemuh wrote:
An engine that is 100% faster is 50 Elo stronger.
An engine that is 10% faster is 5 Elo stronger.
Skipping bishop promotions makes Rybka 10% faster and gains 5 Elo points.
Matthias.
I don't believe it is worth 10%, I'll measure this later this afternoon and report actual results.
I tried this. Had to delete something like 9 lines of code to get rid of bishop underpromotions. I could measure absolutely no speed difference with or without. Even on positions like fine 70 which has massive promotion branches, the NPS did not vary by even 1%. I saw a few thousand nodes in a 1 minute search, typically, which did not produce a measurable speed increase.
I believe he actually meant there was a slight reduction in search time for a ply, mostly due to reduced tree size. It is not really a NPS issue.
-Sam
Right. As I explained in one post, it is about a 10% smaller search tree, not 10% higher nps.
10% is a difficult-to-prove figure, except one really plays 100000 unique games or more.
I was measuring _time_ to complete a fixed depth search. I could not measure the improvement, it was so tiny. The tree sizes reduce, but by almost nothing. Think about this...
You just tried e8=Q, and it fails most of the time because it is immediately captured. What happens on any other under-promotion? They fail for the same reason, and after one move at the next ply, you get a hash hit. By eliminating the e8=B, you eliminate making one move and then one move at the next ply. This is such a tiny reduction it really doesn't matter. If you do a 60 second search and the difference with and without the =B move is < 0.01 seconds (that is the resolution of the timer in Crafty) then I think you can safely conclude that there is _zero_ Elo gain by eliminating the B under-promotion.
I agree that the difference is probably very small but you cannot be sure of zero elo without testing and it may be also 1 elo or 2 elo points or 3 elo.[
I am certain that the speed gain (which was < 0.01 seconds on a 60 second search) is not going to produce anywhere remotely near 1 Elo. I tried several positions. Probably fine 70 leads to the most issues with this position and it was no faster with or without bishop under-promotions. When the cluster comes back up, I'll run it, but expect no detectable difference, although it will require at least 200K games to get down to the resolution necessary to pick up such a small change.
I have the following comments.
1)Most of the time is not all the time.
Hence my choice of the word "most"
I care about the usual case, not the 1% case... The usual case is the one that bears the brunt of the search effort.
There are cases when you cannot capture the bishop and you still fail low because the opponent promotes to a queen and it contradicts the underpromotion so you do not get hash hit.
2)eliminating tiny reductions may be important if the elimination happen often.
Promotions can happen near the leaves and not in the root
and if they happen often enough you can save significant number of nodes.
If 2% of the moves that you make in the search of some endgame are underpromotions to bishop then you can get at least 2% speed improvement in that endgame.
Uri
But they aren't, based on measurement on endgame test positions....
Just for fun. I tested some engines with this position (original) which requires a Bishop promotion to win:
[d]4r3/5P1k/5K2/5N2/8/8/8/8 w - - 0 1
Actually Rybka 2.2 (the only version I have) fails to solve it and draws, while all other engines I tried (but mine ) get it. Of course, with 5-man TB's there is no issue.