official-pikafish / Pikafish

UCI xiangqi engine
http://pikafish.org
GNU General Public License v3.0
867 stars 162 forks source link

miniz on iOS device #12

Closed duongbadu closed 9 months ago

duongbadu commented 1 year ago

miniz (extract pikafish.nnue file) does not work when building for iOS device.

PikaCat-OuO commented 1 year ago

Any error message when building? Could you please provide a detailed screenshot of what's happening when building the binary on iOS?

duongbadu commented 1 year ago

info string ERROR: The network file /var/containers/Bundle/Application/*****-57F3-4167-B2DE-**/ChineseChess172-mobile.app/books/pikafish.nnue was not loaded successfully.

duongbadu commented 1 year ago

I see that Stockfish use: incbin library to embed the NNUE file. Can we use incbin in Pikafish?

Warm-rain commented 1 year ago

You need to specify the nnue path with the command. eg:setoption name EvalFile value /bin/pikafish.nnue

duongbadu commented 1 year ago

You need to specify the nnue path with the command. eg:setoption name EvalFile value /bin/pikafish.nnue

already set in ucioption.cpp file: auto nnuePath = FileUtils::getInstance()->fullPathForFilename("pikafish.nnue"); o["EvalFile"] << Option(nnuePath.c_str(), on_eval_file);

PikaCat-OuO commented 1 year ago

I believe chessroad-lite(https://github.com/hezhaoyun/chessroad-lite) have successfully build it. You can ask the author for help.

PikaCat-OuO commented 9 months ago

Since it has been here for more than a year. I'll mark this as stale now.