kobanium / Ray

Computer go engine using Monte-Carlo Tree Search (MCTS)
BSD 2-Clause "Simplified" License
70 stars 81 forks source link

gcc 13.2 compile err, and winrate is 0% with cgos-genmove_analyze #174

Open yssaya opened 2 months ago

yssaya commented 2 months ago

Ray 11.1.0 has an error with gcc 13.2 on Ubuntu 24.04. src/mcts/MCTSNode.cpp:34:8: error: 'fill_n' is not a member of 'std'

$ gcc -v gcc version 13.2.0 (Ubuntu 13.2.0-23ubuntu4)

I added these three line in "include/mcts/MCTSNode.hpp".

#include <algorithm>
#include <iostream>
#include <iterator>

Looks like root winrate returns always 0% with cgos-genmove_analyze. And sometimes Ray had stopped and lost on time. http://www.yss-aya.com/cgos/19x19/cross/ray_11.1.0_10k.html

ServerUser = ray_11.1.0_10k CommandLine = ./ray1110 --size 19 --playout 10000 --cgos

Thanks.

kobanium commented 5 days ago

@yssaya I fixed all bugs and released Ray v11.2.0. Please check newer version. Main critical bug is following;

When Ray plays any move, json data is fulfilled

= 
{ "winrate": 0.2005,"visits": 9884, "moves": [{ "move": "B7","winrate": 0.2122,"prior": 0.045090,"pv" : "B7 C7 D6 B5 S7 S11","visits" : 1475},{ "move": "C7","winrate": 0.2077,"prior": 0.082815,"pv" : "C7 B7 D8 D9 E9 E8 D7","visits" : 1358},{ "move": "D11","winrate": 0.2069,"prior": 0.047303,"pv" : "D11 E8 F8 E9 F9","visits" : 1160},{ "move": "D5","winrate": 0.1940,"prior": 0.183580,"pv" : "D5 C4 D7 C7 B7","visits" : 1031},{ "move": "M2","winrate": 0.2065,"prior": 0.001989,"pv" : "M2 D9 E9 E8 D6","visits" : 978},{ "move": "D7","winrate": 0.1990,"prior": 0.030015,"pv" : "D7 C7 D6 D9 E9 B7","visits" : 794},{ "move": "E8","winrate": 0.1960,"prior": 0.045799,"pv" : "E8 C7 D6 B7 D8","visits" : 745},{ "move": "K2","winrate": 0.2003,"prior": 0.002351,"pv" : "K2 D9 E9 E8","visits" : 599},{ "move": "D9","winrate": 0.1777,"prior": 0.173544,"pv" : "D9 C7 D6 C9 E8","visits" : 557},{ "move": "S7","winrate": 0.1946,"prior": 0.014446,"pv" : "S7 D9 C7 B7","visits" : 519},{ "move": "B10","winrate": 0.1949,"prior": 0.005953,"pv" : "B10 B9 B11 D9","visits" : 431},{ "move": "S11","winrate": 0.1561,"prior": 0.007492,"pv" : "S11 S10 T12 S7","visits" : 237}],"ownership": "oeSHEBAAADGLWo25566ssFFGAAAACGHQn75667ssF5VVABAAIDDh17677ssF5kAADBAf88839887sr55jNAIAAar0tmi878rtt5uk6I3aUlzoWLL75vsz1z06v3lOk5mVMLL5y44yyz0zvlZksgJJkmmrmjrzzywtnjmqbLMJPVcYLj60ywvsrtwnJLJQRSPPevzzzzyz199nfeZZNLJbpz244347988xunjKKWku4999999B8377mgIHvu55BBBBBBBguL7NVHICl5HHFFHIILUZLENOFEEE5GIHHMONKMMDHJLDDBFCKGDLPTPKDGHIKLDDDDCGGIMQSQMIIJKKLDDDDEFHJMPRQNKJKKKK","comment" : "Ray selected the next move based on Monte-Carlo tree search."}
play B7

When Ray resign, json data is empty

= 

play resign
yssaya commented 2 hours ago

Thank you for your update! It looks like v11.2.0 is very stable. http://www.yss-aya.com/cgos/19x19/cross/ray_11.2.0_10k.html