Alpha Zero explanation: here
Alpha Go, DeepMind: here
please run this scripts in Google Colaboratory
- Select GPU.
Edit -> Notebook settings -> GPU
- Mount your Google Drive
#to access your google drive folder
from google.colab import auth, drive, files, output
drive.mount('/content/drive')
- Import the folder from github & setup
#to clone codes
!git clone https://github.com/takehiko-ohkawa/AlphaZero.git
import os
os.chdir('./AlphaZero')
!pwd
!chmod ugo+x ./setup_colab.sh #give a permission
! ./setup_colab.sh #install torch
- Train
!chmod ugo+x ./train_colab.sh
!./train_colab.sh
- make a folder or copy a folder
#make
!mkdir <folder>
#copy
!cp -r <folderA> <folderB> #copy A->B
- Overwrite your code
%%writefile oo.py
<contents of oo.py file>
- Check GPU status
!df -h #desk status
!free -h #memory status
!ps aux #process status
!nvidia-smi #GPU status
!cat /proc/uptime |awk '{print $1/86400"days"}' #remaining time - upto 0.5days
- Download files
files.download(<file>)
Reference: here
Alpha Zero explanation & result: here