Discussion of anything and everything relating to chess playing software and machines.
Moderators: hgm, Dann Corbit, Harvey Williamson
Forum rules
This textbox is used to restore diagrams posted with the [d] tag before the upgrade.
-
zullil
- Posts: 6442
- Joined: Mon Jan 08, 2007 11:31 pm
- Location: PA USA
- Full name: Louis Zulli
Post
by zullil » Sun Aug 09, 2020 7:53 pm
zullil wrote: ↑Sun Aug 09, 2020 4:06 pm
carldaman wrote: ↑Sun Aug 09, 2020 3:36 pm
Deberger wrote: ↑Sun Aug 09, 2020 12:10 am
carldaman wrote: ↑Sat Aug 08, 2020 8:57 pm
It defeats the purpose if the NNUE cannot always be set to active [as an option], because then you're at the mercy of the engine only using NNUE when it chooses. Hopefully the SF team will wake up to the fact that people also use the engine for analysis.
With a trivial change to the source code, you can build your own executable which always uses NNUE.
However this change can never yield stronger analysis.
Over time, using "always NNUE" will be gradually weaker and weaker as the nets are optimized for their intended use in balanced positions.
We're making too many assumptions for now, while in the early stages of NNUE. Much more convenient is if the end user is enabled to analyze with or without NNUE whenever he chooses. That way one can get more than one opinion on a given position, without loading a different engine altogether.
Wish they'd just delete the classical evaluation completely, and stop this awkward hybridization. Yes, the NNUE evaluation is (currently) half as fast as the classical one. And given that it still was +90 Elo above classical-fish. Folks are just emotionally attached to the classical evaluation, because so many people tweaked it over the years. NNUE is the future; let it happen and evolve. And start working on SMP search.
Sadly, it seems the silliness has only begun.
https://github.com/official-stockfish/S ... e325ccb942
Introducing more confusion, simply because it might gain 0.2 Elo under Fishtest conditions...

-
jhellis3
- Posts: 488
- Joined: Fri Aug 16, 2013 10:36 pm
Post
by jhellis3 » Sun Aug 09, 2020 7:57 pm
Lol, well.... there won't be any of that in Crystal, or at the very least there will be an option to just use the NN.
-
zullil
- Posts: 6442
- Joined: Mon Jan 08, 2007 11:31 pm
- Location: PA USA
- Full name: Louis Zulli
Post
by zullil » Sun Aug 09, 2020 7:58 pm
jhellis3 wrote: ↑Sun Aug 09, 2020 7:57 pm
Lol, well.... there won't be any of that in Crystal, or at the very least there will be an option to just use the NN.
Good sense, man! Thanks.
-
Deberger
- Posts: 71
- Joined: Sat Nov 02, 2019 5:42 pm
- Full name: ɹǝƃɹǝqǝᗡ ǝɔnɹꓭ
Post
by Deberger » Mon Aug 10, 2020 12:22 am
Ovyron wrote: ↑Sat Aug 08, 2020 2:31 pm
zullil wrote: ↑Sat Aug 08, 2020 1:58 pm
Yes, I can modify source code before compiling so that "Use NNUE" means "Use NNUE only". But that's going to get old very quickly.
So, basically you just want someone that doesn't find this getting old quickly to maintain a Stockfish fork and do this for you?
Folks who don't code are making the most vocal demands:
zullil wrote: ↑Sat Aug 08, 2020 2:33 pm
(Though eventually I should spend the time to learn how to use git fully myself.

)
NN is the Future!
NN All The Things!
zullil wrote: ↑Sun Aug 09, 2020 4:06 pm
Wish they'd just delete the classical evaluation completely, and stop this awkward hybridization.
-
jhellis3
- Posts: 488
- Joined: Fri Aug 16, 2013 10:36 pm
Post
by jhellis3 » Mon Aug 10, 2020 12:48 am
I've pushed the upstream merge to Crystal. Instead of a bool for NNUE, it has off, hybrid, and on as choices. I *think* everything is working fine, but haven't really had the time to go over all the changes closely.
Planning on doing a 3.0 release in a couple of weeks, but the impatient can just compile off github if they want to try Crystal + NNUE.
https://github.com/jhellis3/Stockfish/tree/crystal
-
zullil
- Posts: 6442
- Joined: Mon Jan 08, 2007 11:31 pm
- Location: PA USA
- Full name: Louis Zulli
Post
by zullil » Mon Aug 10, 2020 1:43 am
Deberger wrote: ↑Mon Aug 10, 2020 12:22 am
Ovyron wrote: ↑Sat Aug 08, 2020 2:31 pm
zullil wrote: ↑Sat Aug 08, 2020 1:58 pm
Yes, I can modify source code before compiling so that "Use NNUE" means "Use NNUE only". But that's going to get old very quickly.
So, basically you just want someone that doesn't find this getting old quickly to maintain a Stockfish fork and do this for you?
Folks who don't code are making the most vocal demands:
zullil wrote: ↑Sat Aug 08, 2020 2:33 pm
(Though eventually I should spend the time to learn how to use git fully myself.

)
NN is the Future!
NN All The Things!
zullil wrote: ↑Sun Aug 09, 2020 4:06 pm
Wish they'd just delete the classical evaluation completely, and stop this awkward hybridization.
Not the future of all things, but the days of humans writing chess evaluation functions are obviously coming to a close. Time to focus on SMP searching.
And I do code. Have written a chess program from scratch even. Just haven't spent the time to master git.

-
smatovic
- Posts: 1681
- Joined: Wed Mar 10, 2010 9:18 pm
- Location: Hamburg, Germany
- Full name: Srdja Matovic
-
Contact:
Post
by smatovic » Mon Aug 10, 2020 7:34 am
zullil wrote: ↑Mon Aug 10, 2020 1:43 am
Deberger wrote: ↑Mon Aug 10, 2020 12:22 am
Ovyron wrote: ↑Sat Aug 08, 2020 2:31 pm
zullil wrote: ↑Sat Aug 08, 2020 1:58 pm
Yes, I can modify source code before compiling so that "Use NNUE" means "Use NNUE only". But that's going to get old very quickly.
So, basically you just want someone that doesn't find this getting old quickly to maintain a Stockfish fork and do this for you?
Folks who don't code are making the most vocal demands:
zullil wrote: ↑Sat Aug 08, 2020 2:33 pm
(Though eventually I should spend the time to learn how to use git fully myself.

)
NN is the Future!
NN All The Things!
zullil wrote: ↑Sun Aug 09, 2020 4:06 pm
Wish they'd just delete the classical evaluation completely, and stop this awkward hybridization.
Not the future of all things, but the days of humans writing chess evaluation functions are obviously coming to a close. Time to focus on SMP searching.
And I do code. Have written a chess program from scratch even. Just haven't spent the time to master git.
Cos you mentioned SMP search repeatedly, did some experiments with 256 workers on gpu with Zeta -> RMO - Randomized Move Order
viewtopic.php?f=7&t=72684
--
Srdja
-
JohnS
- Posts: 201
- Joined: Sun Feb 24, 2008 1:08 am
Post
by JohnS » Mon Aug 10, 2020 8:44 am
I modified the script on the stockfish site to make a nnue version under msys64/mingw for win10.
Code: Select all
#!/bin/bash
# install packages if not already installed
unzip -v &> /dev/null || pacman -S --noconfirm unzip
make -v &> /dev/null || pacman -S --noconfirm make
g++ -v &> /dev/null || pacman -S --noconfirm mingw-w64-x86_64-gcc
# remove any previous version
rm master.zip
rm -r Stockfish-master
# download the stockfish source code
wget https://github.com/official-stockfish/Stockfish/archive/master.zip
unzip master.zip
cd Stockfish-master/src
make net
sed -i*.bak -e "s/false, on_use_NNUE/true, on_use_NNUE/" ucioption.cpp
sed -i*.bak -e "s|NNUEThreshold = Value([0-9]\+)|NNUEThreshold = Value(VALUE_INFINITE)|" evaluate.cpp
sed -i*.bak -e "s|return NNUE::evaluate(pos) + Tempo|return NNUE::evaluate(pos)|" evaluate.cpp
CXXFLAGS='-march=native -flto' LDFLAGS='-flto -O3 -march=native' make -j ARCH=x86-64-bmi2 profile-build COMP=mingw
strip stockfish.exe
cp stockfish.exe ../..
cd ../..
# clean up
rm master.zip
rm -r Stockfish-master
Just adjust ARCH to suit your system and run from your home directory.
It works for the current source code but the sed lines may need to be adjusted if they make more changes to ucioption.cpp and evaluate.cpp.
-
corres
- Posts: 3657
- Joined: Wed Nov 18, 2015 10:41 am
- Location: hungary
Post
by corres » Tue Aug 11, 2020 11:02 am
zullil wrote: ↑Sun Aug 09, 2020 4:06 pm
...
Wish they'd just delete the classical evaluation completely, and stop this awkward hybridization. Yes, the NNUE evaluation is (currently) half as fast as the classical one. And given that it still was +90 Elo above classical-fish. Folks are just emotionally attached to the classical evaluation, because so many people tweaked it over the years. NNUE is the future; let it happen and evolve. And start working on SMP search.
You can not delete the classical evaluation completely because the working NNUE use partly the evaluation of Stockfish too. The common parts are: UCI-frame, position parsing, piece and its position eval, move generator and mainly the searcher of Stockfish.
-
corres
- Posts: 3657
- Joined: Wed Nov 18, 2015 10:41 am
- Location: hungary
Post
by corres » Tue Aug 11, 2020 5:42 pm
jhellis3 wrote: ↑Mon Aug 10, 2020 12:48 am
I've pushed the upstream merge to Crystal. Instead of a bool for NNUE, it has off, hybrid, and on as choices. I *think* everything is working fine, but haven't really had the time to go over all the changes closely.
Planning on doing a 3.0 release in a couple of weeks, but the impatient can just compile off github if they want to try Crystal + NNUE.
https://github.com/jhellis3/Stockfish/tree/crystal
I think Crystal would be better if Sergio would make a special net for Crystal basing it on the play of Crystal.