Buch "Deep Learning Learned with Shogi AI" von Tadao Yamaoka Ursprünglicher Quellcode https://github.com/TadaoYamaoka/python-dlshogi.git
Führen Sie "Deep Learning with Shogi AI" auf iMac und Google Colab aus. Erstellen Sie eine Basisumgebung auf iMac und verwenden Sie die GPU von Google Colab nur beim Lernen.
iMac iMac 2020 27-Zoll-Standardmodell 3,1 GHz 6-Core Intel Core i5 Prozessor der 10. Generation Bis zu 4,5 GHz bei Verwendung von Turbo Boost 8 GB 2.666 MHz DDR4-Speicher 256 GB SSD-Speicher Radeon Pro 5300 (mit 4 GB GDDR6-Speicher) OS : Catalina Python: 3.8.2 und 2.7 vorinstalliert. Diesmal habe ich 3.8.2 verwendet. Google Colab Python 3.6.9
Bereiten Sie die Datei auf der iMac-Seite vor und synchronisieren Sie sie mit Google Drive. Das Lernen wird auf der Google Colab-Seite ausgeführt. Spielen Sie auf iMac. Spielvideo https://youtu.be/vPCsmi3_Zu8
Google Colab verwenden </ b> [Google Colab vorbereiten](https://qiita.com/kazunoriri/items/ef116e1cf88b4649a9b7#google-colab%E3%82%92%E4%BD%BF%E3%81%88%E3%82% 8B% E7% 8A% B6% E6% 85% 8B% E3% 81% AB% E3% 81% 99% E3% 82% 8B) Lokale Seite Google Colab-Seite [Mount Drive](https://qiita.com/kazunoriri/items/ef116e1cf88b4649a9b7#%E3%83%89%E3%83%A9%E3%82%A4%E3%83%96%E3%82% 92% E3% 83% 9E% E3% 82% A6% E3% 83% B3% E3% 83% 88% E3% 81% 99% E3% 82% 8B) [GPU aktivieren](https://qiita.com/kazunoriri/items/ef116e1cf88b4649a9b7#gpu%E3%82%92%E6%9C%89%E5%8A%B9%E3%81%AB%E3% 81% 99% E3% 82% 8B) [Chainer installieren](https://qiita.com/kazunoriri/items/ef116e1cf88b4649a9b7#chainer%E3%82%92%E3%82%A4%E3%83%B3%E3%82%B9%E3%83% 88% E3% 83% BC% E3% 83% AB) [Installieren Sie Python-Shogi und Pydlshogi](https://qiita.com/kazunoriri/items/ef116e1cf88b4649a9b7#python-shogi%E3%81%A8pydlshogi%E3%82%92%E3%82%A4%E3%83% B3% E3% 82% B9% E3% 83% 88% E3% 83% BC% E3% 83% AB) Google Colab verwenden Lokal Colab-Seite Lernausführung Experiment CPU vs GPU
Kapitel 1-6 </ b> Kapitel 1-5 [Kapitel 6 Deep Learning Framework](https://qiita.com/kazunoriri/items/32c45e46bb122ae1ef7c#%E7%AC%AC6%E7%AB%A0-%E3%83%87%E3%82%A3% E3% 83% BC% E3% 83% 97% E3% 83% A9% E3% 83% BC% E3% 83% 8B% E3% 83% B3% E3% 82% B0% E3% 83% 95% E3% 83% AC% E3% 83% BC% E3% 83% A0% E3% 83% AF% E3% 83% BC% E3% 82% AF) Warnung vor Chainer und Numpy
Kapitel 7 1-4 </ b> [Kapitel 7 Policy Network](https://qiita.com/kazunoriri/items/f91e39e36cf179750e5e#%E7%AC%AC7%E7%AB%A0-%E6%96%B9%E7%AD%96%E3% 83% 8D% E3% 83% 83% E3% 83% 88% E3% 83% AF% E3% 83% BC% E3% 82% AF) 7.1~7.4 policy.py [Bedeutung von 194 Filtern](https://qiita.com/kazunoriri/items/f91e39e36cf179750e5e#%E3%83%95%E3%82%A3%E3%83%AB%E3%82%BF%E3% 83% BC% E6% 95% B0194% E5% 80% 8B% E3% 81% AE% E6% 84% 8F% E5% 91% B3) [Bedeutung des 1x1-Filters](https://qiita.com/kazunoriri/items/f91e39e36cf179750e5e#1x1%E3%83%95%E3%82%A3%E3%83%AB%E3%82%BF%E3%83 % BC% E3% 81% AE% E6% 84% 8F% E5% 91% B3) common.py bb_rotate180() features.py make_input_features() make_input_features_from_board() make_output_label() make_features()
Kapitel 7 5-7 </ b> 7.5~7.7 read_kifu.py read_kifu()
Kapitel 7 8 </ b> 7.8 [Automatische Verwendung von GPU und CPU](https://qiita.com/kazunoriri/items/e8541358bb030742cb19#gpu%E3%81%A8cpu%E3%81%AE%E8%87%AA%E5%8B%95%E4 % BD% BF% E3% 81% 84% E5% 88% 86% E3% 81% 91) [Pickle-Protokoll](https://qiita.com/kazunoriri/items/e8541358bb030742cb19#pickle%E3%81%AE%E3%83%97%E3%83%AD%E3%83%88%E3%82% B3% E3% 83% AB) train_policy.py
Kapitel 7 9 </ b> 7.9 Lernausführung
Kapitel 8 1-4 </ b> [Implementierung der USI-Engine](https://qiita.com/kazunoriri/items/e313efd0026d56e65442#usi%E3%82%A8%E3%83%B3%E3%82%B8%E3%83%B3%E3%81 % AE% E5% AE% 9F% E8% A3% 85) policy_player.py y = self.model(x) logits = y.data[0] probabilities = F.softmax(y).data[0] [Automatisches Umschalten zwischen GPU / CPU und PC](https://qiita.com/kazunoriri/items/e313efd0026d56e65442#gpucpu%E3%81%A8pc%E3%81%AE%E8%87%AA%E5%8B%95 % E5% 88% 87% E3% 82% 8A% E6% 9B% BF% E3% 81% 88) Strategieeinstellung Alle Codes Test [Test über die Befehlszeile](https://qiita.com/kazunoriri/items/e313efd0026d56e65442#%E3%82%B3%E3%83%9E%E3%83%B3%E3%83%89%E3%83% A9% E3% 82% A4% E3% 83% B3% E3% 81% 8B% E3% 82% 89% E3% 83% 86% E3% 82% B9% E3% 83% 88) [Getestet von Google Colab](https://qiita.com/kazunoriri/items/e313efd0026d56e65442#google-colab%E3%81%8B%E3%82%89%E3%83%86%E3%82%B9%E3 % 83% 88) Koordinaten
Kapitel 8 5-9 </ b> [Bei GUI-Software registrieren](https://qiita.com/kazunoriri/items/e0791fb8a975b58db275#gui%E3%82%BD%E3%83%95%E3%83%88%E3%81%AB%E7%99 % BB% E9% 8C% B2) [Problem, dass die Motorregistrierung nicht endet](https://qiita.com/kazunoriri/items/e0791fb8a975b58db275#%E3%82%A8%E3%83%B3%E3%82%B8%E3%83%B3%E7% 99% BB% E9% 8C% B2% E3% 81% 8C% E7% B5% 82% E3% 82% 8F% E3% 82% 89% E3% 81% AA% E3% 81% 84% E5% 95% 8F% E9% A1% 8C) Spiel
Kapitel 9 </ b> [Lerntechnik](https://qiita.com/kazunoriri/items/74c800bfa48cba34bb1c#%E5%AD%A6%E7%BF%92%E3%83%86%E3%82%AF%E3%83%8B% E3% 83% 83% E3% 82% AF) SGD Momentum SGD SGD , Batch Normalization
Word </ b> shogi.BB_SQUARES shogi.COLORS shogi.CSA.Parser.parse_file(filepath) shogi.PIECE_TYPES_WITH_NONE shogi.MAX_PIECES_IN_HAND shogi.SQUARES Klasse verschieben from_square to_square Board-Klasse piece_bb occupied pieces_in_hand
Recommended Posts