New chess engine: Texel

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

Moderators: hgm, Rebel, chrisw

petero2
Posts: 687
Joined: Mon Apr 19, 2010 7:07 pm
Location: Sweden
Full name: Peter Osterlund

New chess engine: Texel

Post by petero2 »

Hi,

My new UCI chess engine "Texel" is now available for download from http://web.comhem.se/petero2home/texel101.zip

Texel is derived from my old engine CuckooChess. In fact, Texel 1.00 was functionally equivalent to an unreleased version of CuckooChess. The main difference is that Texel is written in C++11 instead of java.

The program is licensed under GNU GPLv3. The zip archive contains source code and binaries for linux 64-bit and 32-bit (Fedora 16, untested on other distributions) and windows 64-bit and 32-bit (tested on Windows 7 64-bit and Windows Vista 32-bit.)

In theory it should be possible to compile the program on any platform that has a C++11 compiler, because the source code does not contain any platform-specific code. In practice it is still quite hard to find good C++11 compilers. I have used gcc 4.6.3 in linux and Visual Studio 2012 beta in Windows.

Changes compared to CuckooChess 1.12:

* Ported from Java to C++. About twice as fast as a result.
* Made node counters 64-bit to avoid overflow in long searches.
* Fixed handling of UCI "searchmoves" command.
* Added evaluation term to avoid walking into wrong corner in KRKB endings.
* Implemented reverse futility pruning.
* Implemented late move pruning.
* Made strength setting between 0% and 10% even weaker. 0% now plays random legal moves and 10% corresponds to the old 0% setting.
* Replaced cuckoo hashing with a more cache-friendly alternative.
* Try harder not to lose on time in really short time control games.
* Implemented passed pawn race evaluation.
* Increased passed pawn bonus for pawns on rank 6 and 7.

Texel scores about 70% (+140 elo) against CuckooChess 1.13a8 (unreleased) on my 64-bit linux computer at short time control (60 moves in 8 seconds), but I would be very surprised if the difference is that big at longer time controls against different engines.
mar
Posts: 2554
Joined: Fri Nov 26, 2010 2:00 pm
Location: Czech Republic
Full name: Martin Sedlak

Re: New chess engine: Texel

Post by mar »

Hi Peter, i already heard that you are writing a C++ engine based on Cuckoo, so congratulations and good luck!
Cuckoo was already amazing so i wonder how well it will do, +140 is more than impressive!
petero2
Posts: 687
Joined: Mon Apr 19, 2010 7:07 pm
Location: Sweden
Full name: Peter Osterlund

Re: New chess engine: Texel

Post by petero2 »

Thanks Martin

I know +140 sounds impressive, but I believe there is some unknown effect in the test setup that is responsible for this. A 2X speed increase should not be worth more than 70 elo max.

At first I suspected java startup time and time before the JIT compiler had optimized the java bytecode. However I use cutechess-cli to run the tests, and it doesn't restart the engines between games, so this effect should only exist for the first game.
mar
Posts: 2554
Joined: Fri Nov 26, 2010 2:00 pm
Location: Czech Republic
Full name: Martin Sedlak

Re: New chess engine: Texel

Post by mar »

petero2 wrote:Thanks Martin

I know +140 sounds impressive, but I believe there is some unknown effect in the test setup that is responsible for this. A 2X speed increase should not be worth more than 70 elo max.

At first I suspected java startup time and time before the JIT compiler had optimized the java bytecode. However I use cutechess-cli to run the tests, and it doesn't restart the engines between games, so this effect should only exist for the first game.
Yes some say it's 50 elo for doubling, most say 70 and some say it's about 100.
Anyway i think even if it's less than 140 at long TC, even 70, it's still impressive.
I recently fixed a couple of nasty bugs but could not improve more than 10 :)
So fingers crossed to surpass Fruit 2.1!
zullil
Posts: 6442
Joined: Tue Jan 09, 2007 12:31 am
Location: PA USA
Full name: Louis Zulli

Re: New chess engine: Texel

Post by zullil »

Doesn't compile under Mac OS X 10.6.8 using gcc-4.6.3:

Code: Select all

LZsMacPro-OSX6: ~/Downloads/texel101] make texel64
mkdir -p obj64
g++-mp-4.6 -O3 -Wall -std=c++0x -m64 -c -o obj64/bitBoard.o src/bitBoard.cpp
mkdir -p obj64
g++-mp-4.6 -O3 -Wall -std=c++0x -m64 -c -o obj64/book.o src/book.cpp
mkdir -p obj64
g++-mp-4.6 -O3 -Wall -std=c++0x -m64 -c -o obj64/computerPlayer.o src/computerPlayer.cpp
mkdir -p obj64
g++-mp-4.6 -O3 -Wall -std=c++0x -m64 -c -o obj64/enginecontrol.o src/enginecontrol.cpp
In file included from src/enginecontrol.cpp:28:0:
src/enginecontrol.hpp:50:21: error: 'thread' is not a member of 'std'
src/enginecontrol.hpp:50:21: error: 'thread' is not a member of 'std'
src/enginecontrol.hpp:50:32: error: template argument 1 is invalid
src/enginecontrol.hpp:51:5: error: 'mutex' in namespace 'std' does not name a type
src/enginecontrol.cpp: In member function 'void EngineControl::ponderHit()':
src/enginecontrol.cpp:119:9: error: 'lock_guard' is not a member of 'std'
src/enginecontrol.cpp:119:25: error: 'mutex' is not a member of 'std'
src/enginecontrol.cpp:119:39: error: 'threadMutex' was not declared in this scope
src/enginecontrol.cpp:119:50: error: 'L' was not declared in this scope
src/enginecontrol.cpp: In lambda function:
src/enginecontrol.cpp:228:18: error: 'std::this_thread' has not been declared
src/enginecontrol.cpp:231:9: error: 'lock_guard' is not a member of 'std'
src/enginecontrol.cpp:231:25: error: 'mutex' is not a member of 'std'
src/enginecontrol.cpp:231:39: error: 'threadMutex' was not declared in this scope
src/enginecontrol.cpp:231:50: error: 'L' was not declared in this scope
src/enginecontrol.cpp:237:25: error: base operand of '->' is not a pointer
src/enginecontrol.cpp&#58;238&#58;22&#58; error&#58; request for member 'reset' in '(&#40;const EngineControl&#58;&#58;startThread&#40;int, int, int, int&#41;&#58;&#58;<lambda&#40;)>*&#41;this&#41;->EngineControl&#58;&#58;startThread&#40;int, int, int, int&#41;&#58;&#58;<lambda&#40;)>&#58;&#58;__this->EngineControl&#58;&#58;engineThread', which is of non-class type 'int'
src/enginecontrol.cpp&#58; In member function 'void EngineControl&#58;&#58;startThread&#40;int, int, int, int&#41;'&#58;
src/enginecontrol.cpp&#58;243&#58;9&#58; error&#58; 'lock_guard' is not a member of 'std'
src/enginecontrol.cpp&#58;243&#58;25&#58; error&#58; 'mutex' is not a member of 'std'
src/enginecontrol.cpp&#58;243&#58;39&#58; error&#58; 'threadMutex' was not declared in this scope
src/enginecontrol.cpp&#58;243&#58;50&#58; error&#58; 'L' was not declared in this scope
src/enginecontrol.cpp&#58;244&#58;22&#58; error&#58; request for member 'reset' in '(&#40;EngineControl*&#41;this&#41;->EngineControl&#58;&#58;engineThread', which is of non-class type 'int'
src/enginecontrol.cpp&#58;244&#58;32&#58; error&#58; expected type-specifier
src/enginecontrol.cpp&#58;244&#58;32&#58; error&#58; expected ')'
src/enginecontrol.cpp&#58; In member function 'void EngineControl&#58;&#58;stopThread&#40;)'&#58;
src/enginecontrol.cpp&#58;250&#58;21&#58; error&#58; 'thread' is not a member of 'std'
src/enginecontrol.cpp&#58;250&#58;21&#58; error&#58; 'thread' is not a member of 'std'
src/enginecontrol.cpp&#58;250&#58;32&#58; error&#58; template argument 1 is invalid
src/enginecontrol.cpp&#58;250&#58;42&#58; error&#58; invalid type in declaration before ';' token
src/enginecontrol.cpp&#58;252&#58;9&#58; error&#58; 'lock_guard' is not a member of 'std'
src/enginecontrol.cpp&#58;252&#58;25&#58; error&#58; 'mutex' is not a member of 'std'
src/enginecontrol.cpp&#58;252&#58;39&#58; error&#58; 'threadMutex' was not declared in this scope
src/enginecontrol.cpp&#58;252&#58;50&#58; error&#58; 'L' was not declared in this scope
src/enginecontrol.cpp&#58;262&#58;17&#58; error&#58; base operand of '->' is not a pointer
make&#58; *** &#91;obj64/enginecontrol.o&#93; Error 1

LZsMacPro-OSX6&#58; ~/Downloads/texel101&#93; g++-mp-4.6 --version
g++-mp-4.6 &#40;GCC&#41; 4.6.3
Copyright &#40;C&#41; 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
User avatar
Graham Banks
Posts: 41423
Joined: Sun Feb 26, 2006 10:52 am
Location: Auckland, NZ

Re: New chess engine: Texel

Post by Graham Banks »

petero2 wrote:Hi,

My new UCI chess engine "Texel" is now available for download from http://web.comhem.se/petero2home/texel101.zip
Thanks Peter. :)
gbanksnz at gmail.com
petero2
Posts: 687
Joined: Mon Apr 19, 2010 7:07 pm
Location: Sweden
Full name: Peter Osterlund

Re: New chess engine: Texel

Post by petero2 »

Unfortunately std::thread is not supported by gcc 4.6 in Mac OS X. See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50196.

That thread also says it should be fixed in 4.7. Any chance you could try that?
Adam Hair
Posts: 3226
Joined: Wed May 06, 2009 10:31 pm
Location: Fuquay-Varina, North Carolina

Re: New chess engine: Texel

Post by Adam Hair »

mar wrote:
petero2 wrote:Thanks Martin

I know +140 sounds impressive, but I believe there is some unknown effect in the test setup that is responsible for this. A 2X speed increase should not be worth more than 70 elo max.

At first I suspected java startup time and time before the JIT compiler had optimized the java bytecode. However I use cutechess-cli to run the tests, and it doesn't restart the engines between games, so this effect should only exist for the first game.
Yes some say it's 50 elo for doubling, most say 70 and some say it's about 100.
Anyway i think even if it's less than 140 at long TC, even 70, it's still impressive.
I recently fixed a couple of nasty bugs but could not improve more than 10 :)
So fingers crossed to surpass Fruit 2.1!
The general effect that has been noticed, but not confirmed, is that the gain in Elo is larger for shorter time controls and decreases as the time control increases.
zullil
Posts: 6442
Joined: Tue Jan 09, 2007 12:31 am
Location: PA USA
Full name: Louis Zulli

Re: New chess engine: Texel

Post by zullil »

petero2 wrote:Unfortunately std::thread is not supported by gcc 4.6 in Mac OS X. See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50196.

That thread also says it should be fixed in 4.7. Any chance you could try that?
Thanks, Peter. Yes, I'll install a version of 4.7 and try again.
Adam Hair
Posts: 3226
Joined: Wed May 06, 2009 10:31 pm
Location: Fuquay-Varina, North Carolina

Re: New chess engine: Texel

Post by Adam Hair »

Thanks Peter. I take interest in the work that you, Martin, and several other authors have done. It is interesting to watch the progression you guys are making.