Poll: How Many "Weights" Needed To Play "Known" Chess Very Well?

Discussion of anything and everything relating to chess playing software and machines.

Moderators: bob, hgm, Harvey Williamson

Forum rules
This textbox is used to restore diagrams posted with the [d] tag before the upgrade.

How many weights needed to play known chess very well using definitions in first post?

Fewer than 10 million
0
No votes
10 - 50 million
0
No votes
51-100 million
0
No votes
101 million - 1 billion
0
No votes
2 billion - 100 billion
0
No votes
More than 100 billion
0
No votes
 
Total votes: 0

User avatar
Ovyron
Posts: 2707
Joined: Tue Jul 03, 2007 2:30 am

Re: Poll: How Many "Weights" Needed To Play "Known" Chess Very Well?

Post by Ovyron » Tue Oct 22, 2019 4:03 am

Yes, you go and see how Human GMs play bullet chess to realize how calculation is a critical part of avoiding critical mistakes. Even at 3 0 they blunder a lot, it's just that if they're not good enough to find the opponent's tactic to avoid it's also likely their opponents don't have time to see it either.
Great spirits have always encountered violent opposition from mediocre minds.

Dann Corbit
Posts: 10110
Joined: Wed Mar 08, 2006 7:57 pm
Location: Redmond, WA USA
Contact:

Re: Poll: How Many "Weights" Needed To Play "Known" Chess Very Well?

Post by Dann Corbit » Tue Oct 22, 2019 4:06 am

Suppose it were 10,000 weights needed.
Humans would have no hope to comprehend that clearly.
We do well up to 7 distinct items, on average. After that, we start to degrade.
We can deal with bigger clumps of things by splitting into parts (especially related parts).
But past a certain point, we start to get lost even with that.
That's why menus often get split into sub-menus at a certain count on computer menu systems.
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.

User avatar
Ovyron
Posts: 2707
Joined: Tue Jul 03, 2007 2:30 am

Re: Poll: How Many "Weights" Needed To Play "Known" Chess Very Well?

Post by Ovyron » Tue Oct 22, 2019 7:18 am

People can recite 30000 numbers of pi from memory so it wouldn't be out of reach for some people to just memorize the weights and apply them to positions.

If it comes to learning the weights it might be possible to applying them without needing to comprehend them.
Great spirits have always encountered violent opposition from mediocre minds.

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

Re: Poll: How Many "Weights" Needed To Play "Known" Chess Very Well?

Post by hgm » Tue Oct 22, 2019 7:51 am

fabianVDW wrote:
Mon Oct 21, 2019 9:16 pm
You are right for counting, but I would not immediately see such neurons for determining for instance passers.
More complex than counting, for sure, but still not very hard. For each square you would need a neuron that fires when there is a passer on that square. (And that for each player.) This neuron for input connects to the Pawn plane of its own square with a positive weight (say +1), and to all squares in front of it in the enemy Pawn plane on its own file and the two adjacent files, with larger negative weight (say -1). The neuron can have step-function or rectifier response. Even for a 2nd-rank square that is only 16 connections, for 7th rank it is only one. The only way to get a +1 output is if there is a passer on that square; otherwise the output will be 0.

In the next layer you can have counting cells per file for the number of passers in that file (6 inputs), or detecting the fact there is at least one passer (step-function response). In the third layer you can have a cell per pair of neighboring files with 2 inputs, to detect connected passers. All these cells can be connected to a final summing output cell with the desired evaluation weight for the feature (passer in that location, bonus or connected passers etc.).

User avatar
towforce
Posts: 9295
Joined: Wed Mar 08, 2006 11:57 pm
Location: Birmingham UK

Re: Poll: How Many "Weights" Needed To Play "Known" Chess Very Well?

Post by towforce » Tue Oct 22, 2019 10:10 pm

dkappe wrote:
Mon Oct 21, 2019 11:11 am
The 11258 distilled networks run all the way from 16x2, 24x3, 32x4, 48x5, etc., and will run reasonably well on CPU. You can find them here: https://github.com/dkappe/leela-chess-w ... d-Networks

Try out the various sizes on lc0 and judge for yourself.

You can also try this BOT https://github.com/dkappe/leela-chess-w ... -style-net

It’s a 32x4 looking at ~25 moves on a raspberry pi 3. Because of its source material, it plays objectively weaker moves than SF or leela, but is very effective against humans.

Thanks - just had 3 interesting games against her. By the third game, I'd learned that I have to defend my king as the top priority or it will get killed, and I thought I was holding on, but then made a losing blunder under pressure. I might be mistaken, but I think she missed a checkmate sequence in game 3 - but all that achieved was to prolong the agony! :oops:
Love of truth is the best defence against ideological possession.

Dann Corbit
Posts: 10110
Joined: Wed Mar 08, 2006 7:57 pm
Location: Redmond, WA USA
Contact:

Re: Poll: How Many "Weights" Needed To Play "Known" Chess Very Well?

Post by Dann Corbit » Tue Oct 22, 2019 10:36 pm

Ovyron wrote:
Tue Oct 22, 2019 7:18 am
People can recite 30000 numbers of pi from memory so it wouldn't be out of reach for some people to just memorize the weights and apply them to positions.
Someone did 100K digits. There is a difference, though, between having nearly photographic memory and knowing the meaning of the thing memorized.
https://www.foxnews.com/story/japanese- ... gits-of-pi
If it comes to learning the weights it might be possible to applying them without needing to comprehend them.
But if we still don't understand them, why not just leave them as "black box weights"?
The NN engine already knows how to use them. You could inject them into an alpha-beta searcher, but you would still need a GPU to do all the math or it would be too slow.
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.

User avatar
Ovyron
Posts: 2707
Joined: Tue Jul 03, 2007 2:30 am

Re: Poll: How Many "Weights" Needed To Play "Known" Chess Very Well?

Post by Ovyron » Tue Oct 22, 2019 11:02 pm

Dann Corbit wrote:
Tue Oct 22, 2019 10:36 pm
There is a difference, though, between having nearly photographic memory and knowing the meaning of the thing memorized.
The idea would be memorizing all the weights and being able to use them to figure out what move to play in a give chess position without needing to understand their meaning. Like learning how to decode a crypto message and getting that TH is Z and being able to translate it even if you don't know what Z means by itself. The combination of pieces on a chess board could code the best move to play and you'd just need to decipher it.
Dann Corbit wrote:
Tue Oct 22, 2019 10:36 pm
But if we still don't understand them, why not just leave them as "black box weights"?
The idea would be that someone could become world chess champion by learning the weights and applying them in their chess games, even if they didn't understand their meaning.

(...in theory. In practice it may turn out the weights out of the "black box" are gibberish and unusable by humans...)

User avatar
towforce
Posts: 9295
Joined: Wed Mar 08, 2006 11:57 pm
Location: Birmingham UK

Re: Poll: How Many "Weights" Needed To Play "Known" Chess Very Well?

Post by towforce » Wed Oct 23, 2019 7:52 am

Dann Corbit wrote:
Tue Oct 22, 2019 10:36 pm
But if we still don't understand [the weights], why not just leave them as "black box weights"?

I believe it will be possible to use linear programming to fit numerical expressions rather than trained NNs, with the following advantages:

1. Chess without search is a complex shape that will be extremely difficult to "fit" with NN learning alone. IMO LP has a better chance

2. A set of expressions will be easier to simplify than a trained NN IMO, making for a smaller overall size, a faster run time, and more hope that humans might be able to understand it

3. IMO it is very possible that there might exist a relatively simple expression that will work in most chess positions (there probably isn't a super-simple one, or it would likely have been found already), and that it might be possible to find it. If so, it will be much easier to extract "human meaning" from a numerical expression than it would from an NN
Love of truth is the best defence against ideological possession.

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

Re: Poll: How Many "Weights" Needed To Play "Known" Chess Very Well?

Post by hgm » Wed Oct 23, 2019 12:58 pm

But a NN is nothing but a set of expressions...

User avatar
towforce
Posts: 9295
Joined: Wed Mar 08, 2006 11:57 pm
Location: Birmingham UK

Re: Poll: How Many "Weights" Needed To Play "Known" Chess Very Well?

Post by towforce » Wed Oct 23, 2019 3:05 pm

hgm wrote:
Wed Oct 23, 2019 12:58 pm
But a NN is nothing but a set of expressions...

A quick comparison of NN training with generating expressions and fitting them to a classification problem using linear prgramming. NN offers the following advantages:

1. You can download a software library like TensorFlow and, if you know what you're doing, you're good to go

2. Proven way of getting a good learning system for many problem types

3. Being used right now for chess position evaluation in many chess engines (some of them free and open source, and they mostly play very well)

4. If you want a classifier that fits the given data using Linear Programming (LP), and which would hence output a set of expressions, then right now you're building it yourself


LP generated expressions would offer the following advantages:

1. IMO LP will be more able to fit a complex shape like the solution to chess than a NN will

2. Could fit the data to the mathematical limit - the best possible fit (it may be necessary to use some LP tricks like symmetry breaking in such a large model space)

3. Having found the best fit, you could then turn the achieved fit into a model condition, and then do another optimisation to maximise the number of expressions for which the weight is zero, resulting in a smaller set of expressions

4. Having got a set of expressions and weights, it would be easy to translate this into a computer language for a program that would run on any computer - with or without a graphics card

5. If it turns out to be possible to make smallish set of expressions which can correctly classify most chess positions, it might be possible to articulate this expression in English language

Btw - if classification by LP turns out to be viable, you'll then have another optimisation problem: selection of position/evaluation pairs. The 7 piece tablebase alone has 423,836,835,667,331 positions in, which is infeasibly large for an LP model with today's technology - by many orders of magnitude. If you couldn't find a selection of around a million of them which could enable most of the others to be solved by the classifier, then the quest to solve "known chess" this way would likely be out of reach.
Love of truth is the best defence against ideological possession.

Post Reply