Web implementation of this chess engine
This project uses ONNX model instead of PyTorch model to make possible running the engine on the web. Although the model operates on the CPU since utilizeing CUDA cores for acceleration on the web is not feasible the performance remains sufficiently high to ensure an enjoyable gaming experience.
You can try this game here
To run this project you should make this steps:
- Clone this repository
- Add your models (
.pth
files of PyTorch models) to themodels
folder - Install all requirements with
pip install -r requirements.txt
in utils folder - Run the script
python convertTrch2Onnx.py
to convert the models to.onnx
format
- Install all dependencies with
npm install
- Run the project with
npm start
- You are ready to go! Use
AutoPlay
button to make engine play for you andflip board
button to change the board orientation. At the end of the game you can copy pgn of your game to then analyze it.