Difference between revisions of "CrazyAra"

From Chessprogramming wiki
Jump to: navigation, search
 
(9 intermediate revisions by the same user not shown)
Line 3: Line 3:
 
[[FILE:Ara chloroptera -Brookfield Zoo-8.jpg|border|right|thumb| [https://en.wikipedia.org/wiki/Red-and-green_macaw Ara chloropterus] <ref>[https://en.wikipedia.org/wiki/Red-and-green_macaw Red-and-green macaw] in [https://en.wikipedia.org/wiki/Brookfield_Zoo Brookfield Zoo], [https://commons.wikimedia.org/wiki/File:Ara_chloroptera_-Brookfield_Zoo-8.jpg Photo] by [https://www.flickr.com/photos/22321795@N04 Nimesh M], July 05, 2008, [https://en.wikipedia.org/wiki/Wikimedia_Commons Wikimedia Commons]</ref> ]]  
 
[[FILE:Ara chloroptera -Brookfield Zoo-8.jpg|border|right|thumb| [https://en.wikipedia.org/wiki/Red-and-green_macaw Ara chloropterus] <ref>[https://en.wikipedia.org/wiki/Red-and-green_macaw Red-and-green macaw] in [https://en.wikipedia.org/wiki/Brookfield_Zoo Brookfield Zoo], [https://commons.wikimedia.org/wiki/File:Ara_chloroptera_-Brookfield_Zoo-8.jpg Photo] by [https://www.flickr.com/photos/22321795@N04 Nimesh M], July 05, 2008, [https://en.wikipedia.org/wiki/Wikimedia_Commons Wikimedia Commons]</ref> ]]  
  
'''CrazyAra''',<br/>
+
'''CrazyAra''', (ClassicAra, MultiAra)<br/>
an [[UCI]] compatible [[Chess#Variants|chess variant]] [[:Category:Open Source|open source]] engine licensed under the [[Free Software Foundation#GPL|GPL v3.0]].
+
a family of [[UCI]] compatible [[Chess#Variants|chess variant]] [[:Category:Open Source|open source]] engines licensed under the [[Free Software Foundation#GPL|GPL v3.0]].
 
CrazyAra started as a [https://en.wikipedia.org/wiki/Academic_term#Synonyms semester] project by [[Johannes Czech]], [[Moritz Willig]] and [[Alena Beyer]] for the course ''Deep Learning: Methods and Architectures'' at the [[Darmstadt University of Technology|TU Darmstadt]] in summer 2018, headed by [[Kristian Kersting]] and [[Johannes Fürnkranz]].
 
CrazyAra started as a [https://en.wikipedia.org/wiki/Academic_term#Synonyms semester] project by [[Johannes Czech]], [[Moritz Willig]] and [[Alena Beyer]] for the course ''Deep Learning: Methods and Architectures'' at the [[Darmstadt University of Technology|TU Darmstadt]] in summer 2018, headed by [[Kristian Kersting]] and [[Johannes Fürnkranz]].
 
The project was inspired by the [[Deep Learning|deep learning]] and [[Monte-Carlo Tree Search|MCTS]] techniques described in [[DeepMind|DeepMind's]] [[AlphaZero]] papers   
 
The project was inspired by the [[Deep Learning|deep learning]] and [[Monte-Carlo Tree Search|MCTS]] techniques described in [[DeepMind|DeepMind's]] [[AlphaZero]] papers   
Line 13: Line 13:
 
<ref>[https://lichess.org/study/uAJmnF3w CrazyAra Crazyhouse]</ref> <ref>[https://zhchess.blogspot.com/2018/12/crazyara-plays-jannlee-for-christmas.html Crazyhouse Chess: CrazyAra plays JannLee for Christmas], December 26, 2018</ref>.
 
<ref>[https://lichess.org/study/uAJmnF3w CrazyAra Crazyhouse]</ref> <ref>[https://zhchess.blogspot.com/2018/12/crazyara-plays-jannlee-for-christmas.html Crazyhouse Chess: CrazyAra plays JannLee for Christmas], December 26, 2018</ref>.
  
 +
=Continuation=
 
As subject of his master thesis <ref>[[Johannes Czech]] ('''2019'''). ''Deep Reinforcement Learning for Crazyhouse''. Master thesis, [[Darmstadt University of Technology|TU Darmstadt]], [https://ml-research.github.io/papers/czech2019deep.pdf pdf]</ref>,  
 
As subject of his master thesis <ref>[[Johannes Czech]] ('''2019'''). ''Deep Reinforcement Learning for Crazyhouse''. Master thesis, [[Darmstadt University of Technology|TU Darmstadt]], [https://ml-research.github.io/papers/czech2019deep.pdf pdf]</ref>,  
 
Johannes Czech continued the development in porting the engine to [[Cpp|C++]] and to further apply [[Reinforcement Learning|reinforcement learning]] to Crazyhouse and other chess variants including [[Chess960]].
 
Johannes Czech continued the development in porting the engine to [[Cpp|C++]] and to further apply [[Reinforcement Learning|reinforcement learning]] to Crazyhouse and other chess variants including [[Chess960]].
 
While the initial version uses [[Python-chess]] by [[Niklas Fiekas]], the C++ version uses a multi variant [[Stockfish]] fork by [[Daniel Dugovic]] <ref>[https://github.com/ddugovic/Stockfish GitHub - ddugovic/Stockfish: BETA multi-variant fork of popular UCI chess engine; final release for now]</ref>
 
While the initial version uses [[Python-chess]] by [[Niklas Fiekas]], the C++ version uses a multi variant [[Stockfish]] fork by [[Daniel Dugovic]] <ref>[https://github.com/ddugovic/Stockfish GitHub - ddugovic/Stockfish: BETA multi-variant fork of popular UCI chess engine; final release for now]</ref>
 
for [[Move Generation|move generation]], [[Board Representation|board representation]] and [[Syzygy Bases|Syzygy]] parsing.
 
for [[Move Generation|move generation]], [[Board Representation|board representation]] and [[Syzygy Bases|Syzygy]] parsing.
 +
To feature more chess variants, more recently [[Fairy-Stockfish]] by [[Fabian Fichter]] was incorporated <ref>[https://github.com/QueensGambit/CrazyAra/releases Releases · QueensGambit/CrazyAra · GitHub]</ref>,
 +
as for instance used in [[Maximilian Langer|Maximilian Langer's]] [[Chinese Chess|Xiangqi]] version of CrazyAra <ref>[[Maximilian Langer]] ('''2021'''). ''Evaluation of Monte-Carlo Tree Search for Xiangqi''. B.Sc. thesis, [[Darmstadt University of Technology|TU Darmstadt]], [https://ml-research.github.io/papers/langer2021xiangqi.pdf pdf]</ref>.
  
 
=Network=
 
=Network=
Line 30: Line 33:
  
 
=ClassicAra=
 
=ClassicAra=
'''ClassicAra''' is a version of CrazyAra to play classical chess as well as [[Chess960]]. ClassicAra had its tournament debut as [[TCEC Season 21]] in Spring 2021.
+
'''ClassicAra''' is a version of CrazyAra to play classical chess as well as [[Chess960]]. ClassicAra had its tournament debut as [[TCEC Season 21]] in Spring 2021, not yet improved by [[Reinforcement Learning|reinforcement learning]] <ref>[http://www.talkchess.com/forum3/viewtopic.php?f=2&t=77020&start=58 Re: ClassicAra Chess Engine..World Record Download!!] by [[Johannes Czech]], [[CCC]], May 20, 2021</ref>.
 +
 
 +
=MultiAra=
 +
'''MultiAra''', released in August 2021, is a version of the Ara project which supports all [[Chess#Variants|chess variants]] available on [[Lichess]] <ref>[https://www.talkchess.com/forum3/viewtopic.php?f=2&t=78027 CrazyAra, ClassicAra, MultiAra 0.9.5 release] by [[Johannes Czech]], August 26, 2021</ref>.
  
 
=See also=
 
=See also=
Line 49: Line 55:
 
* [[Johannes Czech]], [[Patrick Korus]], [[Kristian Kersting]] ('''2021'''). ''[https://ojs.aaai.org/index.php/ICAPS/article/view/15952 Improving AlphaZero Using Monte-Carlo Graph Search]''. [https://ojs.aaai.org/index.php/ICAPS/issue/view/380 Proceedings of the Thirty-First International Conference on Automated Planning and Scheduling], Vol. 31, [https://www.ml.informatik.tu-darmstadt.de/papers/czech2021icaps_mcgs.pdf pdf]
 
* [[Johannes Czech]], [[Patrick Korus]], [[Kristian Kersting]] ('''2021'''). ''[https://ojs.aaai.org/index.php/ICAPS/article/view/15952 Improving AlphaZero Using Monte-Carlo Graph Search]''. [https://ojs.aaai.org/index.php/ICAPS/issue/view/380 Proceedings of the Thirty-First International Conference on Automated Planning and Scheduling], Vol. 31, [https://www.ml.informatik.tu-darmstadt.de/papers/czech2021icaps_mcgs.pdf pdf]
 
* [[Maximilian Langer]] ('''2021'''). ''Evaluation of Monte-Carlo Tree Search for Xiangqi''. B.Sc. thesis, [[Darmstadt University of Technology|TU Darmstadt]], [https://ml-research.github.io/papers/langer2021xiangqi.pdf pdf] » [[Chinese Chess|Xiangqi]]
 
* [[Maximilian Langer]] ('''2021'''). ''Evaluation of Monte-Carlo Tree Search for Xiangqi''. B.Sc. thesis, [[Darmstadt University of Technology|TU Darmstadt]], [https://ml-research.github.io/papers/langer2021xiangqi.pdf pdf] » [[Chinese Chess|Xiangqi]]
 +
* [[Maximilian Alexander Gehrke]] ('''2021'''). ''Assessing Popular Chess Variants Using Deep Reinforcement Learning''. Master thesis, [[Darmstadt University of Technology|TU Darmstadt]], [https://ml-research.github.io/papers/gehrke2021assessing.pdf pdf]
  
 
=Forum Posts=
 
=Forum Posts=
Line 55: Line 62:
 
* [http://www.talkchess.com/forum3/viewtopic.php?f=2&t=76209&start=199 Re: New engine releases & news 2021] by [[Günther Simon]], [[CCC]], April 05, 2021
 
* [http://www.talkchess.com/forum3/viewtopic.php?f=2&t=76209&start=199 Re: New engine releases & news 2021] by [[Günther Simon]], [[CCC]], April 05, 2021
 
* [http://www.talkchess.com/forum3/viewtopic.php?f=2&t=77020 ClassicAra Chess Engine..World Record Download!!] by supersharp77, [[CCC]], April 06, 2021
 
* [http://www.talkchess.com/forum3/viewtopic.php?f=2&t=77020 ClassicAra Chess Engine..World Record Download!!] by supersharp77, [[CCC]], April 06, 2021
 +
: [http://www.talkchess.com/forum3/viewtopic.php?f=2&t=77020&start=58 Re: ClassicAra Chess Engine..World Record Download!!] by [[Johannes Czech]], [[CCC]], May 20, 2021
 +
: [http://www.talkchess.com/forum3/viewtopic.php?f=2&t=77020&start=70 Re: ClassicAra Chess Engine..World Record Download!!] by [[Johannes Czech]], [[CCC]], May 25, 2021 <ref>[https://tcec-chess.com/#div=l4&game=127&season=21 Drofa 3.0.0 vs ClassicAra 0.9.2.post1 - TCEC Season 21 - League 4]</ref>
 +
* [http://www.talkchess.com/forum3/viewtopic.php?f=2&t=77670 Has CrazyAra really improved because of MTGS ?] by George Pichard, [[CCC]], July 08, 2021
 +
* [https://www.talkchess.com/forum3/viewtopic.php?f=2&t=78027 CrazyAra, ClassicAra, MultiAra 0.9.5 release] by [[Johannes Czech]], August 26, 2021
  
 
=External Links=
 
=External Links=
Line 73: Line 84:
 
* [https://en.wikipedia.org/wiki/Ara_(bird) Ara (bird) from Wikipedia]
 
* [https://en.wikipedia.org/wiki/Ara_(bird) Ara (bird) from Wikipedia]
 
* [https://en.wikipedia.org/wiki/Ara Ara from Wikipedia]
 
* [https://en.wikipedia.org/wiki/Ara Ara from Wikipedia]
 +
* [[:Category:Weather Report|Weather Report]] - [https://en.wikipedia.org/wiki/Birdland_(song) Birdland], [https://en.wikipedia.org/wiki/The_Midnight_Special_(TV_series) The Midnight Special], April 1977, [https://en.wikipedia.org/wiki/YouTube YouTube] Video
 +
: lineup: [[:Category:Joe Zawinul|Joe Zawinul]], [[:Category:Wayne Shorter|Wayne Shorter]], [[:Category:Jaco Pastorius|Jaco Pastorius]], [https://en.wikipedia.org/wiki/Alex_Acu%C3%B1a Alex Acuña], [https://en.wikipedia.org/wiki/Manolo_Badrena Manolo Badrena]
 +
: {{#evu:https://www.youtube.com/watch?v=0MOOSx85rqs|alignment=left|valignment=top}}
  
 
=References=  
 
=References=  
Line 91: Line 105:
 
[[Category:Linux]]
 
[[Category:Linux]]
 
[[Category:Mac]]
 
[[Category:Mac]]
 +
[[Category:Thesis]]
 
[[Category:Bird]]
 
[[Category:Bird]]
 +
[[Category:Weather Report]]
 +
[[Category:Jaco Pastorius]]
 +
[[Category:Joe Zawinul]]
 +
[[Category:Wayne Shorter]]

Latest revision as of 11:23, 7 October 2021

Home * Engines * CrazyAra

CrazyAra, (ClassicAra, MultiAra)
a family of UCI compatible chess variant open source engines licensed under the GPL v3.0. CrazyAra started as a semester project by Johannes Czech, Moritz Willig and Alena Beyer for the course Deep Learning: Methods and Architectures at the TU Darmstadt in summer 2018, headed by Kristian Kersting and Johannes Fürnkranz. The project was inspired by the deep learning and MCTS techniques described in DeepMind's AlphaZero papers [2] [3], the goal to train a deep convolutional neural network to play Crazyhouse trained by supervised learning on human data - the initial version of CrazyAra entirely written in Python [4]. In December 2018, CrazyAra won a five game Crazyhouse online-match versus Justin Tan aka JannLee with 4-1 [5] [6].

Continuation

As subject of his master thesis [7], Johannes Czech continued the development in porting the engine to C++ and to further apply reinforcement learning to Crazyhouse and other chess variants including Chess960. While the initial version uses Python-chess by Niklas Fiekas, the C++ version uses a multi variant Stockfish fork by Daniel Dugovic [8] for move generation, board representation and Syzygy parsing. To feature more chess variants, more recently Fairy-Stockfish by Fabian Fichter was incorporated [9], as for instance used in Maximilian Langer's Xiangqi version of CrazyAra [10].

Network

CrazyAra uses MXNet as it's deep learning framework - with three NN back-ends to run the NN inference available, Nvidia's TensorRT built on CUDA (GPU only), MXNet and Torch [11]. The input representation is a hybrid between chess and Shogi and compared to the AlphaZero description avoids the history of past board representations [12]. In CrazyAra v0.2.0 a newly designed architecture was used which is called RISE (ResneXt, Inception, Squeeze, Excitation). The model uses mixed depth-wise convolutional kernels, efficient squeeze excitation modules, use of 5x5 convolutions in deeper layers, and hard sigmoid instead of sigmoid activation functions. The proposed model architecture has fewer parameters, faster inference and training time while maintaining an equal amount of depth compared to the architecture proposed by DeepMind (19 residual layers with 256 filters) [13]. Similar to AlphaZero, the output is represented by a value and policy head, the latter implemented as vector of moves [14] [15].

Monte-Carlo Graph Search

CrazyAra optionally features an improvement of AlphaZero's MCTS / PUCT algorithm, considering transpositions - dubbed Monte-Carlo Graph Search based on a directed acyclic graph (DAG) instead of a tree structure [16] [17].

ClassicAra

ClassicAra is a version of CrazyAra to play classical chess as well as Chess960. ClassicAra had its tournament debut as TCEC Season 21 in Spring 2021, not yet improved by reinforcement learning [18].

MultiAra

MultiAra, released in August 2021, is a version of the Ara project which supports all chess variants available on Lichess [19].

See also

Publications

Forum Posts

Re: ClassicAra Chess Engine..World Record Download!! by Johannes Czech, CCC, May 20, 2021
Re: ClassicAra Chess Engine..World Record Download!! by Johannes Czech, CCC, May 25, 2021 [20]

External Links

Chess Engine

GitHub

Reports

Misc

lineup: Joe Zawinul, Wayne Shorter, Jaco Pastorius, Alex Acuña, Manolo Badrena

References

  1. Red-and-green macaw in Brookfield Zoo, Photo by Nimesh M, July 05, 2008, Wikimedia Commons
  2. David Silver, Thomas Hubert, Julian Schrittwieser, Ioannis Antonoglou, Matthew Lai, Arthur Guez, Marc Lanctot, Laurent Sifre, Dharshan Kumaran, Thore Graepel, Timothy Lillicrap, Karen Simonyan, Demis Hassabis (2017). Mastering Chess and Shogi by Self-Play with a General Reinforcement Learning Algorithm. arXiv:1712.01815
  3. David Silver, Thomas Hubert, Julian Schrittwieser, Ioannis Antonoglou, Matthew Lai, Arthur Guez, Marc Lanctot, Laurent Sifre, Dharshan Kumaran, Thore Graepel, Timothy Lillicrap, Karen Simonyan, Demis Hassabis (2018). A general reinforcement learning algorithm that masters chess, shogi, and Go through self-play. Science, Vol. 362, No. 6419
  4. GitHub - QueensGambit/CrazyAra: A Deep Learning UCI-Chess Variant Engine written in C++ & Python
  5. CrazyAra Crazyhouse
  6. Crazyhouse Chess: CrazyAra plays JannLee for Christmas, December 26, 2018
  7. Johannes Czech (2019). Deep Reinforcement Learning for Crazyhouse. Master thesis, TU Darmstadt, pdf
  8. GitHub - ddugovic/Stockfish: BETA multi-variant fork of popular UCI chess engine; final release for now
  9. Releases · QueensGambit/CrazyAra · GitHub
  10. Maximilian Langer (2021). Evaluation of Monte-Carlo Tree Search for Xiangqi. B.Sc. thesis, TU Darmstadt, pdf
  11. 2. Build neural network inference library · QueensGambit/CrazyAra Wiki · GitHub
  12. Input representation · QueensGambit/CrazyAra Wiki · GitHub
  13. Model architecture · QueensGambit/CrazyAra Wiki · GitHub
  14. Output representation · QueensGambit/CrazyAra Wiki · GitHub
  15. Network visualization · QueensGambit/CrazyAra Wiki · GitHub
  16. Johannes Czech, Patrick Korus, Kristian Kersting (2020). Monte-Carlo Graph Search for AlphaZero. arXiv:2012.11045
  17. Engine settings · QueensGambit/CrazyAra Wiki · GitHub
  18. Re: ClassicAra Chess Engine..World Record Download!! by Johannes Czech, CCC, May 20, 2021
  19. CrazyAra, ClassicAra, MultiAra 0.9.5 release by Johannes Czech, August 26, 2021
  20. Drofa 3.0.0 vs ClassicAra 0.9.2.post1 - TCEC Season 21 - League 4

Up one Level