Sounds reasonable. If that helps in increasing the playing strength, it would be a "cheapo", because it's easy to implement.zamar wrote:
One idea:
Loop through opponent's pawns. Find highest relative rank of pawn which is not blocked by enemy pawn. If this pawn is further advanced than unstoppable pawn, give significantly lower unstoppable pawn bonus.
unstoppable passed pawns in stockfish
Moderator: Ras
-
- Posts: 408
- Joined: Sat Mar 06, 2010 9:28 am
Re: unstoppable passed pawns in stockfish
-
- Posts: 10895
- Joined: Thu Mar 09, 2006 12:37 am
- Location: Tel-Aviv Israel
Re: unstoppable passed pawns in stockfish
Note that a pawn that is blocked can also be relevant because the king may capture the blocking pawnRalph Stoesser wrote:Sounds reasonable. If that helps in increasing the playing strength, it would be a "cheapo", because it's easy to implement.zamar wrote:
One idea:
Loop through opponent's pawns. Find highest relative rank of pawn which is not blocked by enemy pawn. If this pawn is further advanced than unstoppable pawn, give significantly lower unstoppable pawn bonus.
[d]2K4k/p7/P6p/8/8/8/8/8 w - - 0 1
I think that if you suspect an unstoppable pawn the best thing to do is
simply to calculate some bound for number of moves to promote for every pawn of the opponent when you can use also king moves and unstoppable that get high bonus is only a pawn that can promote 2 plies earlier than all the opponent pawns(you can include also one ply in case that it promotes with check but it is more complicated to calculate).
Uri
-
- Posts: 2684
- Joined: Sat Jun 14, 2008 9:17 pm
Re: unstoppable passed pawns in stockfish
Following is imho the general and correct approach to detect unstoppable pawns in pawn endgames:
1 - save king positions inpawn hashes, this is a prerequisite to let the system dont slow down to much.
2 - for each new pawn-king disposition do an 7 depth search and detect if we got a queen score
3 - save the result in pawn hash to avoid recalculate
To mitigate the effect you may want (loosing detecting queens on some cases) to trigger the search only in cases wherw current code detects an unstoppable pawn.
1 - save king positions inpawn hashes, this is a prerequisite to let the system dont slow down to much.
2 - for each new pawn-king disposition do an 7 depth search and detect if we got a queen score
3 - save the result in pawn hash to avoid recalculate
To mitigate the effect you may want (loosing detecting queens on some cases) to trigger the search only in cases wherw current code detects an unstoppable pawn.