mobility score

Discussion of chess software programming and technical issues.

Moderators: hgm, Harvey Williamson, bob

Forum rules
This textbox is used to restore diagrams posted with the [d] tag before the upgrade.
op12no2
Posts: 349
Joined: Tue Feb 04, 2014 11:25 am
Location: Mumbles, Wales, UK.
Full name: Colin Jenkins
Contact:

mobility score

Post by op12no2 » Fri May 15, 2015 12:00 pm

Hi,

I've been reading more and more code recently 'cos i'm not getting very far on my own and I'm a bit confused by the relatively high value of mobility.

For example Fruit/TogaUserManual: Bishop mob score is a linear 5cp per square. A doubled pawn in the opening is -10cp.

Pos1: N bishop moves, no doubled pawn.
Pos2: N+3 bishop moves, doubled pawn.

Everything else being equal, Pos 2 scores better than Pos 1 regardless of N.

No doubt this works, but I don't really understand it - in that I would have thought the doubled pawn penalty should be more or the bishop mobility less; or am I looking at it all wrong...?

User avatar
hgm
Posts: 23474
Joined: Fri Mar 10, 2006 9:06 am
Location: Amsterdam
Full name: H G Muller
Contact:

Re: mobility score

Post by hgm » Fri May 15, 2015 12:51 pm

Humans usually make a big deal of doubled Pawns. For computers they seem hardly to matter at all, though.

PK
Posts: 813
Joined: Mon Jan 15, 2007 10:23 am
Location: Warsza
Contact:

Re: mobility score

Post by PK » Fri May 15, 2015 1:02 pm

Doubled pawn penalty is just an icing on the cake - but bear in mind that doubled pawn is a good indicator that there is a problem with pawn structure somewhere else. A couple of examples:

1.d4 Nf6 2.c4 e6 3.Nc3 Bb4 4.a3 Bxc3 5.bxc3 : weak "a" pawn
1.e4 e5 2. Nf3 Nc6 3. Bb5 a6 4. Bxc6 dxc6: white kingside majority
1.e4 e6 2.d4 d5 3.Nc3 Bb4 4.e5 c5 5.a3 Bxc3 6,bxc3: both doubled pawns are also weak/backward

User avatar
hgm
Posts: 23474
Joined: Fri Mar 10, 2006 9:06 am
Location: Amsterdam
Full name: H G Muller
Contact:

Re: mobility score

Post by hgm » Fri May 15, 2015 1:12 pm

PK wrote:but bear in mind that doubled pawn is a good indicator that there is a problem with pawn structure somewhere else. A couple of examples:
It means you are either a Pawn ahead, or have an extra half-open file. Neither of these are usually a problem, especially if you still have Rooks.

The worst thing about doubled Pawns is that they form a huge obstruction for shuttling your pieces between Queen and King side. But that usually shows up in the mobility too.

op12no2
Posts: 349
Joined: Tue Feb 04, 2014 11:25 am
Location: Mumbles, Wales, UK.
Full name: Colin Jenkins
Contact:

Re: mobility score

Post by op12no2 » Fri May 15, 2015 1:52 pm

OK Thanks guys, so the problem is really with my "everything else being equal" - that's not likely to be the case, so I'm creating an artificial/unrealistic/pathological example.

I have another question if I may be so bold. My engine does not scale well WRT time controls. At 40/1 it can take 80% of the points off engine X. At 40/2 about 55% and by 40/25 it's losing soundly. Is there a 'common' reason for this or could it be almost anything. What comes to my mind is over pruning and a possible TT bug, I'm testing the former now...

User avatar
Evert
Posts: 2923
Joined: Fri Jan 21, 2011 11:42 pm
Location: NL
Contact:

Re: mobility score

Post by Evert » Fri May 15, 2015 3:22 pm

op12no2 wrote: I have another question if I may be so bold. My engine does not scale well WRT time controls. At 40/1 it can take 80% of the points off engine X. At 40/2 about 55% and by 40/25 it's losing soundly. Is there a 'common' reason for this or could it be almost anything. What comes to my mind is over pruning and a possible TT bug, I'm testing the former now...
Effective branching factor.
If your engine is less selective than X it will look at more moves to reach a given depth, which means it will lag further and further behind the other engine as search depth increases. So rather than pruning too much, you may be pruning too little.

op12no2
Posts: 349
Joined: Tue Feb 04, 2014 11:25 am
Location: Mumbles, Wales, UK.
Full name: Colin Jenkins
Contact:

Re: mobility score

Post by op12no2 » Sat May 16, 2015 9:01 am

Thanks Evert, I'll do some more experiments.

I also came across this from Don Dailey (via CPW) in an interesting king safety thread.

http://www.talkchess.com/forum/viewtopi ... 241#445241

He had a similar problem and king safety solved it. My king safety is currently just a shelter so I'll add progressive attacks as well and see if that helps.

Based on Steve M's check extension thread I'm over extending check moves as well.

User avatar
hgm
Posts: 23474
Joined: Fri Mar 10, 2006 9:06 am
Location: Amsterdam
Full name: H G Muller
Contact:

Re: mobility score

Post by hgm » Sat May 16, 2015 9:27 am

Evaluation can indeed also play an important role in this. At low depth most games are decided by tactical errors, and wrong strategy induced by unrealistic or incomplete evaluation doesn't hurt that much. But deeper searches allow engines to more precisely enforce what their eval says is good (especially if the opponent's eval does not agree with that, and would make him glad to assist).

User avatar
lucasart
Posts: 3036
Joined: Mon May 31, 2010 11:29 am
Full name: lucasart
Contact:

Re: mobility score

Post by lucasart » Sun May 17, 2015 1:04 am

hgm wrote:Humans usually make a big deal of doubled Pawns. For computers they seem hardly to matter at all, though.
Completely agree. Somehow all computer chess beginners cite "doubled pawns" as one of the first feature they want to implement, but every experienced chess programmer knows they are practically (if not entirely) useless.

DiscoCheck doesn't evaluate doubled pawns. I tried to penalize doubled pawns in a zillion different ways, and it never improved elo, so I left this dubious feature out. Somehow it's worth a tiny bit of elo in SF, but it's never clear if it's valuable by itself, or simply by its orthogonal projection on the rest of the eval (eg. reducing on average the material value of a pawn).

I bet Lyudmil Tsvetkov would lecture me about doubled pawns, and tell me that DiscoCheck could gain 50 elo at least from properly implementing doubled pawns :lol:
Theory and practice sometimes clash. And when that happens, theory loses. Every single time.

kbhearn
Posts: 411
Joined: Thu Dec 30, 2010 3:48 am

Re: mobility score

Post by kbhearn » Sun May 17, 2015 5:25 am

lucasart wrote:
hgm wrote:Humans usually make a big deal of doubled Pawns. For computers they seem hardly to matter at all, though.
Completely agree. Somehow all computer chess beginners cite "doubled pawns" as one of the first feature they want to implement, but every experienced chess programmer knows they are practically (if not entirely) useless.

DiscoCheck doesn't evaluate doubled pawns. I tried to penalize doubled pawns in a zillion different ways, and it never improved elo, so I left this dubious feature out. Somehow it's worth a tiny bit of elo in SF, but it's never clear if it's valuable by itself, or simply by its orthogonal projection on the rest of the eval (eg. reducing on average the material value of a pawn).

I bet Lyudmil Tsvetkov would lecture me about doubled pawns, and tell me that DiscoCheck could gain 50 elo at least from properly implementing doubled pawns :lol:
I somehow doubt that... It's pretty well accepted in human theory that doubled pawns are not that big of a deal in most situations and in some cases even positive (such as an extra central pawn or allowing faster development). From a practical standpoint, beginning chess players tend to obsess about doubled pawns because it's something very easy to recognise and can be a symptom of a real problem or become a real problem. It's not really a huge surprise that the magnitude of a doubled pawn penalty in an engine should be small when many of the aggravating factors are also evaluated separately (isolated/backward/missing pawn in king shelter/holes that can be used for outposts).

Post Reply