Black has advantage in this position however I'm getting the wrong score in this position because (I'm guessing) there is too much of a penalty for the lack of pawn shelter in black's kingside. Should there be 3 cases for calculating pawn shelter? e.g. castled same side, castled opposite, and one or both sides not castled? I'm not sure if all programs make this distinction, but something is wrong because as I increase the pawnshelter penalties whites score increases to + when it should really be a big -. It seems logical that black should still have a penalty here.. but the score when compared to (I would say all) other programs is wrong. I was thinking maybe only do pawnshelter with queens still on? Thanks.
Black has an extra Bishop so I would think you should see that Black is ahead even if you calculate King Safety here. What do you see if you disable the king safety calculation? The position I would say is more an endgame. White has only two Rooks left so right now I think there is not much chance of attacking the black king with that. It could change if White had a very progressed passed pawn. If there was a promotion somehow then sudenly this endgame could change into a middlegame again In Stockfish if White had a full Queen and at least a Rook, in Rainbow Serpent at least the equivalent of Rook and Queen then it would start calculating King Safety again. But even with king safety enabled you should see that Black has an extra piece here so the position is comfortable for Black?
Regards Eelco
Debugging is twice as hard as writing the code in the first
place. Therefore, if you write the code as cleverly as possible, you
are, by definition, not smart enough to debug it.
-- Brian W. Kernighan
well first of all the ksafety is set rather high to obtain a + score for white, secondly Im considering changing to a 100 400 600 1200 piece value since the old 100 (or 80, 90) 325 500 975 just doesn't seem to cut it unless I add some bad trade code... perhaps another question for a different thread, but I was wondering how programs using the 325etc. piece values get correct scores without using bad trade code... or do they all? I thought crafty removed it i could be wrong. BTW I added that there needs to be a queen on the board for shelter eval and that basically seems to solve alot of problems, maybe I will make it Q+R or equivalent as you suggested? Maybe having Q+R or equivalent is good measure of endgame too? I'm currently doing end_eval if pieces < 5 but I wonder if there cant be a better criteria esp. if ksafety needs queens off. Thanks again for your answer.
Black has advantage in this position however I'm getting the wrong score in this position because (I'm guessing) there is too much of a penalty for the lack of pawn shelter in black's kingside. Should there be 3 cases for calculating pawn shelter? e.g. castled same side, castled opposite, and one or both sides not castled? I'm not sure if all programs make this distinction, but something is wrong because as I increase the pawnshelter penalties whites score increases to + when it should really be a big -. It seems logical that black should still have a penalty here.. but the score when compared to (I would say all) other programs is wrong. I was thinking maybe only do pawnshelter with queens still on? Thanks.
Are you evaluating this position directly by calling your evaluation function or get the score by searching to a certain time or depth?
outAtime wrote:Im not sure I understand the question... a score is returned by the engine when I tell it to analyze.
[d]5r1k/1b5r/1pp3R1/3p4/p2Pp3/2P1P3/PP3PR1/3K4 w - - 9 1
In this position, Deuterium's eval without searching is -170. Searching it to 10 seconds is -243.
That means black is better by more than 1 pawn (1.70) without searching and black is better by more than 2 pawns (2.43) with a search to 10 seconds.
outAtime wrote:By the way: With pawn shelter disabled score is about -1.60. I think that score is still not low enough but maybe thats because of the piece values.
Hi,
If your engine evaluates it from the point of view from White as -1.60 and Rybka as -1.50 then I think you have it about right
secondly Im considering changing to a 100 400 600 1200 piece value since the old 100 (or 80, 90) 325 500 975 just doesn't seem to cut it unless I add some bad trade code...
Getting the right piece values is another matter especially with unequal material on board, as you suggest. I don't think you can solve everything without some form of bad trade score or code that achieves something similar, and most programs know at least some basic rules. If you really want to avoid trade rules that go against the piece values you use I think there is no other way than having more values for different kind of material combinations. I don't think it is a problem if you first look at for instance what GM Larry Kaufman wrote here http://mywebpages.comcast.net/danheisma ... alance.htm for instance and then study how it is implemented in Stockfish, in material.cpp There is a lot more stuff in there (in material.cpp) but you just need to begin somewhere, and the article of Larry Kaufman is specifically mentioned in the Stockfish source code. The material.cpp code has been discussed in this forum too, I also made a few posts on Tord Romstad's material imbalance code so I'd be happy to discuss it some more.
Eelco
Debugging is twice as hard as writing the code in the first
place. Therefore, if you write the code as cleverly as possible, you
are, by definition, not smart enough to debug it.
-- Brian W. Kernighan
Yes, thankyou for the reply. I will have a look at the material code you have suggested and see if I get any ideas. I'm convinced at this point that some imbalance code is definitely needed using the 325 values. I've been doing a ton of bugfixing and even with kingsafety improved I'm still getting bad scores because the darn thing is a piece down (maybe for 2 pawns, even) and over-values the position with an open opp. king + weak passer. Interesting so much compensation is needed for a piece when the tactics are becoming clear Thanks again!