Code Monkey home page Code Monkey logo

compression's Introduction

Chess clock and move compression algorithms for lichess.org

Disclaimer

This library was migrated from the Java language to the Scala language. Only the language syntax changed to Scala; the design and paradigms of the Java program were kept. This is not how Scala code should be written, it is not idiomatic.

Blog posts

License

This library is licensed under the GNU Affero General Public License 3 or any later version at your option. See LICENSE for the full license text.

compression's People

Contributors

niklasf avatar ornicar avatar lenguyenthanh avatar schlawg avatar ddugovic avatar kunal-mandalia avatar sergiuszkierat avatar

Stargazers

 avatar  avatar Christopher Akiki avatar Panagiotis avatar Herald Gersdorff avatar Aurélien Pillevesse avatar SagXD avatar uhuru avatar  avatar Jonathan avatar Taketoday avatar Gabriel Mathiuce avatar Filipe Santos avatar João Lucas  avatar Holocen in Neogen avatar Rémy Marquis avatar  avatar Michael Mata avatar Trevor Elkins avatar Boris Verkhovskiy avatar  avatar wh1stl3r avatar Noah Seger avatar  avatar ebigram avatar YoungChief avatar Raph avatar Barnabás Domozi avatar David P avatar  avatar Lucien Fiorini avatar  avatar Jack Myrick avatar  avatar  avatar Joohun, Maeng avatar inceptmyth avatar  avatar Aravindh Rajagopalan avatar Igor M. avatar Tomasz Cichocki avatar Nikheel avatar Girish Reddy avatar Lawrence Wachira avatar Stanley Chan avatar Aditya Ramesh avatar Shikhar Vaish avatar Harshal Sheth avatar  avatar Cameron Conn avatar Mahmoud Dolah avatar Marco avatar Samet Sevindik avatar  avatar Harmon avatar  avatar Dimiter 'malkia' Stanev avatar Jorge Lambraño avatar S. Tarık Çetin avatar ik5 avatar GAURAV avatar Abdallah Ahmed avatar Devon avatar Orestis Ousoultzoglou avatar Ozioma avatar Max Fan avatar Jeferson Alves avatar  avatar Thibaut Vandenbussche avatar  avatar Peter Medus avatar Jon Baer avatar Nate Kresge avatar Ian Littlewood avatar  avatar Kemal Ogun Isik avatar Zach Albia avatar Lucas T. A. Gouvêa avatar Andrii Mishchenko avatar Muharrem Okutan avatar Luis Emilio Velasco Sánchez avatar Hieu Do avatar  avatar  avatar Deepak Tripathi avatar Navya  avatar Puspraj Jaiswal avatar Tosotada avatar Chris Katzmann avatar Rob Scott avatar Jose avatar Steven Shaw avatar Kjell Denti avatar  avatar Kyle avatar Grzegorz Adam Hankiewicz avatar Matt Singletary avatar Richard Smith avatar  avatar Caio Tonetti avatar

Watchers

 avatar Lakin Wecker avatar Trevor Fitzgerald avatar  avatar Vincent Velociter avatar  avatar James Cloos avatar  avatar Stanley Chan avatar  avatar Benedikt Werner avatar  avatar  avatar  avatar  avatar

compression's Issues

Benchmark compression algorithm

Current pull requests are stale because there is no benchmark to evaluate them. JMH can be used to implement those benchmarks. The benchmarks should measure compression ratio, compression speed and decompression speed. You can use the Lichess games as data.

pin and skewer

Flag of pin and skewer should be not checked if no bishops , no rooks and no Queen are present

Feature-Request: Tactic Problem reporting.

Tactics/Puzzles on lichess are taken from it's database, so the reply/continuing move of the puzzle is the move played in the puzzle.
However, the issue with this is, even if the first move is the best(according to the computer/stockfish chess engine), the move that opponent takes sometimes isn't the best. So in a way, we are expected to expect that the opponent will move do a blunder and then we would react to it.
Example:
image
The green lines show the move sequence of the puzzle. We clearly can see that bishopC4(by black) is a blunder and we should not expect the player to do so, however, the puzzle is making up expect it.

There are 2 solutions in my head(relatively difficult but better, and relatively easier but not the best):

  1. Computer shall analyse such games and do the tactically best move omitting the blunder made by the player.
  2. There could be sub-forum, wherein, people can submit such puzzles and then, the puzzle could be removed or omitted.

Lichess Time Bug

Hello.
I played a game of chess against someone and gave my opponent more time. So that he has 5min time to think about it. For some reason lichess always interrupts the game. The reason for this is "time out". But both players still have time. What could be the reason for that. The game ends immediately if white wants to make the first move.
Forum: https://lichess.org/forum/general-chess-discussion/lichess-time-bug

Question: Huffman tree impact on small game

Greeting and my apologies for using the issue tracker for just a question but here what I would ask :

I just read Lichess post about this compressor
https://lichess.org/blog/Wqa7GiAAAOIpBLoY/developer-update-275-improved-game-compression

And I find it really brilliant, but then I started to remember courses I took lot of years ago and just curious about how such implementation perform against different chess game sizes.

I am using my memory about Huffman encoding, so probably I am making mistakes, but I remember that can be expensive to store the tree for short messages. And for that reason is not always used as compression algorithm.
For that reason I am curious about data on this problem (compression of chess games) to understand if there is some threshold where simpler compression algorithm are cheaper (eg an adaptation of Zigzag VLQ because we are talking about byte/int).

Another way to cut head of small games, and improving in general compression rate may be also the use of shared opening book. So you can use just a number to pinpoint a sequence in the opening.

So to summarize, my question did you already thought about those two possible improvements? I think probably yes, then if possible can you please share your consideration about splitting the compression phase, because I am really curious about it.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.