Rodent IV Book Setup

824 views
Skip to first unread message

RandyR

unread,
Apr 5, 2020, 7:37:02 PM4/5/20
to PicoChess
Hi,

I was wondering if someone (Al?) can give me some help with setting up Rodent IV so that the personality selected will use the book file(s) referenced at the bottom of the applicable section (in the engine.uci file). I have selected no-book in the Picochess menu but the engine does not seem to be using a book, since it doesn't respond immediately to my opening move (e4) and appears to be thinking. Rodent III seems to work correctly, although I'm not sure how I can see which book it is actually using. I tried using the full path (e.g. /opt/picochess/engines/rodent4/books/micro.bin) in the GuideBookFile and MainBookFile entries, but it still doesn't appear to be using a book.

Secondly, is there a way to set the UCI_Elo parameter when using a personality? Can I just add the variable under the personality heading?

Thanks.

Randy

Scally

unread,
Apr 6, 2020, 2:12:40 AM4/6/20
to PicoChess
Hi Randy,

Yes I have Rodent IV working the developer is active again with help from a keen admirer, they are adding more personalities and updating it again.

I’ll knock something up for you and get back to you later today.

Al.

Scally

unread,
Apr 6, 2020, 8:05:41 AM4/6/20
to PicoChess
Hi Randy,

Clone my GitHub repository via:

sudo git clone https://github.com/ScallyBag/AlsPicoEngines/

then cd into it

cd into the folder named ‘requested’ and copy folder rodent4 to /opt/picochess/engines/ (sudo cp -r rodent4 /opt/picochess/engines/)

Remove any rodent4 engine files you already have in /opt/picochess/engines/armv7l/ and delete any reference to rodent4 from your picochess.ini file

cp rodentIV, rodentIV.uci and engines.ini.rodentIV from my ‘requested’ folder into /opt/picochess/engines/armv7l/

cd into /opt/picochess/engines/armv7l and mv you current engines.ini to engines.ini.old

Then create a new engines.ini with my engines.ini.rodentIV bolted on using sed:

sudo sed wengines.ini engines.ini.old engines.ini.rodentIV


Reboot and enjoy.

Note RodentIV has been compiled so that it can find the books within the /opt/picochess/engines/rodent4/ folder, so this must be there for books to work with the ‘no book’ setting on the clock.
There are ELO settings for the default engine, plus many personalities in the rodentIV.uci file. The authors are adding more and converting some of the favourite Rodent3 engines (these cannot be used in their current format) I will add these when they have finished.


Cheers,

Al.

RandyR

unread,
Apr 6, 2020, 10:14:24 AM4/6/20
to PicoChess
Hi Al.

Thanks very much for this. I have been keenly following the rejuvenated development of Rodent IV. I use a linux laptop to transfer the files, etc. and make the changes (as root) and will enjoy testing it this morning. I noticed there is a typo in your SED command (sudo sed wengines.ini engines.ini.old engines.ini.rodentIV) but I think most people would catch it.

I do have a question about the following engines.ini entry:

;Personality = ---
;UCI_Elo = 2800

If I select a personality, will it play at an Elo of 2800? To adjust that, do I just edit the above UCI_Elo entry? If I select a preset from the rodentIV.uci file (e.g. [13 Elo 2000]) does it override the UCI_Elo=2800 entry?

And, finally, do you have any tips or suggestions for me to compile my own engines? I have been struggling trying to set up a cross-compiler on my laptop (Linux Mint 19.3) and seem to run into issues with the linking process. I have been using the Stockfish dev source as my test code and was (eventually) able to compile directly on the Pi but haven't had any luck yet going the cross-compiler route. I would like to utilize the increased speed of the laptop. What kind of dev environment do you suggest?

Thanks again for sharing.

Randy

Scally

unread,
Apr 6, 2020, 10:55:41 AM4/6/20
to PicoChess
Hi Randy,

That’s no typo, the w is required.

The personalities will play at their strongest level.

The ELO levels are for the default engine only. If I made an ELO level for every personality the .uci file would be huge, there would be 21 levels for each personality. It’s doable, give it a try.

I compile directly on the RPi, but have updated all the default compilers to higher versions. I have no cross-compiler experience.

Attached is a picture of most of my source code folders.

I can help you with compiling most engines, just email me ....


Cheers,

Al.


B1AFDF02-83DA-43BF-9B0F-A5D9901E6EA8.jpeg

RandyR

unread,
Apr 6, 2020, 11:50:05 AM4/6/20
to PicoChess
Sorry for doubting you, Al. Your linux knowledge far surpasses mine. I mistakenly thought that commands always needed a '-' before them. Of course I just used a text editor to add the necessary lines to engines.ini.

The Rodent IV engine works great! Thanks so much. I'll play around with the UCI_Elo setting. I do not yet know Python so I am unsure what exactly the relationship is between the engines.ini file and the <engine>.uci files. If I want to adjust some options, where should I make the changes? For example, if I wanted to weaken the Amanda personality, should I do something like this in the rodentIV.uci file:

[Amanda]
; Amanda personality for Rodent IV chess engine
; attacker first, then emphasising own mobility
UCI_LimitStrength = true                <------- also, does there need to be an empty line inserted here?
UCI_Elo = 1200
PawnValueMg = 90
KnightValueMg = 380

or should I make the change in the engines.ini file:

;UCI_LimitStrength = True
;PrintPv = True
;TimeBuffer = 10
;Clear Hash =
;Personality = ---
;UCI_Elo = 1200
;Hash = 16

That's alot of engines you have there. Thanks for the offer of assistance! My RPi4 arrived a couple weeks ago so I could use it for compiling. I only have passive cooling, though. I'll continue to try to get the cross-compiler working. It's possible the errors I am seeing would also be present on the RPi when compiling there but I haven't compared specific results.

Thanks again, Al.

Randy

Scally

unread,
Apr 6, 2020, 12:31:26 PM4/6/20
to PicoChess
Hi Randy,

Any changes in the engines.ini file will be ignored, they just show what the options are.

Using Amanda as an example and assuming you wanted to play her at 1800 ELO you could add this to the rodentIV.uci file

[Amanda 1800] #11 characters maximum here
; Amanda personality for Rodent IV chess engine
; attacker first, then emphasising own mobility

UCI_LimitStrength = true
UCI_Elo = 1800

PawnValueMg = 90
KnightValueMg = 380
Etc ....


You could leave the Amanda name as it is [Amanda] and just add you ELO to each personality with the 2 lines added as above and your ‘UCI_Elo = ????’ Where ???? is the strength you want to play against. That way you’d still have 1 setting for each personality. Otherwise you’d have to duplicate all the Amanda settings for each ELO setting (21 times).

I hope this makes sense ....


Al.

RandyR

unread,
Apr 6, 2020, 12:35:36 PM4/6/20
to PicoChess
Thanks for that, Al. Yes, it does make sense. I will make changes in the rodentIV.uci file as suggested. I don't think I'm at the 1800 level yet, though. :^)

Randy

Scally

unread,
Apr 6, 2020, 12:43:12 PM4/6/20
to PicoChess
Hi Randy,

I’m thinking on the fly without trying it out.

It just occurred to me that you could add those 2 lines at the top here:

DEFAULT]
Hash = 16
Threads = 2
UCI_LimitStrength = true
UCI_Elo = ???? #1800 for example

Then every personality would play at 1800 or whatever Elo you like.

Al.

Scally

unread,
Apr 6, 2020, 12:44:31 PM4/6/20
to PicoChess
[DEFAULT] Of course

Scally

unread,
Apr 6, 2020, 1:12:21 PM4/6/20
to PicoChess
Yes that works,

Either that or I’m stronger than Tal 🤣


Al.

RandyR

unread,
Apr 6, 2020, 1:17:12 PM4/6/20
to PicoChess
Thanks for that tip, Al. I notice that when you drop the Elo down to hobby range (1100  - ok, maybe that's beginner range :^) ) that the computer takes a while to respond. I had assumed that it was because it was not using the book (maybe the code is written to do this?) but I think it actually IS using the book since if I bump it up to 2800, it responds immediately, so my original post may have been in error thinking it wasn't using the book at all. Still, I learned alot in this thread.

I saw another thread when I was searching yesterday that the display should say 'book' when the computer is still in the opening book, or is this just with the picochess books (or is this no longer the case)?

Randy

RandyR

unread,
Apr 6, 2020, 1:18:11 PM4/6/20
to PicoChess
Ha ha. Perhaps. :^)

Scally

unread,
Apr 6, 2020, 1:46:23 PM4/6/20
to PicoChess
Hi Randy,

Picochess shows ‘book’ when you’re using a Picochess book file and it’s still in book.

However with Rodent, you have to select ‘no book’ for it to use its own books. Then ‘book’ is not shown but it replies immediately so is obviously using the rodent books.

So I beat Tal (at grade 1400 😂) but when selecting one of the ELO levels like 2300 the default UCI_Elo is overridden, so all is working well. Only the personalities use the UCI_Elo in the [DEFAULT] section.

I’m going to add these 2 lines to my rodentIV.uci file so all anyone needs to do is to add their Elo and remove the ; at the front of the 2 lines.


Al.

RandyR

unread,
Apr 6, 2020, 1:51:20 PM4/6/20
to PicoChess
Great! Thanks for testing/verifying.

Randy
Reply all
Reply to author
Forward
0 new messages