BrainLearn

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

Moderators: Harvey Williamson, bob, hgm

Forum rules
This textbox is used to restore diagrams posted with the [d] tag before the upgrade.
Post Reply
Damir
Posts: 2422
Joined: Mon Feb 11, 2008 2:53 pm
Location: Denmark
Full name: Damir Desevac

Re: BrainLearn

Post by Damir » Sun Jun 28, 2020 6:34 pm

Thanks a lot Andrea. Looks very promising.

May I ask how development os Shashchess is going on ? :)

Damir
Posts: 2422
Joined: Mon Feb 11, 2008 2:53 pm
Location: Denmark
Full name: Damir Desevac

Re: BrainLearn

Post by Damir » Sun Jun 28, 2020 6:36 pm

Sorry just saw a thread with Shashchess.

peter
Posts: 2157
Joined: Sat Feb 16, 2008 6:38 am
Full name: Peter Martan

Re: BrainLearn

Post by peter » Tue Jun 30, 2020 6:47 pm

amchess wrote:
Sun Jun 28, 2020 5:58 pm
It's a pleasure to annonce the new BrainLearn 9 release with a lot of novelties:
-new Self Q-learning, a learning variant optimized for self play
Thanks for new BrainLearn!
Self Q-Learning chosen doesn't create an experience- file. Is this supposed to be so?
You already told me, more data was stored by ShashChess with option Standard.
Will Self make already existing experience.bin grow at all, if there isn't a new one created, or is it only kind of changed as for the entries?
Peter.

amchess
Posts: 147
Joined: Tue Dec 05, 2017 1:42 pm

Re: BrainLearn

Post by amchess » Tue Jun 30, 2020 9:35 pm

peter wrote:
Tue Jun 30, 2020 6:47 pm
amchess wrote:
Sun Jun 28, 2020 5:58 pm
It's a pleasure to annonce the new BrainLearn 9 release with a lot of novelties:
-new Self Q-learning, a learning variant optimized for self play
Thanks for new BrainLearn!
Self Q-Learning chosen doesn't create an experience- file. Is this supposed to be so?
You already told me, more data was stored by ShashChess with option Standard.
Will Self make already existing experience.bin grow at all, if there isn't a new one created, or is it only kind of changed as for the entries?
Q-learning is different from standard learning because it memorize only the previous game's best scores.
Moreover, the communication between the engine and the gui is very different changing this last.
So, we had to choice: at uci commands level, the experience is created at the moment where the engine is unloaded (quit command sent).
In fritz gui, you obtain this in match play (not tournament): when the match is terminated and you quit the gui.
In arena, after a tournament, when the engines are unloaded.
In aquarium, at tournament play (not match play), when you quit the gui
and so on.
Anyway, I advise you to use it only in selfplay.
After, you can use it, in normal mode, against another engine.
Andrea

peter
Posts: 2157
Joined: Sat Feb 16, 2008 6:38 am
Full name: Peter Martan

Re: BrainLearn

Post by peter » Tue Jun 30, 2020 11:01 pm

amchess wrote:
Tue Jun 30, 2020 9:35 pm
In fritz gui, you obtain this in match play (not tournament): when the match is terminated and you quit the gui.
Neither in Deep Fritz 14 nor in Shredder 13 with the popcnt compile a new experience is created by single moves.
Neither at unloading of the engine nor at quitting of the GUI.
Maybe only with result of a fully completed game and with complete move history including starting position?
Peter.

User avatar
Zerbinati
Posts: 74
Joined: Mon Aug 18, 2014 5:12 pm
Location: Trento (Italy)

Re: BrainLearn

Post by Zerbinati » Tue Jun 30, 2020 11:59 pm

peter wrote:
Tue Jun 30, 2020 11:01 pm
amchess wrote:
Tue Jun 30, 2020 9:35 pm
In fritz gui, you obtain this in match play (not tournament): when the match is terminated and you quit the gui.
Neither in Deep Fritz 14 nor in Shredder 13 with the popcnt compile a new experience is created by single moves.
Neither at unloading of the engine nor at quitting of the GUI.
Maybe only with result of a fully completed game and with complete move history including starting position?
Hi peter,
No experience file is created because there is a small error in the code ..
Delete the character ! in the uci.cpp file (line 83)

Code: Select all

	  LearningFileEntry currentLearningEntry;
	  currentLearningEntry.depth = 0;
	  currentLearningEntry.hashKey = pos.key();
	  currentLearningEntry.move = m;
	  currentLearningEntry.score = VALUE_NONE;
	  currentLearningEntry.performance = 100;
	  if(!Options["Self Q-learning"])
      {
	  	insertIntoOrUpdateLearningTable(currentLearningEntry,globalLearningHT);
      }

User avatar
Zerbinati
Posts: 74
Joined: Mon Aug 18, 2014 5:12 pm
Location: Trento (Italy)

Re: BrainLearn

Post by Zerbinati » Wed Jul 01, 2020 1:57 am

also file tt.cpp (line 268)

Code: Select all

	        ((node->latestMoveInfo.depth < node->siblingMoveInfo[k].depth)
	  		||
	  		((node->latestMoveInfo.depth == node->siblingMoveInfo[k].depth) && (node->latestMoveInfo.score <= node->siblingMoveInfo[k].score )))
	  	&& (!Options["Self Q-learning"])
	        )
	      )
	    {
		updateLatestMoveInfo (node, k);

peter
Posts: 2157
Joined: Sat Feb 16, 2008 6:38 am
Full name: Peter Martan

Re: BrainLearn

Post by peter » Wed Jul 01, 2020 5:04 am

Zerbinati wrote:
Tue Jun 30, 2020 11:59 pm
No experience file is created because there is a small error in the code ..
Thanks for pointing out, Marco!
I'll wait and see, how Andrea will handle this.
I''m not good enough at understanding that code neither at compiling on my own, so I'd wait and hope for new compiles to download then too anyhow for further testing of new Q-learning.
Peter.

amchess
Posts: 147
Joined: Tue Dec 05, 2017 1:42 pm

Re: BrainLearn

Post by amchess » Wed Jul 01, 2020 9:55 am

peter wrote:
Wed Jul 01, 2020 5:04 am
Zerbinati wrote:
Tue Jun 30, 2020 11:59 pm
No experience file is created because there is a small error in the code ..
Thanks for pointing out, Marco!
I'll wait and see, how Andrea will handle this.
I''m not good enough at understanding that code neither at compiling on my own, so I'd wait and hope for new compiles to download then too anyhow for further testing of new Q-learning.
There is no error in the code and the experience file is perfectly created.
You have to have administrator privileges to launch the gui.
If you remove the "!", there is no Q-learning.
The "!" is a negation/not operator in cpp: be careful in what you do if you're not a programmer.

User avatar
Zerbinati
Posts: 74
Joined: Mon Aug 18, 2014 5:12 pm
Location: Trento (Italy)

Re: BrainLearn

Post by Zerbinati » Wed Jul 01, 2020 11:51 am

amchess wrote:
Wed Jul 01, 2020 9:55 am
peter wrote:
Wed Jul 01, 2020 5:04 am
Zerbinati wrote:
Tue Jun 30, 2020 11:59 pm
No experience file is created because there is a small error in the code ..
Thanks for pointing out, Marco!
I'll wait and see, how Andrea will handle this.
I''m not good enough at understanding that code neither at compiling on my own, so I'd wait and hope for new compiles to download then too anyhow for further testing of new Q-learning.
There is no error in the code and the experience file is perfectly created.
You have to have administrator privileges to launch the gui.
If you remove the "!", there is no Q-learning.
The "!" is a negation/not operator in cpp: be careful in what you do if you're not a programmer.
Now I understand..
start an analysis and force some moves to close the GUI does not create anything .. but when I subsequently set a match play the BIN file is created

Post Reply