This is a draft of a kivy app which can do basics tictactoe game. User can choose to play against cpu.
The iterface is not nice. Yeah! but it can do the job.
- Mainly for fun
- To apply my understanding of kivy and Q-learning free tabular
-
My next plan is to implement a reinforcement learning model from scratch to allow cpu to play on its own. -
It seems that the model plays offensive only. I will train it to play against myself after against itself when I have time for that. -
Update with gui... - Still thinking and waiting for a free time
First of all, you need to download and install its requirement on python3.
git clone https://github.com/aheritianad/kivy-tictactoe.gitcd kivy-tictactoeDo the following if you want to run it in a virtual environment.
python3 -m venv .venvsource .venv/bin/activatepip3 install -r requirements.txtpython3 main.py- For solo, you can choose to either the first player or the second by setting CPU player's name by either
cpu0for easy,cpu1for medium,cpu2for hard orcpu3for expert.
It is important to know that expert will upgrade after each game it plays
- For multiplayer, only avoid
cpu0,cpu1,cpu2andcpu3for players' names