RubiChess NNUE player implemented

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

Moderator: Ras

User avatar
RubiChess
Posts: 640
Joined: Fri Mar 30, 2018 7:20 am
Full name: Andreas Matthies

Re: RubiChess NNUE player implemented

Post by RubiChess »

OliverBr wrote: Sun Nov 01, 2020 8:37 pm Hi,

you may perhaps want to know that I cannot compile RubiChess for MacOSX and clang:

Code: Select all

make COMP=clang
rm -f RubiChess-BMI2 RubiChess-AVX2 RubiChess RubiChess-Legacy *.o
rm -f -rf OPT
rm -f *.clangprof-raw *.profdata
  Compiling RubiChess...
clang++ -std=c++11 -Wall -O3 -flto -pedantic -Wextra -Wshadow  -mssse3 -msse2 -mmmx -mpopcnt *.cpp -lpthread -fuse-ld=lld  -D GITVER=\"20200913143055\" -D GITID=\"dc4bcbc\" -DUSE_SSSE3 -DUSE_SSE2 -DUSE_MMX -DUSE_POPCNT -o RubiChess
clang: error: invalid linker name in argument '-fuse-ld=lld'
make[1]: *** [compile] Error 1
make: *** [default] Error 2
It would be nice if this worked. With just "make" (it's the GCC profile) yield to a couple of more errors, but gcc is linked to clang on my Mac.
I'm using lld when compiling with clang. Needed it for proper profile building iirc.
This https://stackoverflow.com/questions/609 ... g-on-macos seems to say that lld is no option for MacOSX.

You could try to change this line in Makefile:
ifeq ($(COMP),clang)
CXX=clang++
CXXFLAGS += -pedantic -Wextra -Wshadow
-- LDFLAGS=-lpthread -fuse-ld=lld
++ LDFLAGS=-lpthread
profile_make = clang-profile-make
endif

Andreas
OliverBr
Posts: 794
Joined: Tue Dec 18, 2007 9:38 pm
Location: Munich, Germany
Full name: Dr. Oliver Brausch

Re: RubiChess NNUE player implemented

Post by OliverBr »

RubiChess wrote: Sun Nov 01, 2020 9:19 pm You could try to change this line in Makefile:
ifeq ($(COMP),clang)
CXX=clang++
CXXFLAGS += -pedantic -Wextra -Wshadow
-- LDFLAGS=-lpthread -fuse-ld=lld
++ LDFLAGS=-lpthread
profile_make = clang-profile-make
endif

Andreas
After pathing the makefile, unfortunately other errors appear (some of them equal to just "make":

Code: Select all

make COMP=clang
rm -f RubiChess-BMI2 RubiChess-AVX2 RubiChess RubiChess-Legacy *.o
rm -f -rf OPT
rm -f *.clangprof-raw *.profdata
  Compiling RubiChess...
clang++ -std=c++11 -Wall -O3 -flto -pedantic -Wextra -Wshadow  -mssse3 -msse2 -mmmx -mpopcnt *.cpp -lpthread  -D GITVER=\"20201029193215\" -D GITID=\"4cd1205\" -DUSE_SSSE3 -DUSE_SSE2 -DUSE_MMX -DUSE_POPCNT -o RubiChess
board.cpp:2577:31: error: use of undeclared identifier 'aligned_alloc'
    sthread = (searchthread*) allocalign64(size);
                              ^
./RubiChess.h:125:25: note: expanded from macro 'allocalign64'
#define allocalign64(x) aligned_alloc(64, x)
                        ^
1 error generated.
nnue.cpp:429:22: error: use of undeclared identifier 'aligned_alloc'
    bias = (int16_t*)allocalign64(allocsize);
                     ^
./RubiChess.h:125:25: note: expanded from macro 'allocalign64'
#define allocalign64(x) aligned_alloc(64, x)
                        ^
nnue.cpp:431:24: error: use of undeclared identifier 'aligned_alloc'
    weight = (int16_t*)allocalign64(allocsize);
                       ^
./RubiChess.h:125:25: note: expanded from macro 'allocalign64'
#define allocalign64(x) aligned_alloc(64, x)
                        ^
nnue.cpp:467:22: error: use of undeclared identifier 'aligned_alloc'
    bias = (int32_t*)allocalign64(allocsize);
                     ^
./RubiChess.h:125:25: note: expanded from macro 'allocalign64'
#define allocalign64(x) aligned_alloc(64, x)
                        ^
nnue.cpp:469:23: error: use of undeclared identifier 'aligned_alloc'
    weight = (int8_t*)allocalign64(allocsize);
                      ^
./RubiChess.h:125:25: note: expanded from macro 'allocalign64'
#define allocalign64(x) aligned_alloc(64, x)
                        ^
4 errors generated.
transposition.cpp:167:36: error: use of undeclared identifier 'aligned_alloc'
    table = (transpositioncluster*)allocalign64(allocsize);
                                   ^
./RubiChess.h:125:25: note: expanded from macro 'allocalign64'
#define allocalign64(x) aligned_alloc(64, x)
                        ^
transposition.cpp:352:31: error: use of undeclared identifier 'aligned_alloc'
    table = (S_PAWNHASHENTRY*)allocalign64(tablesize);
                              ^
./RubiChess.h:125:25: note: expanded from macro 'allocalign64'
#define allocalign64(x) aligned_alloc(64, x)
                        ^
transposition.cpp:388:33: error: use of undeclared identifier 'aligned_alloc'
    table = (Materialhashentry*)allocalign64(tablesize);
                                ^
./RubiChess.h:125:25: note: expanded from macro 'allocalign64'
#define allocalign64(x) aligned_alloc(64, x)
                        ^
3 errors generated.
make[1]: *** [compile] Error 1
make: *** [default] Error 2
PS: "make -f Makefile-clang" doesn't work either:

Code: Select all

make -f Makefile.clang 
Makefile.clang:47: *** missing separator.  Stop.
Chess Engine OliThink: http://brausch.org/home/chess
OliThink GitHub:https://github.com/olithink
User avatar
RubiChess
Posts: 640
Joined: Fri Mar 30, 2018 7:20 am
Full name: Andreas Matthies

Re: RubiChess NNUE player implemented

Post by RubiChess »

Thanks for testing.
I have opened an issue on github: https://github.com/Matthies/RubiChess/issues/248

The Makefile.clang is for using with nmake of MSVC and will not work with make as you noticed.

Regards, Andreas
User avatar
xr_a_y
Posts: 1872
Joined: Sat Nov 25, 2017 2:28 pm
Location: France

Re: RubiChess NNUE player implemented

Post by xr_a_y »

Frank Quisinsky wrote: Sun Nov 01, 2020 6:31 pm [...]

Unclear is the Minic configuration (NNUE file or not for engine tournaments).

And so one!

Better is if programmers give a clear announcement what they like to see in chess tournaments.
To test all the available NNUE files for so many available engines isn't possible.

[...]
I am sad to hear Minic case can still be unclear.

http://talkchess.com/forum3/viewtopic.p ... 50#p855313
http://talkchess.com/forum3/viewtopic.p ... 67#p863067
http://talkchess.com/forum3/viewtopic.p ... 60#p864860
http://talkchess.com/forum3/viewtopic.p ... 43#p863836

As a summary, MinicNNUE based on SF code merge is (was?) a fun experiment, not official version of Minic.
As a side note, Werner tested it (http://www.cegt.net/40_40%20Rating%20Li ... s/126.html) in a rating list but accepting to give a specific name to it to clarify situation.

But, I'm now working on another implementation, please be patient ;)

Best regards
Frank Quisinsky
Posts: 6888
Joined: Wed Nov 18, 2009 7:16 pm
Location: Gutweiler, Germany
Full name: Frank Quisinsky

Re: RubiChess NNUE player implemented

Post by Frank Quisinsky »

Hi Vivien,

unclear is ...

The current Minic version with or without NNUE.
If NNUE ... which of the NN files you would like to see and is most important for your own development.

I think the RubiChess solution is very good (own NNUE).

For the moment I have no idea what I have to added in my next tourney.
Minic with or without NNUE.

It would be great if you can give me a hint before the next tournament will be start ... start of January 2021.

Best
Frank
AndrewGrant
Posts: 1955
Joined: Tue Apr 19, 2016 6:08 am
Location: U.S.A
Full name: Andrew Grant

Re: RubiChess NNUE player implemented

Post by AndrewGrant »

Frank Quisinsky wrote: Mon Nov 02, 2020 7:42 pm Hi Vivien,

unclear is ...

The current Minic version with or without NNUE.
If NNUE ... which of the NN files you would like to see and is most important for your own development.

I think the RubiChess solution is very good (own NNUE).

For the moment I have no idea what I have to added in my next tourney.
Minic with or without NNUE.

It would be great if you can give me a hint before the next tournament will be start ... start of January 2021.

Best
Frank
Minic author has been very clear. Did you read the links he posted??
Frank Quisinsky
Posts: 6888
Joined: Wed Nov 18, 2009 7:16 pm
Location: Gutweiler, Germany
Full name: Frank Quisinsky

Re: RubiChess NNUE player implemented

Post by Frank Quisinsky »

Hi Andy,

for that reason I have listed the program on my Tourney-2021 page without NNUE.

Yes, I read the messages.

A lot of Minic version are available since I started the tourney 2020 for around 5 months. I believe 8 versions.
2.37, 2.40, 2.45, 2.46, 2.47, 2.48, 2.52, 2.53 ... maybe others I don't saw.

Keep track of things are often complicated if I have no time to deal with something.
For the moment I am looking in Minic 2.33 for an example.

After all:
It's more interesting if programmers are very activ but for an user it's impossible to look in detail in all the available versions.

What I not understand is the own network file:
nascent nutrient = the own!

Again:
For me it's unclear to test the current Minic version with "nascent nutrient" or without the network file.

After all I understand the programmer give us the own NN file but he like more to see his program in a rating list or tourneys without network files. He like it to see that both versions are available in a rating list.

So, I can't other things do if I start to test Minic.
Same for other programs often updated ...

1-2x Wasp in the year is more as enough.
I am happy that John give me the time to test a new version before he send the next one (for an example).

Best
Frank
User avatar
Werner
Posts: 2967
Joined: Wed Mar 08, 2006 10:09 pm
Location: Germany
Full name: Werner Schüle

Re: RubiChess NNUE player implemented

Post by Werner »

Can we expect an official release of Rubichess 1.9 with the new network nn-803c91ad5c-20201107.nnue ?
Werner
User avatar
pohl4711
Posts: 2705
Joined: Sat Sep 03, 2011 7:25 am
Location: Berlin, Germany
Full name: Stefan Pohl

Re: RubiChess NNUE player implemented

Post by pohl4711 »

Werner wrote: Sat Nov 07, 2020 7:00 pm Can we expect an official release of Rubichess 1.9 with the new network nn-803c91ad5c-20201107.nnue ?
Yes, good question. I would like to test RubiChess 1.9 with it's own nnue-net for my ratinglist, but for my machine, I need a AVX or a popcount compile!

Stefan (SPCC)
Krzysztof Grzelak
Posts: 1585
Joined: Tue Jul 15, 2014 12:47 pm

Re: RubiChess NNUE player implemented

Post by Krzysztof Grzelak »

pohl4711 wrote: Sun Nov 08, 2020 10:28 am Yes, good question. I would like to test RubiChess 1.9 with it's own nnue-net for my ratinglist, but for my machine, I need a AVX or a popcount compile!

Stefan (SPCC)
And where can you download versions of 1.9 from nnue from AVX or a popcount compile.