English version of this file is in the second half of this file.
Jump to English version
- MIT License。
- UCI用チェスエンジン。
- C++11と、その標準ライブラリのみで作成。
- CMakeを使用して簡単にビルドが出来る。
- 静的ライブラリとして使用可能。
- 「
SearchParams」クラス、「EvalParams」クラスの値を変更することで、 探索アルゴリズム、評価関数を自由にカスタマイズすることが出来る。
src: ソースファイルのディレクトリ。SayuriCompiled: コンパイル済みバイナリファイルのディレクトリ。Linux: Linux用バイナリファイルのディレクトリ。For64Bit: 64ビットCPU向けのバイナリファイルのディレクトリ。
Windows: Windows用バイナリファイル。 (Linux版MinGWで作成。)For64Bit: 64ビットCPU向けのバイナリファイルのディレクトリ。
SayuriLogo: ロゴ画像ファイルのディレクトリ。SampleGames: Sayuriとその他のエンジンによるサンプルゲームの ファイルのディレクトリ。
README.md: このファイル。CMakeLists.txt: CMakeのビルド設定ファイル。LICENSE: 使用許諾書。UseAsStaticLibrary.md: Sayuriを静的ライブラリとして使う方法。
CMakeを使って簡単にビルドすることができます。
使用するコンパイラはデフォルトで「clang++」となります。
(コンパイラを変更したいときは、「CMakeLists.txt」の26行目、
27行目のコンパイラ設定を変更してください。)
- 「
CMakeLists.txt」のあるディレクトリに移動します。 - 以下のコマンドを実行します。
$ mkdir build$ cd build$ cmake ..$ make
- 「
build」ディレクト内に以下のファイル、ディレクトリが完成します。sayuri: UCI用チェスエンジン。libsayurilib.a: 静的ライブラリ。include: 静的ライブラリ用ヘッダファイルの入ったディレクトリ。
デバッグモードでビルドすと、「最適化なし」、「デバッグ情報の埋め込み」で ビルドすることができます。
以下の手順2-3で「-DCMAKE_BUILD_TYPE=Debug」を挿入するだけです。
- 「
CMakeLists.txt」のあるディレクトリに移動します。 - 以下のコマンドを実行します。
$ mkdir build$ cd build$ cmake -DCMAKE_BUILD_TYPE=Debug ..$ make
- 「
build」ディレクト内に以下のファイル、ディレクトリが完成します。sayuri: UCI用チェスエンジン。libsayurilib.a: 静的ライブラリ。include: 静的ライブラリ用ヘッダファイルの入ったディレクトリ。
「sayuri」はUCI用チェスエンジンです。
このエンジンを使用する場合は、「libsayurilib.a」と
「include」ディレクトリは必要ありません。
「libsayurilib.a」と「include」はSayuriを静的ライブラリとして
使用する場合に使います。
その場合は「sayuri」は必要ありません。
詳しくは「UseAsStaticLibrary.md」を読んで下さい。
CMakeで「build」内で「Makefile」を作成後、「$ make dist」を実行します。
これで以下の3つの配布用パッケージが出来上がります。
sayuri-xxxx.xx.xx.tar.Zsayuri-xxxx.xx.xx.tar.bz2sayuri-xxxx.xx.xx.tar.gz
((注) 「xxxx.xx.xx」にはバージョン番号が入ります。)
以下のコマンドでエンジンの設定を変更できます。
-
ハッシュテーブルのサイズを変更。 (デフォルトは 32。最大は 8192。最小は 8。)
setoption name Hash value <サイズ、メガバイト> -
ハッシュテーブルを初期化。
setoption name Clear Hash -
Ponderの有効化、無効化。 (デフォルトは true。)
setoption name Ponder value <true、又はfalse> -
探索用スレッドの数を変更。 (デフォルトは 1。最大は 64。最小は 1。)
setoption name Threads value <スレッドの数> -
アナライズモードの有効化、無効化。 (デフォルトは false。)
setoption name UCI_AnalyseMode value <true、又はfalse>
- MIT License.
- A chess engine for UCI.
- Written in C++11 and the standard libraries.
- Easy to build with CMake.
- You can use it as a static library.
- To change "
SearchParams" object or "EvalParams" object, you can freely customize the search algorithm or the static evaluation function.
src: For Sayuri's source files.SayuriCompiled: For Sayuri's binary file.Linux: For binary files for Linux.For64Bit: For 64 bit machines.
Windows: For binary files for Windows. (Created by Linux MinGW.)For64Bit: For 64 bit machines.
SayuriLogo: For the logo image files.SampleGames: For sample game files of Sayuri vs other chess engines.
README.md: This file.CMakeLists.txt: A configuration file for CMake.LICENSE: The software license.UseAsStaticLibrary.md: How to use Sayuri as a static library.
To use CMake, you can build Sayuri easily.
It's default compiler is "clang++".
(If you want to change a compiler, please change 26th line and 27th line
in "CMakeLists.txt".)
- Change directory to where "
CMakeLists.txt" is placed in. - Run the following commands.
$ mkdir build$ cd build$ cmake ..$ make
- The following files or directories have created in "
build" directory.sayuri: A chess engine for UCI.libsayurilib.a: A static library.include: A directory for header files for "libsayurilib.a".
To build in debug mode, you can build Sayuri with "No optimized" and "Embedded the infomation for debugger".
In the following 2-3, insert "-DCMAKE_BUILD_TYPE=Debug" only.
- Change directory to where "
CMakeLists.txt" is placed in. - Run the following commands.
$ mkdir build$ cd build$ cmake -DCMAKE_BUILD_TYPE=Debug ..$ make
- The following files or directories have created in "
build" directory.sayuri: A chess engine for UCI.libsayurilib.a: A static library.include: A directory for header files for "libsayurilib.a".
"sayuri" is a chess engine for UCI.
When you use it, you don't need "libsayurilib.a" and "include".
"libsayurilib.a" and "include" are files for using Sayuri as
a static library.
When you use them, you don't need "sayuri".
Please read "UseAsStaticLibrary.md" for details.
After to make "Makefile" in "build" directory with CMake,
run "$ make dist" command.
If you do so, the following packages have created.
sayuri-xxxx.xx.xx.tar.Zsayuri-xxxx.xx.xx.tar.bz2sayuri-xxxx.xx.xx.tar.gz
(Note: "xxxx.xx.xx" is the version number.)
You can change Sayuri's settings with the following commands.
-
To change size of the hash table. (Default: 32 MB, Max: 8192 MB, Min: 8 MB)
setoption name Hash value <Size(MB)> -
To initialize the hash table.
setoption name Clear Hash -
To enable Ponder. (Default: true)
setoption name Ponder value <true or false> -
To change the number of threads. (Default: 1, Max: 64, Min: 1)
setoption name Threads value <Number of threads> -
To enable analyse mode. (Default: false)
setoption name UCI_AnalyseMode value <true or false>