ProDeo
Would you like to react to this message? Create an account in a few clicks or log in to continue.
ProDeo

Computer Chess
 
HomeHome  CalendarCalendar  Latest imagesLatest images  FAQFAQ  SearchSearch  MemberlistMemberlist  UsergroupsUsergroups  RegisterRegister  Log in  

Post new topic   Reply to topic
 

 Rebel 14 GPL project missing file

Go down 
4 posters
AuthorMessage
Dann Corbit




Posts : 189
Join date : 2020-11-26

Rebel 14 GPL project missing file Empty
PostSubject: Rebel 14 GPL project missing file   Rebel 14 GPL project missing file EmptyWed Jan 12, 2022 11:40 pm

Missing file in Rebel-14 project, collected from here: http://rebel13.nl/windows/rebel-14.html

From nnue.cpp, we have a reference to a text file that is not included in the project:

#include "g:/epoch-78x.txt"

I do see this text file in the project:

Directory of C:\Users\dannc\chess\Rebel-14-Master\embedded-nnues

01/09/2022 08:32 AM 33,696,197 rebel-14.txt.txt
Back to top Go down
Dann Corbit




Posts : 189
Join date : 2020-11-26

Rebel 14 GPL project missing file Empty
PostSubject: Re: Rebel 14 GPL project missing file   Rebel 14 GPL project missing file EmptyThu Jan 13, 2022 12:07 am

Dann Corbit wrote:
Missing file in Rebel-14 project, collected from here: http://rebel13.nl/windows/rebel-14.html

From nnue.cpp, we have a reference to a text file that is not included in the project:

#include "g:/epoch-78x.txt"

I do see this text file in the project:

Directory of C:\Users\dannc\chess\Rebel-14-Master\embedded-nnues

01/09/2022  08:32 AM        33,696,197 rebel-14.txt.txt
I tried using the text file in the embedded-nnues folder:
//#include "g:/epoch-78x.txt"
#include "C:/Users/dannc/chess/Rebel-14-Master/embedded-nnues/rebel-14.txt.txt"

but I got this:
Severity Code Description Project File Line Suppression State
Error LNK2019 unresolved external symbol "unsigned short __cdecl read_u16_le(unsigned char *)" (?read_u16_le@@YAGPEAE@Z) referenced in function "bool __cdecl ParseNetwork(unsigned char * *)" (?ParseNetwork@@YA_NPEAPEAE@Z) Rebel C:\Users\dannc\chess\Rebel-14-Master\Rebel\nnue.obj 1
Error LNK2019 unresolved external symbol "unsigned int __cdecl read_u32_le(unsigned char *)" (?read_u32_le@@YAIPEAE@Z) referenced in function "bool __cdecl ParseHeader(unsigned char * *)" (?ParseHeader@@YA_NPEAPEAE@Z) Rebel C:\Users\dannc\chess\Rebel-14-Master\Rebel\nnue.obj 1
Error LNK2019 unresolved external symbol "unsigned int __cdecl get_file_size(char *)" (?get_file_size@@YAIPEAD@Z) referenced in function "bool __cdecl NnueLoadNet(char *)" (?NnueLoadNet@@YA_NPEAD@Z) Rebel C:\Users\dannc\chess\Rebel-14-Master\Rebel\nnue.obj 1
Error LNK1120 3 unresolved externals Rebel C:\Users\dannc\chess\Rebel-14-Master\Rebel\x64\Debug\Rebel.exe 1
Back to top Go down
Dann Corbit




Posts : 189
Join date : 2020-11-26

Rebel 14 GPL project missing file Empty
PostSubject: Re: Rebel 14 GPL project missing file   Rebel 14 GPL project missing file EmptyThu Jan 13, 2022 12:39 am

Dann Corbit wrote:
Dann Corbit wrote:
Missing file in Rebel-14 project, collected from here: http://rebel13.nl/windows/rebel-14.html

From nnue.cpp, we have a reference to a text file that is not included in the project:

#include "g:/epoch-78x.txt"

I do see this text file in the project:

Directory of C:\Users\dannc\chess\Rebel-14-Master\embedded-nnues

01/09/2022  08:32 AM        33,696,197 rebel-14.txt.txt
I tried using the text file in the embedded-nnues folder:
//#include "g:/epoch-78x.txt"
#include "C:/Users/dannc/chess/Rebel-14-Master/embedded-nnues/rebel-14.txt.txt"

but I got this:
Severity Code Description Project File Line Suppression State
Error LNK2019 unresolved external symbol "unsigned short __cdecl read_u16_le(unsigned char *)" (?read_u16_le@@YAGPEAE@Z) referenced in function "bool __cdecl ParseNetwork(unsigned char * *)" (?ParseNetwork@@YA_NPEAPEAE@Z) Rebel C:\Users\dannc\chess\Rebel-14-Master\Rebel\nnue.obj 1
Error LNK2019 unresolved external symbol "unsigned int __cdecl read_u32_le(unsigned char *)" (?read_u32_le@@YAIPEAE@Z) referenced in function "bool __cdecl ParseHeader(unsigned char * *)" (?ParseHeader@@YA_NPEAPEAE@Z) Rebel C:\Users\dannc\chess\Rebel-14-Master\Rebel\nnue.obj 1
Error LNK2019 unresolved external symbol "unsigned int __cdecl get_file_size(char *)" (?get_file_size@@YAIPEAD@Z) referenced in function "bool __cdecl NnueLoadNet(char *)" (?NnueLoadNet@@YA_NPEAD@Z) Rebel C:\Users\dannc\chess\Rebel-14-Master\Rebel\nnue.obj 1
Error LNK1120 3 unresolved externals Rebel C:\Users\dannc\chess\Rebel-14-Master\Rebel\x64\Debug\Rebel.exe 1

I added these macros:
Code:

#define read_u32_le(buf) \
    (((buf)[3]<<24)|((buf)[2]<<16)|((buf)[1]<<8)|((buf)[0]&0xff))

#define read_u16_le(buf) \
    (((buf)[1]<<8)|((buf)[0]&0xff))

#define read_u32_be(buf) \
    (((buf)[0]<<24)|((buf)[1]<<16)|((buf)[2]<<8)|((buf)[3]&0xff))

#define read_u16_be(buf) \
    (((buf)[0]<<8)|((buf)[1]&0xff))

and then I added a function to find a file's size from the file's name.
Now I can build and run
Back to top Go down
Dann Corbit




Posts : 189
Join date : 2020-11-26

Rebel 14 GPL project missing file Empty
PostSubject: My build is not as fast as Ed's (but I did not use profile optimization and I used the microsoft compiler)   Rebel 14 GPL project missing file EmptyThu Jan 13, 2022 12:44 am

downloaded build (uci/ucinewgame/go infinite):
info depth 19 seldepth 40 score cp 55 time 12844 nodes 16664109 pv e2e4 e7e5 g1f3 b8c6 f1c4 g8f6 d2d3 c6a5 c4b3 d7d6 e1g1 a5b3 a2b3 f8e7 h2h3 e8g8 c1d2 h7h6 d1e1

my build:
info depth 19 seldepth 40 score cp 55 time 15547 nodes 16664109 pv e2e4 e7e5 g1f3 b8c6 f1c4 g8f6 d2d3 c6a5 c4b3 d7d6 e1g1 a5b3 a2b3 f8e7 h2h3 e8g8 c1d2 h7h6 d1e1
Back to top Go down
Dann Corbit




Posts : 189
Join date : 2020-11-26

Rebel 14 GPL project missing file Empty
PostSubject: Since it is GPL, here is a link to the source with my changes   Rebel 14 GPL project missing file EmptyThu Jan 13, 2022 12:55 am

https://drive.google.com/file/d/1rmJRCqTqVpHdJ7lerYemzs83HEocorN8/view?usp=sharing

It has a visual studio project for VS 19 included, also the 64 bit avx2 binary that I created.
Back to top Go down
Dann Corbit




Posts : 189
Join date : 2020-11-26

Rebel 14 GPL project missing file Empty
PostSubject: Re: Rebel 14 GPL project missing file   Rebel 14 GPL project missing file EmptyThu Jan 13, 2022 12:57 am

I should have made a relative path to the nnue weights file, so you will have to edit the path as appropriate for your system if you want to buld it.
Back to top Go down
Dann Corbit




Posts : 189
Join date : 2020-11-26

Rebel 14 GPL project missing file Empty
PostSubject: Re: Rebel 14 GPL project missing file   Rebel 14 GPL project missing file EmptyThu Jan 13, 2022 1:26 am

I got an error trying to use this primitive makefile:
Code:

CXX= g++
CXXFLAGS= -Wall -Wcast-qual -fno-exceptions -std=c++17  -pedantic -Wextra -Wshadow -m64 -DUSE_PTHREADS -DNDEBUG -O3 -mtune=native -DIS_64BIT -msse -msse3 -mpopcnt -DUSE_POPCNT -DUSE_AVX2 -mavx2 -DUSE_SSE41 -msse4.1 -DUSE_SSSE3 -mssse3 -DUSE_SSE2 -msse2 -flto
LDFLAGS=  -m64 -Wl,--no-as-needed -lpthread -Wall -Wcast-qual -fno-exceptions -std=c++17  -pedantic -Wextra -Wshadow -m64 -DUSE_PTHREADS -DNDEBUG -O3 -mtune=native -DIS_64BIT -msse -msse3 -mpopcnt -DUSE_POPCNT -DUSE_AVX2 -mavx2 -DUSE_SSE41 -msse4.1 -DUSE_SSSE3 -mssse3 -DUSE_SSE2 -msse2 -flto -flto=jobserver -save-temps
EXE = rebel.exe

### Source and object files
SRCS = attack.cpp board.cpp book.cpp eval.cpp fen.cpp filesize.cpp hash.cpp list.cpp main.cpp \
   material.cpp move.cpp move_check.cpp move_do.cpp move_evasion.cpp move_gen.cpp move_legal.cpp \
   nnue.cpp option.cpp pawn.cpp piece.cpp posix.cpp protocol.cpp pst.cpp pv.cpp random.cpp recog.cpp \
   search.cpp search_full.cpp see.cpp simd.cpp sort.cpp square.cpp trans.cpp util.cpp value.cpp vector.cpp

OBJS = $(notdir $(SRCS:.cpp=.o))

$(EXE): $(OBJS)
   +$(CXX) -o $@ $(OBJS) $(LDFLAGS)
   
gcc-make:
   $(MAKE) ARCH=$(ARCH) COMP=$(COMP) all

The error was:
Code:

nnue.h: In function 'scanforward64(unsigned long long)':
C:/msys64/mingw64/lib/gcc/x86_64-w64-mingw32/11.2.0/include/bmiintrin.h:172:1: error: inlining failed in call to 'always_inline' '_tzcnt_u64': target specific option mismatch
  172 | _tzcnt_u64 (unsigned long long __X)
      | ^~~~~~~~~~
In file included from nnue.cpp:34:
nnue.h:205:28: note: called from here
  205 |    return ((int)_tzcnt_u64(x));
      |                  ~~~~~~~~~~^~~
make: *** [<builtin>: nnue.o] Error 1
Back to top Go down
Admin
Admin
Admin


Posts : 2608
Join date : 2020-11-17
Location : Netherlands

Rebel 14 GPL project missing file Empty
PostSubject: Re: Rebel 14 GPL project missing file   Rebel 14 GPL project missing file EmptyThu Jan 13, 2022 10:57 am

Dann, I am new to Visual Studio, I will try to add a project file to the download.
Back to top Go down
http://rebel13.nl/
Admin
Admin
Admin


Posts : 2608
Join date : 2020-11-17
Location : Netherlands

Rebel 14 GPL project missing file Empty
PostSubject: Re: Rebel 14 GPL project missing file   Rebel 14 GPL project missing file EmptyThu Jan 13, 2022 12:26 pm

Project file included. Default is AVX2. To change check simd.cpp
Back to top Go down
http://rebel13.nl/
Chris Whittington




Posts : 1254
Join date : 2020-11-17
Location : France

Rebel 14 GPL project missing file Empty
PostSubject: Re: Rebel 14 GPL project missing file   Rebel 14 GPL project missing file EmptyThu Jan 13, 2022 4:24 pm

Admin wrote:
Project file included. Default is AVX2. To change check simd.cpp

You could give them a popcount switch too, I guess.
Plenty of code substitutions possible. Only thing to worry about is if we two end up with different code that then has to be melded.
Back to top Go down
Chris Whittington




Posts : 1254
Join date : 2020-11-17
Location : France

Rebel 14 GPL project missing file Empty
PostSubject: Re: Rebel 14 GPL project missing file   Rebel 14 GPL project missing file EmptyThu Jan 13, 2022 7:02 pm

Chris Whittington wrote:
Admin wrote:
Project file included. Default is AVX2. To change check simd.cpp

You could give them a popcount switch too, I guess.
Plenty of code substitutions possible. Only thing to worry about is if we two end up with different code that then has to be melded.

Scrap that. The popcount64() in the code is never actually called, and the two things that do call it are never called either. It’s there just as part of my useful.cpp and useful.h useful(!) functions. You could just comment the lines away. Better though, would be to have compile switch give an alternative to popcount(), then, if needed in future …..
Back to top Go down
Krisnatoon
Guest




Rebel 14 GPL project missing file Empty
PostSubject: Rebel 14 vs 14.1   Rebel 14 GPL project missing file EmptyMon Feb 14, 2022 6:24 pm

Hallo,

Rebel 14 vond een mat in 11 snel. Rebel 14.1 had dit na 20 zetten nog steeds niet gevonden. Ik vond dat opvallend... Gr, Kris
Back to top Go down
Eelco

Eelco


Posts : 233
Join date : 2021-10-08

Rebel 14 GPL project missing file Empty
PostSubject: Re: Rebel 14 GPL project missing file   Rebel 14 GPL project missing file EmptyWed Feb 16, 2022 12:54 pm

Krisnatoon wrote:
Hallo,

Rebel 14 vond een mat in 11 snel.  Rebel 14.1 had dit na 20  zetten nog steeds niet gevonden. Ik vond dat opvallend... Gr,  Kris

Hallo Krisnatoon. Om welke stelling gaat het? Heb je misschien een FEN string van de stelling? Desnoods een screenshot? Je had dit wel in een eigen topic kunnen plaatsen.
Back to top Go down
Krisnatoon
Guest




Rebel 14 GPL project missing file Empty
PostSubject: stelling   Rebel 14 GPL project missing file EmptyTue Feb 22, 2022 10:24 am

De stelling was:

Wit: Kc2, Tb3, pion a4 en g2
Zwart: Kc5, Lb2, pion c3

Groet, Kris
Back to top Go down
Eelco

Eelco


Posts : 233
Join date : 2021-10-08

Rebel 14 GPL project missing file Empty
PostSubject: Re: Rebel 14 GPL project missing file   Rebel 14 GPL project missing file EmptyTue Feb 22, 2022 3:21 pm

Dankjewel voor de informatie!

Groet, Eelco
Back to top Go down
Sponsored content





Rebel 14 GPL project missing file Empty
PostSubject: Re: Rebel 14 GPL project missing file   Rebel 14 GPL project missing file Empty

Back to top Go down
 
Rebel 14 GPL project missing file
Back to top 
Page 1 of 1
 Similar topics
-
» NNUE Research Project
» Visual Studio can't find file with long name
» what is a ZST file?
» Eman.exp fıle
» We need a new interesting chess Engine project... stockfish and komodo makes no fun

Permissions in this forum:You can reply to topics in this forum
ProDeo :: Programmer Corner-
Post new topic   Reply to topicJump to: