Sayuri icon indicating copy to clipboard operation
Sayuri copied to clipboard

Any plans for a openCl backend?

Open ghost opened this issue 1 year ago • 3 comments

Hi,

I would like to try out sayuri but only have igpu hd520 graphics. Is openCl possible in the future? Thanks.

ghost avatar Mar 30 '23 23:03 ghost

@oldnewsbigfry

Sorry, I don't have any plan to implement the OpenCL backend because it overloads me to maintain CUDA and OpenCL backends at the same time. However, I recommend you use the Eigen or OpenBLAS backend. There are some problems for intel (graphics) OpenCL driver. The HD520 graphics may not work well.

I fixed serious a bug and added support for GCC 11 on the current commit. Please remove the old old and download the new one. Thanks!

CGLemon avatar Mar 31 '23 04:03 CGLemon

Hi,

I've got the Eigen backend compiling on fedora 36 and playing a game in Gogui. Great that it can play opening book!

Is uec-swa-1700k the latest weights file or should I use zero-1315k?

Pachi uses the dcnn patterns and plays a nice game of Go.

Would it be possible for Sayuri to use patterns and zero weight file combined together. For instance if choose between moves of similar winrate, then choose the pattern match move? Just an idea to make Sayuri play nice shape Go.

Also mybe you know of pangafu Leela Master weights on github, it was trained using professional games mixed with leela games and it plays like a human.

thanks again,

ghost avatar Apr 04 '23 11:04 ghost

Hi, @oldnewsbigfry

  1. What's the weights better? The uec-swa-1700k.bin.txt is supervised learning (SL) weight and it trained on KataGo self-play SGF games. The 1700k means it trained 1700000 steps. The zero-1315k.bin.txt is reinforcement learning (RL) weights. The 1315k means it played 1315000 games. I recommend using the last RL weights because there are less blindspots. And the strength of current zero weights is around 5~6 dan in the blitz game. I think it is strong enough for most players.

  2. Combine the zero weights with patterns. Let me quickly describe the pattern-based technology. Pattern is fascinatingly trick for computer go. Rémi Coulom proposed the MM methods for learning patterns in 2007s. The computer go could select the reliable move only depending on local patterns. The prediction rate could be easy greater than 35% on the large pattern set. There is a weight for each pattern. We assume $W_i$ is the weights of $i$ th pattern. The score of each move is sum of pattern score. For example, move $A$ has $x$, $y$ and $z$ patterns. The score of $A$ is equal to $W_x\ +\ W_y\ +\ W_z$. You may see it as a single layer perceptron.

    Although pattern is powerful, there are many obvious blindspots in it, like Life-and-Death, ladder, tesuji or Yose, Since 2015, the deep convolutional neural network (DCNN) was imported into computer go. It can significantly improve the performance about these blindspots (but still be not good at it, maybe it is weakness with local-features-based learning). So I guess it is not wise ideal using the patterns in MCTS for modern computer go.

    As fair as l know, Pachi use policy network, it is from darkgo, with Moggy playout policy using 3x3 patterns if we enable the DCNN. MM patterns are not used in it. (Moggy playout is a rule-based policy for random playout. It is evaluation trick before value network. If you are interested in these ancient technologies, you may see these excellent papers, Pachi and more, Ray)

  3. Leela Zero Master I did not notice it before. It is a cool implementation. I may get some benefit in it. Thanks for providing these information.

CGLemon avatar Apr 05 '23 06:04 CGLemon