clarkerubber / python-puzzle-creator Goto Github PK
View Code? Open in Web Editor NEWCreates JSON chess puzzles from PGN chess games.
Creates JSON chess puzzles from PGN chess games.
I modified the code to read from a pgn file. I iterated it till the end and made sure that it is_game_over(). But I am unable to generate any puzzle.
It always gave me this error:
Not Going Deeper:
Ambiguous: True
Game Over: False
Has Best Move: True
Puzzle incomplete
So I booted up the puzzle generator today, and it threw this error:
Traceback (most recent call last):
File "G:\Python-Puzzle-Creator-master\main.py", line 7, in <module>
import chess.uci
ModuleNotFoundError: No module named 'chess.uci'
How can I get this "chess.uci" module?
pip says there is no such module.
Here's an example:
[Unit]
Description=Puzzles instance
After=network.target
[Service]
User=puzzles
Group=puzzles
WorkingDirectory=/var/www/puzzles
Environment=PATH=/var/www/puzzles/puzzles/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games
ExecStart=/bin/bash -c 'source /var/www/puzzles/puzzles/bin/activate; cd /var/www/puzzles/Python-Puzzle-Creator ; python main.py $key $instance $threads'
Restart=always
[Install]
WantedBy=multi-user.target
By convention, it is assumed that move history should not be considered for a puzzle (except that which can be determined by retrograde analysis). Therefore, players assume this puzzle has multiple solutions:
https://lichess.org/training/97367
python-chess 0.17 changed pop_count() to popcount() so there is an error in the code when you run main.py
https://github.com/niklasf/python-chess/blob/55c6031465d14f386f1f88754a9baafd1d8813db/CHANGELOG.rst
I don´t know if pip can install specific versions, maybe that can solve the problem (instlall the specific 0.15 version) and update the readme file with it. Or change the code to popcount()
the command line reads:
python main.py <Secret API Token> <#Threads = 4> <Hash (MBytes) = 2048>
where can I get the API token from?
I have an account on lichess and there's some kind of API key generator,
but I could not figure out which options should be turned on for the puzzle generator to work?
thanks!
Provide a --quiet option for daemonization.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.