Discuss Scratch
- Discussion Forums
- » Show and Tell
- » Scratch Chess Engine - Game of Kings
- ArnoHu
-
Scratcher
1000+ posts
Scratch Chess Engine - Game of Kings
Why are the cold start runs faster, shouldn't it be the other way around?
It never really speeds up, it's always like 30% faster after I toggle warp timer on/off.
OK, that's true, still it's the recompile that triggers the change. Optimizer can be wrong, or can disable optimizations for certain functions for one reason or another.
- waabooboo
-
Scratcher
500+ posts
Scratch Chess Engine - Game of Kings
Why are the cold start runs faster, shouldn't it be the other way around?
It never really speeds up, it's always like 30% faster after I toggle warp timer on/off.
OK, that's true, still it's the recompile that triggers the change. Optimizer can be wrong, or can disable optimizations for certain functions for one reason or another.
So I get a 30% speed boost by NOT having it optimized? Turbowarp must be “optimizing” one of my main functions in a way that's really counterproductive for there to be such a drop in performance…
Is it possible to prevent it from optimizing at runtime? If it's not possible, is it known what sorts of things get optimized poorly? Is it the kind of thing I can fix by changing my code's structure in some way?
- waabooboo
-
Scratcher
500+ posts
Scratch Chess Engine - Game of Kings
https://scratch.mit.edu/projects/1202302970/
Wolverine 3's official release. Some more small improvements have been made over the DCI version. Same interface as Wolverine 2, although I am in the process of designing a better UI
Wolverine 3's official release. Some more small improvements have been made over the DCI version. Same interface as Wolverine 2, although I am in the process of designing a better UI

- sprunkrLover1234
-
Scratcher
9 posts
Scratch Chess Engine - Game of Kings
How is your chess algorithm coming along? Just asking.
- ArnoHu
-
Scratcher
1000+ posts
Scratch Chess Engine - Game of Kings
https://scratch.mit.edu/projects/1202302970/
Wolverine 3's official release. Some more small improvements have been made over the DCI version. Same interface as Wolverine 2, although I am in the process of designing a better UI
Cool, congrats to this version, it is super dangerous!
Where are the DCI-enabled versions? Because I still have only those from a couple of weeks ago.
Last edited by ArnoHu (Sept. 25, 2026 02:58:14)
- ArnoHu
-
Scratcher
1000+ posts
Scratch Chess Engine - Game of Kings
How is your chess algorithm coming along? Just asking.
Thanks for asking, making progress, step by step.
- ArnoHu
-
Scratcher
1000+ posts
Scratch Chess Engine - Game of Kings
Scratch chess engines TurbowWarp test game series, broadcasted live on lichess:
https://lichess.org/broadcast/scratch-chess-engine-test-games-series/round-1/SLvxmTkh#players
Featuring Wolverine 3, Black Crow, GoK Classic, GoK NNUE (1sec), Delta 5 and Stockfish 12 (depth 10).
GoK NNUE - Stockfish 12: 61 - 39
GoK NNUE - Black Crow: 72.5 - 27.5
GoK Classic - Wolverine 3: 63 - 37
GoK Classic - White Dove: 75.5 - 24.5
Currently playing:
GoK NNUE - Wolverine 3 NNUE
Black Crow - Stockfish 12
https://lichess.org/broadcast/scratch-chess-engine-test-games-series/round-1/SLvxmTkh#players
Featuring Wolverine 3, Black Crow, GoK Classic, GoK NNUE (1sec), Delta 5 and Stockfish 12 (depth 10).
GoK NNUE - Stockfish 12: 61 - 39
GoK NNUE - Black Crow: 72.5 - 27.5
GoK Classic - Wolverine 3: 63 - 37
GoK Classic - White Dove: 75.5 - 24.5
Currently playing:
GoK NNUE - Wolverine 3 NNUE
Black Crow - Stockfish 12
Last edited by ArnoHu (Sept. 25, 2026 03:19:22)
- waabooboo
-
Scratcher
500+ posts
Scratch Chess Engine - Game of Kings
Scratch chess engines TurbowWarp test game series, broadcasted live on lichess:
https://lichess.org/broadcast/scratch-chess-engine-test-games-series/round-1/SLvxmTkh#players
Featuring Wolverine 3, Black Crow, GoK Classic, GoK NNUE (1sec), Delta 5 and Stockfish 12 (depth 10).
GoK NNUE - Stockfish 12: 61 - 39
GoK NNUE - Black Crow: 72.5 - 27.5
GoK Classic - Wolverine 3: 63 - 37
GoK Classic - White Dove: 75.5 - 24.5
Currently playing:
GoK NNUE - Wolverine 3 NNUE
Black Crow - Stockfish 12
https://limewire.com/d/dSiUz#DNR14ViCEd
Try this – this one uses a Smallbrain net (not the 3 MB, one that's much smaller but still larger than the Leorik net).
I am curious how this does against GoK NNUE, as well as against the current Wolverine NNUE that uses the Leorik net. (I can't get two Wolverines running in a DCI project due to variable conflicts, so I can't make direct comparisons – but I suspect the Smallbrain version is stronger even though it's about 3x slower.)
Last edited by waabooboo (Sept. 25, 2026 14:32:32)
- ArnoHu
-
Scratcher
1000+ posts
Scratch Chess Engine - Game of Kings
Scratch chess engines TurbowWarp test game series, broadcasted live on lichess:
https://lichess.org/broadcast/scratch-chess-engine-test-games-series/round-1/SLvxmTkh#players
Featuring Wolverine 3, Black Crow, GoK Classic, GoK NNUE (1sec), Delta 5 and Stockfish 12 (depth 10).
GoK NNUE - Stockfish 12: 61 - 39
GoK NNUE - Black Crow: 72.5 - 27.5
GoK Classic - Wolverine 3: 63 - 37
GoK Classic - White Dove: 75.5 - 24.5
Currently playing:
GoK NNUE - Wolverine 3 NNUE
Black Crow - Stockfish 12
https://limewire.com/d/dSiUz#DNR14ViCEd
Try this – this one uses a Smallbrain net (not the 3 MB, one that's much smaller but still larger than the Leorik net).
I am curious how this does against GoK NNUE, as well as against the current Wolverine NNUE that uses the Leorik net. (I can't get two Wolverines running in a DCI project due to variable conflicts, so I can't make direct comparisons – but I suspect the Smallbrain version is stronger even though it's about 3x slower.)
Couldn't download it.
- waabooboo
-
Scratcher
500+ posts
Scratch Chess Engine - Game of Kings
Scratch chess engines TurbowWarp test game series, broadcasted live on lichess:
https://lichess.org/broadcast/scratch-chess-engine-test-games-series/round-1/SLvxmTkh#players
Featuring Wolverine 3, Black Crow, GoK Classic, GoK NNUE (1sec), Delta 5 and Stockfish 12 (depth 10).
GoK NNUE - Stockfish 12: 61 - 39
GoK NNUE - Black Crow: 72.5 - 27.5
GoK Classic - Wolverine 3: 63 - 37
GoK Classic - White Dove: 75.5 - 24.5
Currently playing:
GoK NNUE - Wolverine 3 NNUE
Black Crow - Stockfish 12
https://limewire.com/d/dSiUz#DNR14ViCEd
Try this – this one uses a Smallbrain net (not the 3 MB, one that's much smaller but still larger than the Leorik net).
I am curious how this does against GoK NNUE, as well as against the current Wolverine NNUE that uses the Leorik net. (I can't get two Wolverines running in a DCI project due to variable conflicts, so I can't make direct comparisons – but I suspect the Smallbrain version is stronger even though it's about 3x slower.)
Couldn't download it.
Strange… Try this instead:
https://fileport.io/FyS9fGBQ7v7N
- waabooboo
-
Scratcher
500+ posts
Scratch Chess Engine - Game of Kings
https://scratch.mit.edu/projects/1202302970/
Wolverine 3's official release. Some more small improvements have been made over the DCI version. Same interface as Wolverine 2, although I am in the process of designing a better UI
Cool, congrats to this version, it is super dangerous!
Where are the DCI-enabled versions? Because I still have only those from a couple of weeks ago.
The DCI file I shared is the new version, only change is I swapped out the Leorik net for a Smallbrain one. Again I had some issues sharing it as a Scratch project, that's why I shared it as a file. The second link I sent will hopefully work…
And I figured out what causes the major slowdowns after a long, painful process, testing every possible thing. Turns out it's sprite costumes with numbers as names, for whatever reason that slows things down significantly…
- ArnoHu
-
Scratcher
1000+ posts
Scratch Chess Engine - Game of Kings
https://scratch.mit.edu/projects/1202302970/
Wolverine 3's official release. Some more small improvements have been made over the DCI version. Same interface as Wolverine 2, although I am in the process of designing a better UI
Cool, congrats to this version, it is super dangerous!
Where are the DCI-enabled versions? Because I still have only those from a couple of weeks ago.
The DCI file I shared is the new version, only change is I swapped out the Leorik net for a Smallbrain one. Again I had some issues sharing it as a Scratch project, that's why I shared it as a file. The second link I sent will hopefully work…
And I figured out what causes the major slowdowns after a long, painful process, testing every possible thing. Turns out it's sprite costumes with numbers as names, for whatever reason that slows things down significantly…
Great finding, I uncovered the same thing only a week ago, it's crazy!
Reason:
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L88-L99
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L150-L160
Why?
In Scratch, switch costume to (“1”) picks the costume named “1”, while switch costume to (1) picks costume number 1. Any stored value could later reach a switch-costume block. So when some costume or sound is named “1”, the compiler keeps every stored 1 as the string “1” to preserve that behaviour. Each later use in arithmetic or a comparison then needs a string-to-number conversion, and the compiler can't use its typed number code paths.
Without S3 backward-compatibility, engines would play a lot better.
Last edited by ArnoHu (Sept. 26, 2026 07:57:08)
#9674Yesterday 16:23:14
- waabooboo
-
Scratcher
500+ posts
Scratch Chess Engine - Game of Kings
https://scratch.mit.edu/projects/1202302970/
Wolverine 3's official release. Some more small improvements have been made over the DCI version. Same interface as Wolverine 2, although I am in the process of designing a better UI
Cool, congrats to this version, it is super dangerous!
Where are the DCI-enabled versions? Because I still have only those from a couple of weeks ago.
The DCI file I shared is the new version, only change is I swapped out the Leorik net for a Smallbrain one. Again I had some issues sharing it as a Scratch project, that's why I shared it as a file. The second link I sent will hopefully work…
And I figured out what causes the major slowdowns after a long, painful process, testing every possible thing. Turns out it's sprite costumes with numbers as names, for whatever reason that slows things down significantly…
Great finding, I uncovered the same thing only a week ago, it's crazy!
Reason:
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L88-L99
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L150-L160
Why?
In Scratch, switch costume to (“1”) picks the costume named “1”, while switch costume to (1) picks costume number 1. Any stored value could later reach a switch-costume block. So when some costume or sound is named “1”, the compiler keeps every stored 1 as the string “1” to preserve that behaviour. Each later use in arithmetic or a comparison then needs a string-to-number conversion, and the compiler can't use its typed number code paths.
Without S3 backward-compatibility, engines would play a lot better.
You should have told me, would have saved me some time… How does Wolverine with the Smallbrain net do, did you get a chance to test?
#9675Yesterday 17:18:24
- ArnoHu
-
Scratcher
1000+ posts
Scratch Chess Engine - Game of Kings
https://scratch.mit.edu/projects/1202302970/
Wolverine 3's official release. Some more small improvements have been made over the DCI version. Same interface as Wolverine 2, although I am in the process of designing a better UI
Cool, congrats to this version, it is super dangerous!
Where are the DCI-enabled versions? Because I still have only those from a couple of weeks ago.
The DCI file I shared is the new version, only change is I swapped out the Leorik net for a Smallbrain one. Again I had some issues sharing it as a Scratch project, that's why I shared it as a file. The second link I sent will hopefully work…
And I figured out what causes the major slowdowns after a long, painful process, testing every possible thing. Turns out it's sprite costumes with numbers as names, for whatever reason that slows things down significantly…
Great finding, I uncovered the same thing only a week ago, it's crazy!
Reason:
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L88-L99
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L150-L160
Why?
In Scratch, switch costume to (“1”) picks the costume named “1”, while switch costume to (1) picks costume number 1. Any stored value could later reach a switch-costume block. So when some costume or sound is named “1”, the compiler keeps every stored 1 as the string “1” to preserve that behaviour. Each later use in arithmetic or a comparison then needs a string-to-number conversion, and the compiler can't use its typed number code paths.
Without S3 backward-compatibility, engines would play a lot better.
You should have told me, would have saved me some time… How does Wolverine with the Smallbrain net do, did you get a chance to test?
Yeah I didn't know your costume names.
I played two quick rounds using Wolverine 3 NNUE-SB, 2.5 - 7.5 against GoK Classic, and 0 - 10 against GoK NNUE. I can export the games to lichess if you want.
Last edited by ArnoHu (Yesterday 17:18:58)
#9676Yesterday 18:12:40
- waabooboo
-
Scratcher
500+ posts
Scratch Chess Engine - Game of Kings
https://scratch.mit.edu/projects/1202302970/
Wolverine 3's official release. Some more small improvements have been made over the DCI version. Same interface as Wolverine 2, although I am in the process of designing a better UI
Cool, congrats to this version, it is super dangerous!
Where are the DCI-enabled versions? Because I still have only those from a couple of weeks ago.
The DCI file I shared is the new version, only change is I swapped out the Leorik net for a Smallbrain one. Again I had some issues sharing it as a Scratch project, that's why I shared it as a file. The second link I sent will hopefully work…
And I figured out what causes the major slowdowns after a long, painful process, testing every possible thing. Turns out it's sprite costumes with numbers as names, for whatever reason that slows things down significantly…
Great finding, I uncovered the same thing only a week ago, it's crazy!
Reason:
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L88-L99
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L150-L160
Why?
In Scratch, switch costume to (“1”) picks the costume named “1”, while switch costume to (1) picks costume number 1. Any stored value could later reach a switch-costume block. So when some costume or sound is named “1”, the compiler keeps every stored 1 as the string “1” to preserve that behaviour. Each later use in arithmetic or a comparison then needs a string-to-number conversion, and the compiler can't use its typed number code paths.
Without S3 backward-compatibility, engines would play a lot better.
You should have told me, would have saved me some time… How does Wolverine with the Smallbrain net do, did you get a chance to test?
Yeah I didn't know your costume names.
I played two quick rounds using Wolverine 3 NNUE-SB, 2.5 - 7.5 against GoK Classic, and 0 - 10 against GoK NNUE. I can export the games to lichess if you want.
GoK Classic beat it 7.5-2.5, really? I wonder if I didn't set the NNUE up right, or maybe it was Wolverine HCE playing again…
0-10 against GoK NNUE is a bit disappointing, although not shocking. But I would like to see the exported games, especially against Classic.
#9677Yesterday 18:20:42
- ArnoHu
-
Scratcher
1000+ posts
Scratch Chess Engine - Game of Kings
https://scratch.mit.edu/projects/1202302970/
Wolverine 3's official release. Some more small improvements have been made over the DCI version. Same interface as Wolverine 2, although I am in the process of designing a better UI
Cool, congrats to this version, it is super dangerous!
Where are the DCI-enabled versions? Because I still have only those from a couple of weeks ago.
The DCI file I shared is the new version, only change is I swapped out the Leorik net for a Smallbrain one. Again I had some issues sharing it as a Scratch project, that's why I shared it as a file. The second link I sent will hopefully work…
And I figured out what causes the major slowdowns after a long, painful process, testing every possible thing. Turns out it's sprite costumes with numbers as names, for whatever reason that slows things down significantly…
Great finding, I uncovered the same thing only a week ago, it's crazy!
Reason:
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L88-L99
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L150-L160
Why?
In Scratch, switch costume to (“1”) picks the costume named “1”, while switch costume to (1) picks costume number 1. Any stored value could later reach a switch-costume block. So when some costume or sound is named “1”, the compiler keeps every stored 1 as the string “1” to preserve that behaviour. Each later use in arithmetic or a comparison then needs a string-to-number conversion, and the compiler can't use its typed number code paths.
Without S3 backward-compatibility, engines would play a lot better.
You should have told me, would have saved me some time… How does Wolverine with the Smallbrain net do, did you get a chance to test?
Yeah I didn't know your costume names.
I played two quick rounds using Wolverine 3 NNUE-SB, 2.5 - 7.5 against GoK Classic, and 0 - 10 against GoK NNUE. I can export the games to lichess if you want.
GoK Classic beat it 7.5-2.5, really? I wonder if I didn't set the NNUE up right, or maybe it was Wolverine HCE playing again…
0-10 against GoK NNUE is a bit disappointing, although not shocking. But I would like to see the exported games, especially against Classic.
What I can say is that the main Wolverine 3 NNUE clearly plays better. It won 6 - 4 against GoK Classic.
Last edited by ArnoHu (Yesterday 18:23:41)
#9678Yesterday 19:58:13
- waabooboo
-
Scratcher
500+ posts
Scratch Chess Engine - Game of Kings
https://scratch.mit.edu/projects/1202302970/
Wolverine 3's official release. Some more small improvements have been made over the DCI version. Same interface as Wolverine 2, although I am in the process of designing a better UI
Cool, congrats to this version, it is super dangerous!
Where are the DCI-enabled versions? Because I still have only those from a couple of weeks ago.
The DCI file I shared is the new version, only change is I swapped out the Leorik net for a Smallbrain one. Again I had some issues sharing it as a Scratch project, that's why I shared it as a file. The second link I sent will hopefully work…
And I figured out what causes the major slowdowns after a long, painful process, testing every possible thing. Turns out it's sprite costumes with numbers as names, for whatever reason that slows things down significantly…
Great finding, I uncovered the same thing only a week ago, it's crazy!
Reason:
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L88-L99
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L150-L160
Why?
In Scratch, switch costume to (“1”) picks the costume named “1”, while switch costume to (1) picks costume number 1. Any stored value could later reach a switch-costume block. So when some costume or sound is named “1”, the compiler keeps every stored 1 as the string “1” to preserve that behaviour. Each later use in arithmetic or a comparison then needs a string-to-number conversion, and the compiler can't use its typed number code paths.
Without S3 backward-compatibility, engines would play a lot better.
You should have told me, would have saved me some time… How does Wolverine with the Smallbrain net do, did you get a chance to test?
Yeah I didn't know your costume names.
I played two quick rounds using Wolverine 3 NNUE-SB, 2.5 - 7.5 against GoK Classic, and 0 - 10 against GoK NNUE. I can export the games to lichess if you want.
GoK Classic beat it 7.5-2.5, really? I wonder if I didn't set the NNUE up right, or maybe it was Wolverine HCE playing again…
0-10 against GoK NNUE is a bit disappointing, although not shocking. But I would like to see the exported games, especially against Classic.
What I can say is that the main Wolverine 3 NNUE clearly plays better. It won 6 - 4 against GoK Classic.
Yeah that's fine, but I still want to try to diagnose the issue with the Smallbrain net – it really should be stronger than the Leorik one.
There is a larger Leorik net I can try as well, with 256-wide accumulators instead of 128. But I don't think we're seeing the full potential of the Smallbrain net, I'd like to figure that out first…
#9679Yesterday 21:16:10
- ArnoHu
-
Scratcher
1000+ posts
Scratch Chess Engine - Game of Kings
https://scratch.mit.edu/projects/1202302970/
Wolverine 3's official release. Some more small improvements have been made over the DCI version. Same interface as Wolverine 2, although I am in the process of designing a better UI
Cool, congrats to this version, it is super dangerous!
Where are the DCI-enabled versions? Because I still have only those from a couple of weeks ago.
The DCI file I shared is the new version, only change is I swapped out the Leorik net for a Smallbrain one. Again I had some issues sharing it as a Scratch project, that's why I shared it as a file. The second link I sent will hopefully work…
And I figured out what causes the major slowdowns after a long, painful process, testing every possible thing. Turns out it's sprite costumes with numbers as names, for whatever reason that slows things down significantly…
Great finding, I uncovered the same thing only a week ago, it's crazy!
Reason:
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L88-L99
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L150-L160
Why?
In Scratch, switch costume to (“1”) picks the costume named “1”, while switch costume to (1) picks costume number 1. Any stored value could later reach a switch-costume block. So when some costume or sound is named “1”, the compiler keeps every stored 1 as the string “1” to preserve that behaviour. Each later use in arithmetic or a comparison then needs a string-to-number conversion, and the compiler can't use its typed number code paths.
Without S3 backward-compatibility, engines would play a lot better.
You should have told me, would have saved me some time… How does Wolverine with the Smallbrain net do, did you get a chance to test?
Yeah I didn't know your costume names.
I played two quick rounds using Wolverine 3 NNUE-SB, 2.5 - 7.5 against GoK Classic, and 0 - 10 against GoK NNUE. I can export the games to lichess if you want.
GoK Classic beat it 7.5-2.5, really? I wonder if I didn't set the NNUE up right, or maybe it was Wolverine HCE playing again…
0-10 against GoK NNUE is a bit disappointing, although not shocking. But I would like to see the exported games, especially against Classic.
What I can say is that the main Wolverine 3 NNUE clearly plays better. It won 6 - 4 against GoK Classic.
Yeah that's fine, but I still want to try to diagnose the issue with the Smallbrain net – it really should be stronger than the Leorik one.
There is a larger Leorik net I can try as well, with 256-wide accumulators instead of 128. But I don't think we're seeing the full potential of the Smallbrain net, I'd like to figure that out first…
I can run a JS profiler later and find out where the hotspot is.
Interestingly with 2sec think time GoK Classic does better against Wolverine 3 NNUE, 14 - 13 right now.
#9680Yesterday 21:45:07
- waabooboo
-
Scratcher
500+ posts
Scratch Chess Engine - Game of Kings
https://scratch.mit.edu/projects/1202302970/
Wolverine 3's official release. Some more small improvements have been made over the DCI version. Same interface as Wolverine 2, although I am in the process of designing a better UI
Cool, congrats to this version, it is super dangerous!
Where are the DCI-enabled versions? Because I still have only those from a couple of weeks ago.
The DCI file I shared is the new version, only change is I swapped out the Leorik net for a Smallbrain one. Again I had some issues sharing it as a Scratch project, that's why I shared it as a file. The second link I sent will hopefully work…
And I figured out what causes the major slowdowns after a long, painful process, testing every possible thing. Turns out it's sprite costumes with numbers as names, for whatever reason that slows things down significantly…
Great finding, I uncovered the same thing only a week ago, it's crazy!
Reason:
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L88-L99
https://github.com/TurboWarp/scratch-vm/blob/c4823421cb7c17d8d8a89878851ce1668c26a21f/src/compiler/irgen.js#L150-L160
Why?
In Scratch, switch costume to (“1”) picks the costume named “1”, while switch costume to (1) picks costume number 1. Any stored value could later reach a switch-costume block. So when some costume or sound is named “1”, the compiler keeps every stored 1 as the string “1” to preserve that behaviour. Each later use in arithmetic or a comparison then needs a string-to-number conversion, and the compiler can't use its typed number code paths.
Without S3 backward-compatibility, engines would play a lot better.
You should have told me, would have saved me some time… How does Wolverine with the Smallbrain net do, did you get a chance to test?
Yeah I didn't know your costume names.
I played two quick rounds using Wolverine 3 NNUE-SB, 2.5 - 7.5 against GoK Classic, and 0 - 10 against GoK NNUE. I can export the games to lichess if you want.
GoK Classic beat it 7.5-2.5, really? I wonder if I didn't set the NNUE up right, or maybe it was Wolverine HCE playing again…
0-10 against GoK NNUE is a bit disappointing, although not shocking. But I would like to see the exported games, especially against Classic.
What I can say is that the main Wolverine 3 NNUE clearly plays better. It won 6 - 4 against GoK Classic.
Yeah that's fine, but I still want to try to diagnose the issue with the Smallbrain net – it really should be stronger than the Leorik one.
There is a larger Leorik net I can try as well, with 256-wide accumulators instead of 128. But I don't think we're seeing the full potential of the Smallbrain net, I'd like to figure that out first…
I can run a JS profiler later and find out where the hotspot is.
Interestingly with 2sec think time GoK Classic does better against Wolverine 3 NNUE, 14 - 13 right now.
That's the Leorik net or Smallbrain?
I tried Wolverine with Smallbrain net vs GoK NNUE myself, 1 sec games, was 3.5-6.5 (+1 =4 -5). Haven't tried Classic yet, but if it can score 35% against GoK NNUE I would expect a match against Classic to be a blowout. It could be another export issue, did you check Wolverine's NPS? It should be like 80k with the Smallbrain NNUE. If it's actually Wolverine HCE playing, then it'll be like 300k. Could also be a corruption issue, hard to say without seeing the games.
- Discussion Forums
- » Show and Tell
-
» Scratch Chess Engine - Game of Kings