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 (
.pthfiles of PyTorch models) to themodelsfolder - Install all requirements with
pip install -r requirements.txtin utils folder - Run the script
python convertTrch2Onnx.pyto convert the models to.onnxformat
- Install all dependencies with
npm install - Run the project with
npm start - You are ready to go! Use
AutoPlaybutton to make engine play for you andflip boardbutton to change the board orientation. At the end of the game you can copy pgn of your game to then analyze it.