Discuss Scratch

HasiLover
Scratcher
100+ posts

Scratch Chess Engine - Game of Kings

Im currently Making a Study with a Bunch of Games between Scratch Chess Engines.
ArnoHu
Scratcher
1000+ posts

Scratch Chess Engine - Game of Kings

HasiLover wrote:

Im currently Making a Study with a Bunch of Games between Scratch Chess Engines.

Cool, can you provide the link?
HasiLover
Scratcher
100+ posts

Scratch Chess Engine - Game of Kings

ArnoHu wrote:

HasiLover wrote:

Im currently Making a Study with a Bunch of Games between Scratch Chess Engines.

Cool, can you provide the link?
Sure,but before that i will eulate a few more Games.
InkTheCoder
Scratcher
19 posts

Scratch Chess Engine - Game of Kings

ArnoHu wrote:

birdracerthree wrote:

I have a playable version of my engine saved, however, it's relatively slow. Does anyone have any ideas on how I can debug my alpha-beta code? (At the moment, nothing is pruning because beta is constantly infinity.) (Also, the engine played Nxe4 on depth 2 after e4 Nf6 Nc3 despite the continuation being 3. Nxe4 )

Is it published? Maybe publish on a test account? You mean debug for performance? Either use your browser's dev tools profiler when on TurboWarp (e.g. F12 on Chrome), or measure the time for code executions via Scratch days-since-2000 block.


Only suggestion is to look over ad try to figure out what's causing the bug and go from there,basic stuff sorry. I'm not sure what else to tell you due to my inexperience

When you grow old and are talking to your grandchildren; make sure you have many good stories to rant about. -InkTheCoder

Hey you! Come check me out…on Scratch.
My Profile: https://scratch.mit.edu/users/InkTheCoder/

birdracerthree
Scratcher
500+ posts

Scratch Chess Engine - Game of Kings

InkTheCoder wrote:

ArnoHu wrote:

birdracerthree wrote:

I have a playable version of my engine saved, however, it's relatively slow. Does anyone have any ideas on how I can debug my alpha-beta code? (At the moment, nothing is pruning because beta is constantly infinity.) (Also, the engine played Nxe4 on depth 2 after e4 Nf6 Nc3 despite the continuation being 3. Nxe4 )

Is it published? Maybe publish on a test account? You mean debug for performance? Either use your browser's dev tools profiler when on TurboWarp (e.g. F12 on Chrome), or measure the time for code executions via Scratch days-since-2000 block.


Only suggestion is to look over ad try to figure out what's causing the bug and go from there,basic stuff sorry. I'm not sure what else to tell you due to my inexperience
Thanks, but I figured it out.
HasiLover
Scratcher
100+ posts

Scratch Chess Engine - Game of Kings

The Study is out:https://lichess.org/study/eWKrNZpD/eWnHQh5G ,itsonly 8 Starting Games featuring the Engines: Game of Kings,Bonsai Chess, White Dove, LowDoor, Wolverine, Element, Midecah's chess engine, DrawFish, PseudoChess.

There were alot of Crazy Games,including a Game with 13 Blunders in a Row.
There was also a Game, Game of Kings underpromoted to a Rook.

Last edited by HasiLover (Sept. 14, 2023 15:51:50)

ArnoHu
Scratcher
1000+ posts

Scratch Chess Engine - Game of Kings

HasiLover wrote:

The Study is out:https://lichess.org/study/eWKrNZpD/eWnHQh5G ,itsonly 8 Starting Games featuring the Engines: Game of Kings,Bonsai Chess, White Dove, LowDoor, Wolverine, Element, Midecah's chess engine, DrawFish, PseudoChess.

There were alot of Crazy Games,including a Game with 13 Blunders in a Row.
There was also a Game, Game of Kings underpromoted to a Rook.

That is very cool, can you trigger a computer analysis for each game, by clicking the button in the resp. tab? Only studio owner can request that. Thank you!

About the underpromotion, that is seldom, but might be required to avoid stalemate. Here it was something else, GoK saw the checkmate in 3 moves, and it did not matter what to promote to, same result.

Last edited by ArnoHu (Sept. 14, 2023 17:12:04)

ArnoHu
Scratcher
1000+ posts

Scratch Chess Engine - Game of Kings

HasiLover wrote:

The Study is out:https://lichess.org/study/eWKrNZpD/eWnHQh5G ,itsonly 8 Starting Games featuring the Engines: Game of Kings,Bonsai Chess, White Dove, LowDoor, Wolverine, Element, Midecah's chess engine, DrawFish, PseudoChess.

There were alot of Crazy Games,including a Game with 13 Blunders in a Row.
There was also a Game, Game of Kings underpromoted to a Rook.

Average accuracy (and number of games):
GoK:         90% (3)
Bonsai: 87% (3)
Wolverine: 85% (1)
LowDoor: 77% (3)
White Dove: 75% (2)
Midecah: 56% (1)
DrawFish: 52% (1)
PseudoChess: 50% (1)
Element: 31% (1)

Last edited by ArnoHu (Sept. 14, 2023 17:16:03)

birdracerthree
Scratcher
500+ posts

Scratch Chess Engine - Game of Kings

ArnoHu wrote:

HasiLover wrote:

The Study is out:https://lichess.org/study/eWKrNZpD/eWnHQh5G ,itsonly 8 Starting Games featuring the Engines: Game of Kings,Bonsai Chess, White Dove, LowDoor, Wolverine, Element, Midecah's chess engine, DrawFish, PseudoChess.

There were alot of Crazy Games,including a Game with 13 Blunders in a Row.
There was also a Game, Game of Kings underpromoted to a Rook.

Average accuracy (and number of games):
GoK:         90% (3)
Bonsai: 87% (3)
Wolverine: 85% (1)
LowDoor: 77% (3)
White Dove: 75% (2)
Midecah: 56% (1)
DrawFish: 52% (1)
PseudoChess: 50% (1)
Element: 31% (1)
I'm assuming Element played Ng8 because of the lack of quiescence. I think there's one more bug in quiescence I need to fix. Then I'll remove the unnecessary code I have to speed things up. Also, play Element on turbo mode because I don't have run without refresh.
HasiLover
Scratcher
100+ posts

Scratch Chess Engine - Game of Kings

Whilst testing Flame,by letting it play against GoK Easy1,this funny Game happened:https://lichess.org/study/2y0Aek5H/eZzuLhlV
HasiLover
Scratcher
100+ posts

Scratch Chess Engine - Game of Kings

I released a new Version of my Flame chess Engine:https://scratch.mit.edu/projects/894019758/ ,Flame ONN learned how to Play Chess,by natural Selection.It has what i Call an ONN which basically is just a long string of Inputs, changed by a Hiddenlayer each and then the Output changes the Eval.Its a very Aggresive Engine and only looks 1 Ply deep, but doesnt Blunder its pieces directly,a Crazy thing is that it plays D5 and E5,without having an Input for center control.

Last edited by HasiLover (Sept. 15, 2023 19:38:53)

ArnoHu
Scratcher
1000+ posts

Scratch Chess Engine - Game of Kings

HasiLover wrote:

I released a new Version of my Flame chess Engine:https://scratch.mit.edu/projects/894019758/ ,Flame ONN learned how to Play Chess,by natural Selection.It has what i Call an ONN which basically is just a long string of Inputs, changed by a Hiddenlayer each and then the Output changes the Eval.Its a very Aggresive Engine and only looks 1 Ply deep, but doesnt Blunder its pieces directly,a Crazy thing is that it plays D5 and E5,without having an Input for center control.

Cool, but that seems to be a training version for two players? Can we run the engine somewhere?
HasiLover
Scratcher
100+ posts

Scratch Chess Engine - Game of Kings

ArnoHu wrote:

HasiLover wrote:

I released a new Version of my Flame chess Engine:https://scratch.mit.edu/projects/894019758/ ,Flame ONN learned how to Play Chess,by natural Selection.It has what i Call an ONN which basically is just a long string of Inputs, changed by a Hiddenlayer each and then the Output changes the Eval.Its a very Aggresive Engine and only looks 1 Ply deep, but doesnt Blunder its pieces directly,a Crazy thing is that it plays D5 and E5,without having an Input for center control.

Cool, but that seems to be a training version for two players? Can we run the engine somewhere?
No,its completely playable,just go on turbowarp with turbo mode
ArnoHu
Scratcher
1000+ posts

Scratch Chess Engine - Game of Kings

HasiLover wrote:

ArnoHu wrote:

HasiLover wrote:

I released a new Version of my Flame chess Engine:https://scratch.mit.edu/projects/894019758/ ,Flame ONN learned how to Play Chess,by natural Selection.It has what i Call an ONN which basically is just a long string of Inputs, changed by a Hiddenlayer each and then the Output changes the Eval.Its a very Aggresive Engine and only looks 1 Ply deep, but doesnt Blunder its pieces directly,a Crazy thing is that it plays D5 and E5,without having an Input for center control.

Cool, but that seems to be a training version for two players? Can we run the engine somewhere?
No,its completely playable,just go on turbowarp with turbo mode

I did. Black did not move. But I could move its pieces.
HasiLover
Scratcher
100+ posts

Scratch Chess Engine - Game of Kings

ArnoHu wrote:

HasiLover wrote:

ArnoHu wrote:

HasiLover wrote:

I released a new Version of my Flame chess Engine:https://scratch.mit.edu/projects/894019758/ ,Flame ONN learned how to Play Chess,by natural Selection.It has what i Call an ONN which basically is just a long string of Inputs, changed by a Hiddenlayer each and then the Output changes the Eval.Its a very Aggresive Engine and only looks 1 Ply deep, but doesnt Blunder its pieces directly,a Crazy thing is that it plays D5 and E5,without having an Input for center control.

Cool, but that seems to be a training version for two players? Can we run the engine somewhere?
No,its completely playable,just go on turbowarp with turbo mode

I did. Black did not move. But I could move its pieces.
Dont click its pieces,just wait a bit.

Last edited by HasiLover (Sept. 15, 2023 21:09:53)

HasiLover
Scratcher
100+ posts

Scratch Chess Engine - Game of Kings

Try this Link:https://turbowarp.org/894019758?turbo,it will take around 20 seconds for a Move, turn on turbomode,you can move its pieces to set the Opening.

Last edited by HasiLover (Sept. 15, 2023 21:19:41)

ArnoHu
Scratcher
1000+ posts

Scratch Chess Engine - Game of Kings

HasiLover wrote:

Try this Link:https://turbowarp.org/894019758?turbo,it will take around 20 seconds for a Move, turn on turbomode,you can move its pieces to set the Opening.

Quick and dirty remix, removing all those busy loops, that slowed down the engine: https://turbowarp.org/894119132 Also, turbo mode not necessary.
HasiLover
Scratcher
100+ posts

Scratch Chess Engine - Game of Kings

ArnoHu wrote:

HasiLover wrote:

Try this Link:https://turbowarp.org/894019758?turbo,it will take around 20 seconds for a Move, turn on turbomode,you can move its pieces to set the Opening.

Quick and dirty remix, removing all those busy loops, that slowed down the engine: https://turbowarp.org/894119132 Also, turbo mode not necessary.
Wow,this is great.The Engine is way faster now!
ArnoHu
Scratcher
1000+ posts

Scratch Chess Engine - Game of Kings

HasiLover wrote:

ArnoHu wrote:

HasiLover wrote:

Try this Link:https://turbowarp.org/894019758?turbo,it will take around 20 seconds for a Move, turn on turbomode,you can move its pieces to set the Opening.

Quick and dirty remix, removing all those busy loops, that slowed down the engine: https://turbowarp.org/894119132 Also, turbo mode not necessary.
Wow,this is great.The Engine is way faster now!

Also runs fast on Scratch 3 now. When the engine is busy, only the engine should be active. No other code, and most importantly no forever-loops. Forever-loops are hardly ever necessary at all on Scratch, unless you want to send a recurring repaint-notification or similar.
HasiLover
Scratcher
100+ posts

Scratch Chess Engine - Game of Kings

ArnoHu wrote:

HasiLover wrote:

ArnoHu wrote:

HasiLover wrote:

Try this Link:https://turbowarp.org/894019758?turbo,it will take around 20 seconds for a Move, turn on turbomode,you can move its pieces to set the Opening.

Quick and dirty remix, removing all those busy loops, that slowed down the engine: https://turbowarp.org/894119132 Also, turbo mode not necessary.
Wow,this is great.The Engine is way faster now!

Also runs fast on Scratch 3 now. When the engine is busy, only the engine should be active. No other code, and most importantly no forever-loops. Forever-loops are hardly ever necessary at all on Scratch, unless you want to send a recurring repaint-notification or similar.
Thanks to your changes it Sped up quite alot,I will probably use this extra Speed for Inputs

Powered by DjangoBB