Final project of the Reinforcement Learning discipline. Here is an implementation of the minesweeper game and codes for training and evaluating reinforcement learning models for the minesweeper game.
To train and run a model you need to have the following Python libraries installed
pip install pygame gymnasium time stable_baselines3
To visualize the training process, you need to have the following library
pip install tensorboard
To train a model, you need to run the following command (changing the path to save the model and logs)
python src/model.py
In the models folder we have different time versions of the model trained with different numbers of steps (the versions were presented during the presentation and the slides can be seen in the file slides.pdf
). We can test a certain model using the command below, changing the global variable that points to the model
python src/run_load_player.py
In the logs
folder there is information obtained during model training, using the command below it can be viewed in HTML format using the tensorboard
library
tensorboard --logdir=logs/logsv6 --port=6000