fairystockfish.git
5 years agoUpdate bot links in readme
Fabian Fichter [Mon, 16 Nov 2020 20:09:23 +0000]
Update bot links in readme

5 years agoFix appveyor build configuration
Fabian Fichter [Sun, 15 Nov 2020 14:28:06 +0000]
Fix appveyor build configuration

5 years agoSimplify compile-time switch for NNUE embedding
Fabian Fichter [Sun, 15 Nov 2020 14:03:01 +0000]
Simplify compile-time switch for NNUE embedding

Disable default net by default instead of disabling Use NNUE.

5 years agoFix NNUE detection for absolute paths
Fabian Fichter [Sun, 15 Nov 2020 13:26:46 +0000]
Fix NNUE detection for absolute paths

Check the file name, not the full path, for prefix with the variant name.

5 years agoSkip NNUE rotation for racing kings
Fabian Fichter [Sat, 14 Nov 2020 18:11:18 +0000]
Skip NNUE rotation for racing kings

5 years agoSupport pondering in CECP
Fabian Fichter [Fri, 30 Oct 2020 18:45:34 +0000]
Support pondering in CECP

Refactor handling of protocol state for CECP and implement pondering.
Improves the protocol compliance of several commands along the way.

Closes #103.

5 years agoUpdate gitignore config
Fabian Fichter [Fri, 13 Nov 2020 17:11:44 +0000]
Update gitignore config

5 years agoUpdate readme
Fabian Fichter [Fri, 13 Nov 2020 00:31:41 +0000]
Update readme

5 years agoMerge official-stockfish/master
Fabian Fichter [Wed, 11 Nov 2020 19:17:25 +0000]
Merge official-stockfish/master

bench: 3828292

5 years agoMake NNUE compatible with basic fairy pieces
Fabian Fichter [Tue, 10 Nov 2020 20:27:15 +0000]
Make NNUE compatible with basic fairy pieces

Re-use existing architecture and map fairy pieces
to their standard chess counterparts.

5 years agoIncrease reduction at root
Joost VandeVondele [Tue, 10 Nov 2020 17:28:43 +0000]
Increase reduction at root

when the best move does not change frequently

STC:
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 51320 W: 5159 L: 4956 D: 41205
Ptnml(0-2): 215, 3897, 17242, 4082, 224
https://tests.stockfishchess.org/tests/view/5faa072367cbf42301d6a767

LTC:
LLR: 2.98 (-2.94,2.94) {0.25,1.25}
Total: 15952 W: 762 L: 642 D: 14548
Ptnml(0-2): 8, 561, 6725, 667, 15
https://tests.stockfishchess.org/tests/view/5faa4c3567cbf42301d6a794

closes https://github.com/official-stockfish/Stockfish/pull/3225

Bench: 3954692

5 years agoIncrease reduction based on the number of best move changes.
lonfom169 [Mon, 9 Nov 2020 02:43:32 +0000]
Increase reduction based on the number of best move changes.

Thanks to Vizvezdenec for the PvNode idea and also to vondele the !PvNode idea.

Passed STC:
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 19120 W: 1998 L: 1839 D: 15283
Ptnml(0-2): 76, 1445, 6375, 1572, 92
https://tests.stockfishchess.org/tests/view/5fa8af3e67cbf42301d6a6c9

Passed LTC:
LLR: 2.94 (-2.94,2.94) {0.25,1.25}
Total: 75584 W: 3454 L: 3205 D: 68925
Ptnml(0-2): 54, 2832, 31771, 3081, 54

closes https://github.com/official-stockfish/Stockfish/pull/3224

Bench: 3595418

5 years agoChanged game header parsing to use quotation marks (Closes #204)
QueensGambit [Sun, 8 Nov 2020 12:33:50 +0000]
Changed game header parsing to use quotation marks (Closes #204)
Added test for loading Seirawan chess pgn
Updated README.md
Updated ffish to 0.4.6

5 years agoAdd Upside-down chess to variants.ini
Fabian Fichter [Sun, 8 Nov 2020 09:23:45 +0000]
Add Upside-down chess to variants.ini

5 years agoQsearch pruning: follow-up
Stéphane Nicolet [Fri, 6 Nov 2020 18:20:27 +0000]
Qsearch pruning: follow-up

This is a follow-up of the recent qsearch pruning patch in
https://github.com/official-stockfish/Stockfish/commit/a260c9a8a24a2630a900efc3821000c3481b0c5d

We now use the same guard condition (testing that we already have a defense with
a score better  score than a TB loss) for all pruning heuristics in qsearch().
This allows some pruning when in check, but  in a controlled way to ensure that
no wrong mate scores appear.

Tested with Elo-gaining bounds:

STC:
LLR: 2.97 (-2.94,2.94) {-0.25,1.25}
Total: 22632 W: 2433 L: 2264 D: 17935
Ptnml(0-2): 98, 1744, 7487, 1865, 122
https://tests.stockfishchess.org/tests/view/5fa59405936c54e11ec99515

LTC:
LLR: 2.94 (-2.94,2.94) {0.25,1.25}
Total: 105432 W: 4965 L: 4648 D: 95819
Ptnml(0-2): 85, 4110, 44011, 4423, 87
https://tests.stockfishchess.org/tests/view/5fa5b609936c54e11ec9952a

closes https://github.com/official-stockfish/Stockfish/pull/3221

Bench: 3578092

5 years agoUpdate default net to nn-c3ca321c51c9.nnue
SFisGOD [Sat, 7 Nov 2020 00:50:02 +0000]
Update default net to nn-c3ca321c51c9.nnue

Optimization of the net biases of the 32 x 32 layer and the output layer.

Tuning of 32 x 32 layer (200k games, 5 seconds TC)
https://tests.stockfishchess.org/tests/view/5f9aaf266a2c112b60691c68

STC:
LLR: 2.95 (-2.94,2.94) {-0.25,1.25}
Total: 41848 W: 4665 L: 4461 D: 32722
Ptnml(0-2): 239, 3308, 13659, 3446, 272
https://tests.stockfishchess.org/tests/view/5fa5ef5a936c54e11ec9954f

LTC:
LLR: 2.94 (-2.94,2.94) {0.25,1.25}
Total: 88008 W: 4045 L: 3768 D: 80195
Ptnml(0-2): 69, 3339, 36908, 3622, 66
https://tests.stockfishchess.org/tests/view/5fa62a78936c54e11ec99577

closes https://github.com/official-stockfish/Stockfish/pull/3220

Bench: 3649288

5 years agoSupport loading multiple variant NNUE files
Fabian Fichter [Sat, 7 Nov 2020 22:47:31 +0000]
Support loading multiple variant NNUE files

Use same separator colon/semicolon as for TB files.

5 years agoAdd patreon link
Fabian Fichter [Sat, 7 Nov 2020 20:52:02 +0000]
Add patreon link

5 years agoDelay adjudication in janggimodern variant
Fabian Fichter [Sat, 7 Nov 2020 20:09:20 +0000]
Delay adjudication in janggimodern variant

5 years agoAVX-512 for smaller affine and feature transforms.
Tomasz Sobczyk [Tue, 3 Nov 2020 21:49:10 +0000]
AVX-512 for smaller affine and feature transforms.

For the feature transformer the code is analogical to AVX2 since there was room for easy adaptation of wider simd registers.

For the smaller affine transforms that have 32 byte stride we keep 2 columns in one zmm register. We also unroll more aggressively so that in the end we have to do 16 parallel horizontal additions on ymm slices each consisting of 4 32-bit integers. The slices are embedded in 8 zmm registers.

These changes provide about 1.5% speedup for AVX-512 builds.

Closes https://github.com/official-stockfish/Stockfish/pull/3218

No functional change.

5 years agoIntroducing King On File
FauziAkram [Wed, 4 Nov 2020 23:54:53 +0000]
Introducing King On File

this new concept calculates bonuses/penalties for the king when the king is in a semiopen or open file.

Passed STC:
LLR: 2.95 (-2.94,2.94) {-0.25,1.25}
Total: 44904 W: 9365 L: 9028 D: 26511
Ptnml(0-2): 857, 5309, 9841, 5530, 915
https://tests.stockfishchess.org/tests/view/5fa343625d72639a7acef72b

Passed LTC:
LLR: 2.94 (-2.94,2.94) {0.25,1.25}
Total: 60552 W: 8449 L: 8051 D: 44052
Ptnml(0-2): 466, 5772, 17481, 6012, 545
https://tests.stockfishchess.org/tests/view/5fa40e365d72639a7acef79e

closes https://github.com/official-stockfish/Stockfish/pull/3219

Bench: 3689484

5 years agoChange handling the special case of a single legal move.
Joost VandeVondele [Fri, 23 Oct 2020 05:39:35 +0000]
Change handling the special case of a single legal move.

Using no searching time in case of a single legal move is not beneficial from
a strength point of view, and this special case can be easily removed:

STC:
LLR: 2.93 (-2.94,2.94) {-1.25,0.25}
Total: 22472 W: 2458 L: 2357 D: 17657
Ptnml(0-2): 106, 1733, 7453, 1842, 102
https://tests.stockfishchess.org/tests/view/5f926cbc81eda81bd78cb6df

LTC:
LLR: 2.94 (-2.94,2.94) {-0.75,0.25}
Total: 37880 W: 1736 L: 1682 D: 34462
Ptnml(0-2): 22, 1392, 16057, 1448, 21
https://tests.stockfishchess.org/tests/view/5f92a26081eda81bd78cb6fe

The advantage of using the normal time management for a single legal move is that scores
reported for that move are reasonable, not searching leads to artifacts during games
(see e.g. https://tcec-chess.com/#div=sf&game=96&season=19)

The disadvantage of using normal time management of a single legal move is that thinking
times can be unnaturally long, making it 'painful to watch' in online tournaments.

This patch uses normal time management, but caps the used time to 500ms.
This should lead to reasonable scores, and be hardly perceptible.

closes https://github.com/official-stockfish/Stockfish/pull/3195
closes https://github.com/official-stockfish/Stockfish/pull/3183

variant of a patch suggested by SFisGOD

No functional change.

5 years agoManually align arrays on the stack
Tomasz Sobczyk [Tue, 3 Nov 2020 10:23:35 +0000]
Manually align arrays on the stack

as a workaround to issues with overaligned alignas() on stack variables in gcc < 9.3 on windows.

closes https://github.com/official-stockfish/Stockfish/pull/3217

fixes #3216

No functional change

5 years agoFix incorrect pruning in qsearch
J. Oster [Sun, 1 Nov 2020 17:33:17 +0000]
Fix incorrect pruning in qsearch

Only do countermove based pruning in qsearch if we already have a move with a better score than a TB loss.

This patch fixes a bug (started as 843a961) that incorrectly prunes moves if in check,
and adds an assert to make sure no wrong mate scores are given in the future.
It replaces a no-op moveCount check with a check for bestValue.

Initially discussed in #3171 and later in #3199, #3198 and #3210.
This PR effectively closes #3171
It also likely fixes #3196 where this causes user visible incorrect TB scores,
which probably result from these incorrect mate scores.

Passed STC and LTC non-regression tests.
https://tests.stockfishchess.org/tests/view/5f9ef8dabca9bf35bae7f648
LLR: 2.93 (-2.94,2.94) {-1.25,0.25}
Total: 21672 W: 2339 L: 2230 D: 17103
Ptnml(0-2): 126, 1689, 7083, 1826, 112

https://tests.stockfishchess.org/tests/view/5f9f0caebca9bf35bae7f666
LLR: 2.97 (-2.94,2.94) {-0.75,0.25}
Total: 33152 W: 1551 L: 1485 D: 30116
Ptnml(0-2): 27, 1308, 13832, 1390, 19

closes https://github.com/official-stockfish/Stockfish/pull/3214

Bench: 3625915

5 years agoElo Worth in King Danger
FauziAkram [Thu, 29 Oct 2020 14:33:18 +0000]
Elo Worth in King Danger

Adding the EloWorth for each term in King Danger.
Should be useful for simplifications, tuning patches, and new ideas.

closes https://github.com/official-stockfish/Stockfish/pull/3204

non-functional change

5 years agoOptimize affine transform for SSSE3 and higher targets.
Tomasz Sobczyk [Wed, 28 Oct 2020 23:14:53 +0000]
Optimize affine transform for SSSE3 and higher targets.

A non-functional speedup. Unroll the loops going over
the output dimensions in the affine transform layers by
a factor of 4 and perform 4 horizontal additions at a time.
Instead of doing naive horizontal additions on each vector
separately use hadd and shuffling between vectors to reduce
the number of instructions by using all lanes for all stages
of the horizontal adds.

passed STC of the initial version:
LLR: 2.95 (-2.94,2.94) {-0.25,1.25}
Total: 17808 W: 1914 L: 1756 D: 14138
Ptnml(0-2): 76, 1330, 5948, 1460, 90
https://tests.stockfishchess.org/tests/view/5f9d516f6a2c112b60691da3

passed STC of the final version after cleanup:
LLR: 2.95 (-2.94,2.94) {-0.25,1.25}
Total: 16296 W: 1750 L: 1595 D: 12951
Ptnml(0-2): 72, 1192, 5479, 1319, 86
https://tests.stockfishchess.org/tests/view/5f9df5776a2c112b60691de3

closes https://github.com/official-stockfish/Stockfish/pull/3203

No functional change

5 years agoUpdate default net to nn-cb26f10b1fd9.nnue
mstembera [Fri, 30 Oct 2020 20:45:40 +0000]
Update default net to nn-cb26f10b1fd9.nnue

Result of https://tests.stockfishchess.org/tests/view/5f9a06796a2c112b60691c0f tuning.

STC
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 53712 W: 5776 L: 5561 D: 42375
Ptnml(0-2): 253, 4282, 17604, 4431, 286
https://tests.stockfishchess.org/tests/view/5f9c7bbc6a2c112b60691d4d

LTC
LLR: 2.97 (-2.94,2.94) {0.25,1.25}
Total: 80184 W: 4007 L: 3739 D: 72438
Ptnml(0-2): 58, 3302, 33130, 3518, 84
https://tests.stockfishchess.org/tests/view/5f9d01f06a2c112b60691d87

closes https://github.com/official-stockfish/Stockfish/pull/3209

bench: 3517795

5 years agoFix failing assertion in losers chess
Fabian Fichter [Sat, 31 Oct 2020 12:24:43 +0000]
Fix failing assertion in losers chess

Prevent non-evasion move generation when in check.

5 years agoFix NNUE for large-board version (#199)
Fabian Fichter [Sat, 31 Oct 2020 10:56:15 +0000]
Fix NNUE for large-board version (#199)

5 years agoReset move repetition on checks
Fabian Fichter [Sat, 31 Oct 2020 08:45:20 +0000]
Reset move repetition on checks

5 years agoAdd FEN validation to pyffish (#87)
Fabian Fichter [Fri, 30 Oct 2020 23:10:38 +0000]
Add FEN validation to pyffish (#87)

5 years agoRemove highlight of passing move in CECP
Fabian Fichter [Fri, 30 Oct 2020 11:04:39 +0000]
Remove highlight of passing move in CECP

Input of passing by king move is invalid, so remove it (#192).

5 years agoOverwrite setup command for Janggi variants
Fabian Fichter [Thu, 29 Oct 2020 19:25:18 +0000]
Overwrite setup command for Janggi variants

Improve compatibility with most recent XBoard version
supporting Janggi as a built-in variant (see #192).

5 years agoMerge official-stockfish/master
Fabian Fichter [Thu, 29 Oct 2020 10:42:31 +0000]
Merge official-stockfish/master

bench: 4282417

5 years agoDo not skip non-recapture ttMove when in check
syzygy1 [Tue, 27 Oct 2020 18:22:41 +0000]
Do not skip non-recapture ttMove when in check

The qsearch() MovePicker incorrectly skips a non-recapture ttMove
when in check (if depth <= DEPTH_QS_RECAPTURES). This is clearly not
intended and can cause qsearch() to return a mate score when there
is no mate. Introduced in cad300c and 6596f0e, as observed by
joergoster in #3171 and #3198.

This PR fixes the bug by not skipping the non-recapture ttMove when in check.

Passed non-regression STC:
https://tests.stockfishchess.org/tests/view/5f9867ea6a2c112b60691b10
LLR: 2.98 (-2.94,2.94) {-1.25,0.25}
Total: 27112 W: 2943 L: 2842 D: 21327
Ptnml(0-2): 127, 2170, 8878, 2237, 144

Passed non-regression LTC:
https://tests.stockfishchess.org/tests/view/5f9967326a2c112b60691bb0
LLR: 2.99 (-2.94,2.94) {-0.75,0.25}
Total: 18392 W: 807 L: 738 D: 16847
Ptnml(0-2): 9, 655, 7802, 718, 12

closes https://github.com/official-stockfish/Stockfish/pull/3199
closes https://github.com/official-stockfish/Stockfish/pull/3198

Bench: 3870606

5 years agoChange CECP pass move to "@@@@"
Fabian Fichter [Wed, 28 Oct 2020 17:33:00 +0000]
Change CECP pass move to "@@@@"

5 years agoFix CECP error message for illegal moves
Fabian Fichter [Wed, 28 Oct 2020 17:20:58 +0000]
Fix CECP error message for illegal moves

Closes #203.

5 years agoUpdate default net to nn-2eb2e0707c2b.nnue
SFisGOD [Tue, 27 Oct 2020 20:24:55 +0000]
Update default net to nn-2eb2e0707c2b.nnue

Optimization of the net weights of the 32 x 32 layer (1024 parameters) and net biases of the 512 x 32 layer (32 parameters) using SPSA.

Tuning of 32 x 32 Layer (800,000 games, 5 seconds time control):
https://tests.stockfishchess.org/tests/view/5f942040d3978d7e86f1aa05

Tuning of 512 x 32 Layer (80,000 games, 20 seconds time control):
https://tests.stockfishchess.org/tests/view/5f8f926d2c92c7fe3a8c608b

STC:
LLR: 2.96 (-2.94,2.94) {-0.25,1.25}
Total: 17336 W: 1918 L: 1754 D: 13664
Ptnml(0-2): 79, 1344, 5672, 1480, 93
https://tests.stockfishchess.org/tests/view/5f9882346a2c112b60691b34

LTC:
LLR: 2.94 (-2.94,2.94) {0.25,1.25}
Total: 37304 W: 1822 L: 1651 D: 33831
Ptnml(0-2): 27, 1461, 15501, 1640, 23
https://tests.stockfishchess.org/tests/view/5f98a4b36a2c112b60691b40

closes https://github.com/official-stockfish/Stockfish/pull/3201

Bench: 3403528

5 years agoBishop Pawns based on Files
FauziAkram [Fri, 23 Oct 2020 23:01:04 +0000]
Bishop Pawns based on Files

Passed STC:
https://tests.stockfishchess.org/tests/view/5f8cc8145a4eacb45305da3c
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 132544 W: 27795 L: 27328 D: 77421
Ptnml(0-2): 2756, 15558, 29272, 15835, 2851

Passed LTC:
https://tests.stockfishchess.org/tests/view/5f8df614bacb75a4f9a4721e
LLR: 2.94 (-2.94,2.94) {0.25,1.25}
Total: 169608 W: 23257 L: 22622 D: 123729
Ptnml(0-2): 1408, 16316, 48758, 16877, 1445

closes https://github.com/official-stockfish/Stockfish/pull/3194

Bench: 4067106

5 years agoSupport Kakao Janggi repetition rules
Fabian Fichter [Tue, 27 Oct 2020 18:29:36 +0000]
Support Kakao Janggi repetition rules

Closes #198 and #142.

5 years agoTweak horde space bonus
Fabian Fichter [Mon, 26 Oct 2020 07:51:30 +0000]
Tweak horde space bonus

horde STC
LLR: 2.96 (-2.94,2.94) [0.00,10.00]
Total: 464 W: 283 L: 175 D: 6
http://www.variantfishtest.org:6543/tests/view/5f954c276e23db221d9e9394

horde LTC
LLR: 2.95 (-2.94,2.94) [0.00,10.00]
Total: 969 W: 540 L: 424 D: 5
http://www.variantfishtest.org:6543/tests/view/5f9574466e23db221d9e9397

5 years agoDisable scale factor for Janggi
Fabian Fichter [Sun, 25 Oct 2020 17:10:47 +0000]
Disable scale factor for Janggi

janggi
LLR: 3.00 (-2.94,2.94) [0.00,10.00]
Total: 1304 W: 693 L: 573 D: 38

5 years agoTweak horde chess evaluation
Fabian Fichter [Sat, 24 Oct 2020 16:00:50 +0000]
Tweak horde chess evaluation

horde STC
LLR: 2.97 (-2.94,2.94) [0.00,10.00]
Total: 5975 W: 3049 L: 2861 D: 65
http://www.variantfishtest.org:6543/tests/view/5f92cb296e23db221d9e936b

horde LTC
LLR: 2.95 (-2.94,2.94) [0.00,10.00]
Total: 3220 W: 1671 L: 1523 D: 26
http://www.variantfishtest.org:6543/tests/view/5f935c4e6e23db221d9e9381

5 years agoTweak NMP depth for losing chess
Fabian Fichter [Sat, 24 Oct 2020 09:37:10 +0000]
Tweak NMP depth for losing chess

giveaway STC
LLR: 2.95 (-2.94,2.94) [0.00,10.00]
Total: 1259 W: 523 L: 424 D: 312
http://www.variantfishtest.org:6543/tests/view/5f93432e6e23db221d9e9373

giveaway LTC
LLR: 2.95 (-2.94,2.94) [0.00,10.00]
Total: 1092 W: 430 L: 337 D: 325
http://www.variantfishtest.org:6543/tests/view/5f93603b6e23db221d9e9384

5 years agoIncrease NMP margin for slow variants
Fabian Fichter [Sat, 24 Oct 2020 09:29:46 +0000]
Increase NMP margin for slow variants

makruk STC
LLR: 2.98 (-2.94,2.94) [0.00,10.00]
Total: 1864 W: 182 L: 118 D: 1564
http://www.variantfishtest.org:6543/tests/view/5f8e86a46e23db221d9e9312

makruk LTC
LLR: 2.99 (-2.94,2.94) [0.00,10.00]
Total: 1277 W: 108 L: 49 D: 1120
http://www.variantfishtest.org:6543/tests/view/5f92a9756e23db221d9e9356

shatranj STC
LLR: 2.96 (-2.94,2.94) [0.00,10.00]
Total: 1688 W: 195 L: 130 D: 1363
http://www.variantfishtest.org:6543/tests/view/5f8dfcbf6e23db221d9e9306

shatranj LTC
LLR: 3.53 (-2.94,2.94) [0.00,10.00]
Total: 1293 W: 134 L: 63 D: 1096
http://www.variantfishtest.org:6543/tests/view/5f912df66e23db221d9e9335

losalamos STC
LLR: 2.96 (-2.94,2.94) [0.00,10.00]
Total: 2926 W: 731 L: 634 D: 1561
http://www.variantfishtest.org:6543/tests/view/5f8fd6d06e23db221d9e9322

5 years agoBreakthrough bonus for horde chess
Fabian Fichter [Fri, 23 Oct 2020 10:07:20 +0000]
Breakthrough bonus for horde chess

horde STC
LLR: 2.97 (-2.94,2.94) [0.00,10.00]
Total: 783 W: 443 L: 330 D: 10
http://www.variantfishtest.org:6543/tests/view/5f91d5366e23db221d9e9342

horde LTC
LLR: 2.95 (-2.94,2.94) [0.00,10.00]
Total: 644 W: 375 L: 264 D: 5
http://www.variantfishtest.org:6543/tests/view/5f91ee7f6e23db221d9e9345

5 years agoEvaluate horde imbalance
Fabian Fichter [Fri, 23 Oct 2020 10:04:43 +0000]
Evaluate horde imbalance

horde STC
LLR: 2.96 (-2.94,2.94) [0.00,10.00]
Total: 570 W: 337 L: 227 D: 6
http://www.variantfishtest.org:6543/tests/view/5f91bada6e23db221d9e933c

horde LTC
LLR: 2.96 (-2.94,2.94) [0.00,10.00]
Total: 592 W: 347 L: 237 D: 8
http://www.variantfishtest.org:6543/tests/view/5f91cf096e23db221d9e9340

5 years agoMore incremental accumulator updates
syzygy1 [Tue, 20 Oct 2020 19:06:06 +0000]
More incremental accumulator updates

This patch was inspired by c065abd which updates the accumulator,
if possible, based on the accumulator of two plies back if
the accumulator of the preceding ply is not available.

With this patch we look back even further in the position history
in an attempt to reduce the number of complete recomputations.
When we find a usable accumulator for the position N plies back,
we also update the accumulator of the position N-1 plies back
because that accumulator is most likely to be helpful later
when evaluating positions in sibling branches.
By not updating all intermediate accumulators immediately,
we avoid doing too much work that is not certain to be useful.
Overall, roughly 2-3% speedup.

This patch makes the code more specific to the net architecture,
changing input features of the net will require additional changes
to the incremental update code as discussed in the PR #3193 and #3191.

Passed STC:
https://tests.stockfishchess.org/tests/view/5f9056712c92c7fe3a8c60d0
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 10040 W: 1116 L: 968 D: 7956
Ptnml(0-2): 42, 722, 3365, 828, 63

closes https://github.com/official-stockfish/Stockfish/pull/3193

No functional change.

5 years agoAdd net as dependency of config
Joost VandeVondele [Sun, 18 Oct 2020 13:01:19 +0000]
Add net as dependency of config

cleaner output and error message if the server is down and the net is not available.

closes https://github.com/official-stockfish/Stockfish/pull/3188

No functional change

5 years agoReduce big time spikes by reducing PV re-searches.
xoto10 [Wed, 21 Oct 2020 13:52:13 +0000]
Reduce big time spikes by reducing PV re-searches.

Save time by reducing PV re-searches above original depth. Instead use 5% extra time on every move.

STC 10+0.1 th 1 :
LLR: 2.93 (-2.94,2.94) {-0.25,1.25}
Total: 90688 W: 9702 L: 9436 D: 71550
Ptnml(0-2): 408, 7252, 29792, 7450, 442
https://tests.stockfishchess.org/tests/view/5f8df807bacb75a4f9a47223

LTC 60+0.6 th 1 :
LLR: 2.97 (-2.94,2.94) {0.25,1.25}
Total: 97856 W: 4602 L: 4303 D: 88951
Ptnml(0-2): 53, 3757, 41057, 3960, 101
https://tests.stockfishchess.org/tests/view/5f8ec4872c92c7fe3a8c602d

closes https://github.com/official-stockfish/Stockfish/pull/3192

Bench 3943959

5 years agoUpgrade ffish.js to 0.4.4 and add validate_fen
Johannes Czech [Wed, 21 Oct 2020 22:51:47 +0000]
Upgrade ffish.js to 0.4.4 and add validate_fen

* Upgraded ffish.js to 0.4.4
+ validate_fen(const std::string& fen, const Variant* v) (Closes #87)
+ ffish.validate_fen(fen)
+ ffish.validate_fen(fen, uciVariant)
+ ffish.startingFen(uciVariant)
+ board.pocket(turn)

Refactoring
+ replaced bool first = true by save_pop_back(string& s)
+ replaced string = " " + s; by string += " "; string += s;

updated README.md
+ simplified memory specification

* Added C++17 specification for building ffish.js
+ updated ffish.js to 0.4.4

* Added more checks to validate_fen()
+ FEN_TOUCHING_KINGS
+ replaced FEN_INVALID_CHECK_COUNTER by FEN_INVALID_NUMBER_OF_KINGS
+ combined FEN_FILE_SIZE_MISMATCH and FEN_INVALID_NUMBER_OF_RANKS into
FEN_INVALID_BOARD_GEOMETRY
+ added more checks for FEN_INVALID_CASTLING_INFO

added struct CharSquare
added class CharBoard (for geometry checks)
refactored different checks into separate functions

5 years agoCleaner definition of piece types
Fabian Fichter [Tue, 20 Oct 2020 16:58:48 +0000]
Cleaner definition of piece types

No functional change.

5 years agoRevert wrong extern constexpr
Fabian Fichter [Sun, 18 Oct 2020 21:22:11 +0000]
Revert wrong extern constexpr

5 years agoFix NNUE piece indeces
Fabian Fichter [Sun, 18 Oct 2020 20:50:54 +0000]
Fix NNUE piece indeces

5 years agoMerge official-stockfish/master
Fabian Fichter [Sun, 18 Oct 2020 18:40:07 +0000]
Merge official-stockfish/master

- Updates language standard to C++17.
- Includes merge of NNUE code.
  - NNUE embedding is disabled by default
  - Variant name is matched against NN file name to detect support

bench: 4170106

5 years agoDo more reductions for late quiet moves in case of consecutive fail highs.
Vizvezdenec [Sat, 17 Oct 2020 11:40:10 +0000]
Do more reductions for late quiet moves in case of consecutive fail highs.

Idea of this patch can be described as following - in case we have consecutive fail highs and we reach late enough moves at root node probability of remaining quiet moves being able to produce even bigger value than moves that produced previous cutoff (so ones that should be high in move ordering but now they fail to produce beta cutoff because we actually reached high move count) should be quiet small so we can reduce them more.

passed STC
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 53392 W: 5681 L: 5474 D: 42237
Ptnml(0-2): 214, 4104, 17894, 4229, 255
https://tests.stockfishchess.org/tests/view/5f88501adcdad978fe8c527e

passed LTC
LLR: 2.94 (-2.94,2.94) {0.25,1.25}
Total: 59136 W: 2773 L: 2564 D: 53799
Ptnml(0-2): 30, 2117, 25078, 2300, 43
https://tests.stockfishchess.org/tests/view/5f884dbfdcdad978fe8c527a

closes https://github.com/official-stockfish/Stockfish/pull/3184

Bench: 4066972

5 years agoUpdate default net to nn-eba324f53044.nnue
mstembera [Sun, 18 Oct 2020 11:23:28 +0000]
Update default net to nn-eba324f53044.nnue

The new net is based on the previous net 04cf2b4ed1da but with the biases
for the 1st hidden layer tuned SPSA, see the SPSA session on fishtest there:
https://tests.stockfishchess.org/tests/view/5f875213dcdad978fe8c5211

Thanks to @vondele for writing out the net, see discussion in this thread:
https://github.com/mstembera/Stockfish/commit/432da86721647dff1d9426a7cdcfd2dbada8155e

Passed STC:
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 15000 W: 1640 L: 1483 D: 11877
Ptnml(0-2): 50, 1183, 4908, 1278, 81
https://tests.stockfishchess.org/tests/view/5f8955e20fea1a44ec4f0a5d

Passed LTC:
LLR: 2.96 (-2.94,2.94) {0.25,1.25}
Total: 81272 W: 3948 L: 3682 D: 73642
Ptnml(0-2): 64, 3194, 33856, 3456, 66
https://tests.stockfishchess.org/tests/view/5f89e8efeae8a6e60644d6e7

closes https://github.com/official-stockfish/Stockfish/pull/3187

Bench: 3762411

5 years agoFix compiler warning
Fabian Fichter [Sat, 17 Oct 2020 22:56:19 +0000]
Fix compiler warning

No functional change.

5 years agoSupport Chaturanga
Fabian Fichter [Sat, 17 Oct 2020 22:23:21 +0000]
Support Chaturanga

https://en.wikipedia.org/wiki/Chaturanga

The exact historic rules of this game are unknown.
This implementations follows the rules from chess.com.

5 years agoScale factor tweak
Unai Corzo [Mon, 12 Oct 2020 07:03:49 +0000]
Scale factor tweak

Add !pawnsOnBothFlanks heuristic to scale factor.

STC https://tests.stockfishchess.org/tests/view/5f8080575b3847b5d41f9134
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 250960 W: 49779 L: 49168 D: 152013
Ptnml(0-2): 4224, 28822, 58802, 29383, 4249

LTC https://tests.stockfishchess.org/tests/view/5f832f498ea73fb8ddf83ddb
LLR: 2.95 (-2.94,2.94) {0.25,1.25}
Total: 88584 W: 11827 L: 11388 D: 65369
Ptnml(0-2): 585, 8079, 26578, 8412, 638

closes https://github.com/official-stockfish/Stockfish/pull/3179

bench: 3834252

5 years agoRookOnQueenFile Removal
FauziAkram [Tue, 6 Oct 2020 19:43:48 +0000]
RookOnQueenFile Removal

Removing Rook On Queen File looks beneficial, and it might even bring some ELO.
I will try to reintroduce it with a different method later on.

Passed STC:
https://tests.stockfishchess.org/tests/view/5f7cea204389873867eb10cb
LLR: 2.94 (-2.94,2.94) {-1.25,0.25}
Total: 18624 W: 3800 L: 3568 D: 11256
Ptnml(0-2): 308, 2131, 4257, 2253, 363

Passed LTC:
https://tests.stockfishchess.org/tests/view/5f7d76a4e936c6892bf50598
LLR: 2.95 (-2.94,2.94) {-0.75,0.25}
Total: 117864 W: 15515 L: 15340 D: 87009
Ptnml(0-2): 926, 11127, 34671, 11262, 946

closes https://github.com/official-stockfish/Stockfish/pull/3176

Bench: 3756191

5 years agoUpdate default net to nn-04cf2b4ed1da.nnue
Joost VandeVondele [Wed, 14 Oct 2020 08:23:30 +0000]
Update default net to nn-04cf2b4ed1da.nnue

Further tune the net parameters, now the last but one layer (32x32).
To limit the number of parameters optimized, the network layer was
decomposed using SVD, and the singular values were treated
as parameters and tuned.

Tuning branch: https://github.com/vondele/Stockfish/tree/svdTune
Tuner: https://github.com/vondele/nevergrad4sf

passed STC:
https://tests.stockfishchess.org/tests/view/5f83e82f8ea73fb8ddf83e4e
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 8488 W: 944 L: 795 D: 6749
Ptnml(0-2): 39, 609, 2811, 734, 51

passed LTC:
https://tests.stockfishchess.org/tests/view/5f83f4118ea73fb8ddf83e66
LLR: 2.94 (-2.94,2.94) {0.25,1.25}
Total: 169016 W: 8043 L: 7589 D: 153384
Ptnml(0-2): 133, 6623, 70538, 7085, 129

closes https://github.com/official-stockfish/Stockfish/pull/3181

Bench: 3945198

5 years agoAdd sponsor button
Fabian Fichter [Mon, 12 Oct 2020 22:02:33 +0000]
Add sponsor button

5 years agoFix typo in error message
Fabian Fichter [Fri, 9 Oct 2020 21:13:00 +0000]
Fix typo in error message

5 years agoPawn Tuning
FauziAkram [Fri, 2 Oct 2020 12:32:19 +0000]
Pawn Tuning

Tuning of pawns, for classical evaluation:

Passed STC:
https://tests.stockfishchess.org/tests/view/5f771f0e52560f5fc78559ec
LLR: 2.96 (-2.94,2.94) {-0.25,1.25}
Total: 252696 W: 50321 L: 49692 D: 152683
Ptnml(0-2): 4614, 29845, 57049, 29978, 4862

Passed LTC:
https://tests.stockfishchess.org/tests/view/5f77cfef090dcf9aaa16d38b
LLR: 2.94 (-2.94,2.94) {0.25,1.25}
Total: 48184 W: 6556 L: 6193 D: 35435
Ptnml(0-2): 335, 4516, 14100, 4733, 408

closes https://github.com/official-stockfish/Stockfish/pull/3169

bench: 4016121

5 years agoSimplify away futility pruning for captures
Unai Corzo [Fri, 2 Oct 2020 20:00:55 +0000]
Simplify away futility pruning for captures

Remove futility pruning for captures.

STC https://tests.stockfishchess.org/tests/view/5f749bfed930428c36d34c56
LLR: 2.94 (-2.94,2.94) {-1.25,0.25}
Total: 38064 W: 4011 L: 3929 D: 30124
Ptnml(0-2): 192, 3004, 12567, 3068, 201

LTC https://tests.stockfishchess.org/tests/view/5f74d99bf18675b1ce2f7412
LLR: 2.94 (-2.94,2.94) {-0.75,0.25}
Total: 184984 W: 8567 L: 8610 D: 167807
Ptnml(0-2): 146, 7593, 77058, 7548, 147

closes https://github.com/official-stockfish/Stockfish/pull/3166

bench: 3890648

5 years agoSchedule threads fairly under valgrind
Joost VandeVondele [Wed, 30 Sep 2020 19:22:36 +0000]
Schedule threads fairly under valgrind

fixes a rare case that can cause CI to fail when running multithreaded under valgrind.

closes https://github.com/official-stockfish/Stockfish/pull/3165

No functional change.

5 years agoSupport parsing variant config string in pyffish
Fabian Fichter [Sat, 3 Oct 2020 20:47:23 +0000]
Support parsing variant config string in pyffish

5 years agoRemove blocked shogi pawns from mobility area
Fabian Fichter [Fri, 2 Oct 2020 09:34:06 +0000]
Remove blocked shogi pawns from mobility area

shogi STC
LLR: 2.96 (-2.94,2.94) [0.00,10.00]
Total: 10872 W: 5545 L: 5286 D: 41
http://www.variantfishtest.org:6543/tests/view/5f6253786e23db221d9e91b8

shogi LTC
LLR: 2.96 (-2.94,2.94) [0.00,10.00]
Total: 17489 W: 8874 L: 8520 D: 95
http://www.variantfishtest.org:6543/tests/view/5f645f406e23db221d9e91c1

5 years agoTweak shogi piece promotion bonus
Fabian Fichter [Fri, 2 Oct 2020 09:31:14 +0000]
Tweak shogi piece promotion bonus

shogi STC (failed)
LLR: -2.97 (-2.94,2.94) [0.00,10.00]
Total: 7135 W: 3552 L: 3552 D: 31
http://www.variantfishtest.org:6543/tests/view/5f51377b6e23db221d9e9065

shogi LTC
LLR: 2.96 (-2.94,2.94) [0.00,10.00]
Total: 14354 W: 7294 L: 6985 D: 75
http://www.variantfishtest.org:6543/tests/view/5f65a4de6e23db221d9e91cc

5 years agoUpdated ffish.js to 0.4.2 (Closes #185)
QueensGambit [Wed, 30 Sep 2020 08:40:06 +0000]
Updated ffish.js to 0.4.2 (Closes #185)
+ board.moveStack()
+ board.pushSan(sanMove, notation)
+ board.pushMoves(uciMoves)
+ board.pushSanMoves(sanMoves)
+ board.pushSanMoves(sanMoves, notation)
+ ffish.readGamePGN(pgn)
+ game.headerKeys()
+ game.headers(key)
+ game.mainlineMoves()
+ ffish.variants()
+ ffish.loadVariantConfig()

Added parse_istream()
+ to allow reading a variant configuration file via a stringstream

Added NO_THREADS #define
+ to disable threads usage for build

Added custom variants info to README.md

Changed ordering for ffish.loadVariantsConfig() in test.js

5 years agoInclude pawns in NNUE scaling
Stéphane Nicolet [Mon, 28 Sep 2020 20:32:55 +0000]
Include pawns in NNUE scaling

We now include the total pawn count in the scaling factor for the output
of the NNUE evaluation network. This should have the effect of trying to
keep more pawns when SF has the advantage, but exchange them when she
is defending.

Thanks to Alexander Pagel (Lolligerhans) for the idea of using the
value of pawns to ease the comparison with the rest of the material
estimation.

Passed STC:
LLR: 2.93 (-2.94,2.94) {-0.25,1.25}
Total: 15072 W: 1700 L: 1539 D: 11833
Ptnml(0-2): 65, 1202, 4845, 1355, 69
https://tests.stockfishchess.org/tests/view/5f7235a63b22d6afa50699b3

Passed LTC:
LLR: 2.93 (-2.94,2.94) {0.25,1.25}
Total: 25880 W: 1270 L: 1124 D: 23486
Ptnml(0-2): 23, 980, 10788, 1126, 23
https://tests.stockfishchess.org/tests/view/5f723b483b22d6afa5069a99

closes https://github.com/official-stockfish/Stockfish/pull/3164

Bench: 3776081

5 years agoTweak reduction formula.
Stefan Geschwentner [Mon, 28 Sep 2020 20:21:14 +0000]
Tweak reduction formula.

Replace log(i) with log(i + 0.25 * log(i)). This increases especially for low values the reductions. But for bigger values there are nearly no changes.

STC:
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 49640 W: 5505 L: 5289 D: 38846
Ptnml(0-2): 270, 4074, 15924, 4274, 278
https://tests.stockfishchess.org/tests/view/5f71f04d3b22d6afa5069478

LTC:
LLR: 2.94 (-2.94,2.94) {0.25,1.25}
Total: 43856 W: 2209 L: 2021 D: 39626
Ptnml(0-2): 32, 1776, 18128, 1956, 36
https://tests.stockfishchess.org/tests/view/5f7232ee3b22d6afa50699a2

closes https://github.com/official-stockfish/Stockfish/pull/3163

Bench: 3555769

5 years agoUpdate default net to nn-baeb9ef2d183.nnue
SFisGOD [Mon, 28 Sep 2020 18:24:26 +0000]
Update default net to nn-baeb9ef2d183.nnue

Further optimization of Sergio's nn-03744f8d56d8.nnue
This patch is the result of collaboration with Joost VandeVondele.

STC:
LLR: 2.96 (-2.94,2.94) {-0.25,1.25}
Total: 37000 W: 4145 L: 3947 D: 28908
Ptnml(0-2): 191, 3016, 11912, 3166, 215
https://tests.stockfishchess.org/tests/view/5f71e7983b22d6afa5069475

LTC:
LLR: 2.96 (-2.94,2.94) {0.25,1.25}
Total: 60224 W: 2992 L: 2769 D: 54463
Ptnml(0-2): 48, 2420, 24956, 2637, 51
https://tests.stockfishchess.org/tests/view/5f722bb83b22d6afa506998f

closes https://github.com/official-stockfish/Stockfish/pull/3161

Bench: 3720073

5 years agoTweaking Mobility and Safe Check
FauziAkram [Mon, 28 Sep 2020 19:09:43 +0000]
Tweaking Mobility and Safe Check

Passed STC:
https://tests.stockfishchess.org/tests/view/5f70d86d3b22d6afa50693b9
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 100368 W: 20323 L: 19914 D: 60131
Ptnml(0-2): 1927, 11641, 22605, 12118, 1893

Passed LTC:
https://tests.stockfishchess.org/tests/view/5f71bb553b22d6afa5069457
LLR: 2.94 (-2.94,2.94) {0.25,1.25}
Total: 77648 W: 10613 L: 10181 D: 56854
Ptnml(0-2): 634, 7280, 22594, 7652, 664

closes https://github.com/official-stockfish/Stockfish/pull/3160

Bench: 3861984

5 years agoAdjust null move pruning constants
Vizvezdenec [Mon, 28 Sep 2020 17:20:06 +0000]
Adjust null move pruning constants

Idea is that division by fraction of 2 is slightly faster than by other numbers so parameters are adjusted in a way that division in null move pruning depth reduction features dividing by 256 instead of dividing by 213.
Other than this patch is almost non-functional - difference starts to exist by depth 133.

passed STC
https://tests.stockfishchess.org/tests/view/5f70dd943b22d6afa50693c5
LLR: 2.95 (-2.94,2.94) {-0.25,1.25}
Total: 57048 W: 6616 L: 6392 D: 44040
Ptnml(0-2): 304, 4583, 18531, 4797, 309

passed LTC
https://tests.stockfishchess.org/tests/view/5f7180db3b22d6afa506941f
LLR: 2.95 (-2.94,2.94) {0.25,1.25}
Total: 45960 W: 2419 L: 2229 D: 41312
Ptnml(0-2): 43, 1779, 19137, 1987, 34

closes https://github.com/official-stockfish/Stockfish/pull/3159

bench 3789924

5 years agoUpdate default net to nn-04a843f8932e.nnue
Joost VandeVondele [Sat, 26 Sep 2020 15:47:52 +0000]
Update default net to nn-04a843f8932e.nnue

an optimization of Sergio's nn-03744f8d56d8.nnue tuning the output layer (33 parameters) on game play.

WIP code to make layer parameters tunable is https://github.com/vondele/Stockfish/tree/optionOutput
Optimization itself is using https://github.com/vondele/nevergrad4sf
Writing of the modified net using WIP code based on the learner code https://github.com/vondele/Stockfish/tree/evalWrite

Most parameters in the output layer are changed only little (~5 for int8_t).

passed STC:
https://tests.stockfishchess.org/tests/view/5f716f6b3b22d6afa506941a
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 15488 W: 1859 L: 1689 D: 11940
Ptnml(0-2): 79, 1260, 4917, 1388, 100

passed LTC:
https://tests.stockfishchess.org/tests/view/5f71908e3b22d6afa506942e
LLR: 2.93 (-2.94,2.94) {0.25,1.25}
Total: 8728 W: 518 L: 400 D: 7810
Ptnml(0-2): 7, 338, 3556, 456, 7

closes https://github.com/official-stockfish/Stockfish/pull/3158

Bench: 3789924

5 years agoUse incremental updates more often
noobpwnftw [Sun, 27 Sep 2020 18:29:21 +0000]
Use incremental updates more often

Use incremental updates for accumulators for up to 2 plies.
Do not copy accumulator. About 2% speedup.

Passed STC:
LLR: 2.95 (-2.94,2.94) {-0.25,1.25}
Total: 21752 W: 2583 L: 2403 D: 16766
Ptnml(0-2): 128, 1761, 6923, 1931, 133
https://tests.stockfishchess.org/tests/view/5f7150cf3b22d6afa5069412

closes https://github.com/official-stockfish/Stockfish/pull/3157

No functional change

5 years agoTweak nnue scaling to keep more material
Stéphane Nicolet [Sat, 26 Sep 2020 21:19:53 +0000]
Tweak nnue scaling to keep more material

Current master uses a constant scale factor of 5/4 = 1.25 for the output
of the NNUE network, for compatibility with search and classical evaluation.
We modify this scale factor to make it dependent on the phase of the game,
going from about 1.5 in the opening to 1.0 for pure pawn endgames.

This helps Stockfish to avoid exchanges of pieces (heavy pieces in particular)
when she has the advantage, keeping more material on the board when attacking.

Passed STC:
LLR: 2.95 (-2.94,2.94) {-0.25,1.25}
Total: 14744 W: 1771 L: 1599 D: 11374
Ptnml(0-2): 87, 1184, 4664, 1344, 93
https://tests.stockfishchess.org/tests/view/5f6fb0a63b22d6afa506904f

Passed LTC:
LLR: 2.95 (-2.94,2.94) {0.25,1.25}
Total: 8912 W: 512 L: 393 D: 8007
Ptnml(0-2): 7, 344, 3637, 459, 9
https://tests.stockfishchess.org/tests/view/5f6fcf533b22d6afa5069066

closes https://github.com/official-stockfish/Stockfish/pull/3154

Bench: 3943952

5 years agoAdd more moderate variants to variants.ini
Fabian Fichter [Sat, 26 Sep 2020 10:43:42 +0000]
Add more moderate variants to variants.ini

5 years agoAdjust endgame evaluation for KSSK
Fabian Fichter [Sat, 26 Sep 2020 09:43:54 +0000]
Adjust endgame evaluation for KSSK

makruk
LLR: 2.97 (-2.94,2.94) [-10.00,5.00]
Total: 12891 W: 944 L: 932 D: 11015
http://www.variantfishtest.org:6543/tests/view/5f5ded636e23db221d9e9184

5 years agoSwitch to NNUE eval probabilistically for OCB
SFisGOD [Wed, 23 Sep 2020 06:00:42 +0000]
Switch to NNUE eval probabilistically for OCB

Introduce a small chance of switching to NNUE if PSQ imbalance is large but we have opposite colored bishops and the classical eval is struggling to win.

STC:
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 25304 W: 3179 L: 2983 D: 19142
Ptnml(0-2): 172, 2171, 7781, 2345, 183
https://tests.stockfishchess.org/tests/view/5f6b14dec7759d4ee307cfe3

LTC:
LLR: 2.94 (-2.94,2.94) {0.25,1.25}
Total: 84680 W: 4846 L: 4556 D: 75278
Ptnml(0-2): 89, 3933, 34011, 4213, 94
https://tests.stockfishchess.org/tests/view/5f6b3fb6c7759d4ee307cff9

closes https://github.com/official-stockfish/Stockfish/pull/3146

Bench: 3865413

5 years agoSuppress info strings before 'uci'
Stéphane Nicolet [Thu, 24 Sep 2020 09:38:35 +0000]
Suppress info strings before 'uci'

On Windows, Stockfish wouldn't launch in some GUI because we output some
info strings (about the use of large pages) before sending the 'uci'
command. It seems more robust to suppress these info strings, and instead
to add a proper section section in the Readme about large pages use.

fixes https://github.com/official-stockfish/Stockfish/issues/3052
closes https://github.com/official-stockfish/Stockfish/pull/3147

No functional change

5 years agoReturn to development version
Fabian Fichter [Thu, 24 Sep 2020 10:38:05 +0000]
Return to development version

5 years agoFairy-Stockfish 11.2
Fabian Fichter [Wed, 23 Sep 2020 07:39:22 +0000]
Fairy-Stockfish 11.2

bench: 4262221

5 years agoIncrease reductions with the number of threads
Stéphane Nicolet [Tue, 22 Sep 2020 20:43:41 +0000]
Increase reductions with the number of threads

Passed STC with 8 threads:
LLR: 2.92 (-2.94,2.94) {-0.25,1.25}
Total: 13520 W: 1135 L: 1012 D: 11373
Ptnml(0-2): 39, 815, 4929, 938, 39
https://tests.stockfishchess.org/tests/view/5f68e274ded68c240be73f41

Passed LTC with 8 threads:
LLR: 2.96 (-2.94,2.94) {0.25,1.25}
Total: 48384 W: 2183 L: 1994 D: 44207
Ptnml(0-2): 28, 1777, 20402, 1948, 37
https://tests.stockfishchess.org/tests/view/5f68f068ded68c240be747e9

closes https://github.com/official-stockfish/Stockfish/pull/3142

No functional change (for one thread)

5 years agoFix move time for CECP
Fabian Fichter [Mon, 21 Sep 2020 15:22:13 +0000]
Fix move time for CECP

Ensure full usage of time specified by `st`.

5 years agoSmall cleanups 12
Stéphane Nicolet [Wed, 9 Sep 2020 08:49:31 +0000]
Small cleanups 12

- Clean signature of functions in namespace NNUE
- Add comment for countermove based pruning
- Remove bestMoveCount variable
- Add const qualifier to kpp_board_index array
- Fix spaces in get_best_thread()
- Fix indention in capture LMR code in search.cpp
- Rename TtmemDeleter to LargePageDeleter

Closes https://github.com/official-stockfish/Stockfish/pull/3063

No functional change

5 years agoAdd large page support for NNUE weights and simplify TT mem management
Sami Kiminki [Sun, 30 Aug 2020 16:41:30 +0000]
Add large page support for NNUE weights and simplify TT mem management

Use TT memory functions to allocate memory for the NNUE weights. This
should provide a small speed-up on systems where large pages are not
automatically used, including Windows and some Linux distributions.

Further, since we now have a wrapper for std::aligned_alloc(), we can
simplify the TT memory management a bit:

- We no longer need to store separate pointers to the hash table and
  its underlying memory allocation.
- We also get to merge the Linux-specific and default implementations
  of aligned_ttmem_alloc().

Finally, we'll enable the VirtualAlloc code path with large page
support also for Win32.

STC: https://tests.stockfishchess.org/tests/view/5f66595823a84a47b9036fba
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 14896 W: 1854 L: 1686 D: 11356
Ptnml(0-2): 65, 1224, 4742, 1312, 105

closes https://github.com/official-stockfish/Stockfish/pull/3081

No functional change.

5 years agoTweak hybrid treshold.
Stefan Geschwentner [Sun, 20 Sep 2020 20:25:19 +0000]
Tweak hybrid treshold.

Increase the first hybrid threshold with more material.
Rewrite the hybrid rules for clarity.

STC:
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 24416 W: 3039 L: 2848 D: 18529
Ptnml(0-2): 135, 2136, 7503, 2271, 163
https://tests.stockfishchess.org/tests/view/5f6451efbb0cae038ca8f4dc

LTC;
LLR: 2.95 (-2.94,2.94) {0.25,1.25}
Total: 65016 W: 3702 L: 3455 D: 57859
Ptnml(0-2): 66, 2991, 26157, 3218, 76
https://tests.stockfishchess.org/tests/view/5f64b143bb0cae038ca8f51f

closes https://github.com/official-stockfish/Stockfish/pull/3140

Bench: 3973739

5 years agoSimplify reduced depth search
Unai Corzo [Sun, 20 Sep 2020 07:03:37 +0000]
Simplify reduced depth search

Simplification in reduced depth search.

STC https://tests.stockfishchess.org/tests/view/5f64c72fbb0cae038ca8f531
LLR: 2.94 (-2.94,2.94) {-1.25,0.25}
Total: 28320 W: 3475 L: 3359 D: 21486
Ptnml(0-2): 170, 2485, 8773, 2523, 209

LTC https://tests.stockfishchess.org/tests/view/5f650cfabb0cae038ca8f585
LLR: 2.95 (-2.94,2.94) {-0.75,0.25}
Total: 58392 W: 3354 L: 3285 D: 51753
Ptnml(0-2): 74, 2826, 23336, 2877, 83

closes https://github.com/official-stockfish/Stockfish/pull/3139

bench: 4201295

5 years agoMerge official-stockfish/master
Fabian Fichter [Sun, 20 Sep 2020 12:10:42 +0000]
Merge official-stockfish/master

bench: 4262221

5 years agoMerge official-stockfish/master
Fabian Fichter [Sun, 20 Sep 2020 11:55:24 +0000]
Merge official-stockfish/master

No functional change.

5 years agoMerge official-stockfish/master
Fabian Fichter [Sun, 20 Sep 2020 11:17:16 +0000]
Merge official-stockfish/master

bench: 4629236

5 years agoMerge official-stockfish/master
Fabian Fichter [Sun, 20 Sep 2020 10:20:05 +0000]
Merge official-stockfish/master

No functional change.

5 years agoTweak shogi piece values
Fabian Fichter [Sat, 19 Sep 2020 16:41:31 +0000]
Tweak shogi piece values

shogi STC
LLR: 2.97 (-2.94,2.94) [0.00,10.00]
Total: 5572 W: 2865 L: 2682 D: 2
http://www.variantfishtest.org:6543/tests/view/5f6110aa6e23db221d9e919c

shogi LTC
LLR: 2.97 (-2.94,2.94) [0.00,10.00]
Total: 5586 W: 2867 L: 2684 D: 35
http://www.variantfishtest.org:6543/tests/view/5f62fc106e23db221d9e91bb

5 years agoMerge official-stockfish/master
Fabian Fichter [Sat, 19 Sep 2020 12:49:12 +0000]
Merge official-stockfish/master

bench: 4665603

5 years agoMerge official-stockfish/master
Fabian Fichter [Sat, 19 Sep 2020 12:45:56 +0000]
Merge official-stockfish/master

No functional change.

5 years agoMerge official-stockfish/master
Fabian Fichter [Sat, 19 Sep 2020 11:41:08 +0000]
Merge official-stockfish/master

bench: 5113210

5 years agoMerge official-stockfish/master
Fabian Fichter [Sat, 19 Sep 2020 09:36:55 +0000]
Merge official-stockfish/master

No functional change.