Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sudden Death - Improve TM #5112

Closed
wants to merge 1 commit into from

Conversation

TierynnB
Copy link
Contributor

@TierynnB TierynnB commented Mar 13, 2024

Due to the 50 estimated move horizon, once a sudden death game got below 1 second, the time allocation for optimumTime would go into the negative and SF would start instamoving.

to counter this, once limits.time is below 1 second, the move horizon will start decreasing, at a rate of 1 move per 20ms. This was just what seemed a reasonable rate of decay.

Fishtest sudden death TC 5+0
https://tests.stockfishchess.org/tests/live_elo/65ee2cdf0ec64f0526c43bbb
LLR: 2.99 (-2.94,2.94) <0.00,2.00>
Total: 3348 W: 1070 L: 727 D:1551
Ptnml(0-2): 46, 277, 738, 514, 99

Fishtest SD TC 10+0
https://tests.stockfishchess.org/tests/live_elo/65ee401e0ec64f0526c43cf7
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 3780 W: 1097 L: 808 D: 1875
Ptnml(0-2): 11, 353, 919, 550, 57

Neutral Non-Regression STC 10+0.1
https://tests.stockfishchess.org/tests/live_elo/65ee45ff0ec64f0526c43d68
LLR: 2.95 (-2.94,2.94) <-1.75, 0.25>
Total: 123616 W: 32054 L: 31927 D:59635
Ptnml(0-2): 493, 14323, 32105, 14338, 549

neutral Non-Regression LTC 60+0.6
https://tests.stockfishchess.org/tests/live_elo/65ef1eec0ec64f0526c44bc4
LLR: 2.95 (-2.94,2.94) <-1.75, 0.25>
Total: 130482 W: 32961 L: 32855 D:64666
Ptnml(0-2): 88, 13412, 38123, 13542, 76

@TierynnB
Copy link
Contributor Author

For reference, heres an example of how the optimum/maxtime were before and after this change at times below a second.

Base code Change Code
inc(ms) limit.time(ms) OptTime(ms) MaxTime(ms) OptTime(ms) MaxTime(ms)
0 1000 20 128 20 128
0 900 16 99 18 113
0 800 12 70 16 98
0 700 7 41 14 84
0 600 3 12 12 69
0 500 -9 0 10 54
0 400 -9 0 7 34
0 300 -9 0 5 21
0 200 -9 0 3 9
0 100 -9 0 1 -2

@Disservin
Copy link
Member

did we have patch on fishtest which scales the mtg accordingly ?

@FauziAkram
Copy link
Contributor

did we have patch on fishtest which scales the mtg accordingly ?

@Disservin yes, I tried something like that long time ago, let me find the links.

@TierynnB
Copy link
Contributor Author

I had tried something similar, just a linear curve from 50 to 30.
https://tests.stockfishchess.org/tests/view/65d5266e1d8e83c78bfdc4d4
https://tests.stockfishchess.org/tests/view/65d9d1af4c0e22b904f5752b

I think maybe from this change, increase the time it starts to degrade(and adjust the rate), and see if it has a positive impact.
Idk how big an impact it would have tbh.

@Disservin
Copy link
Member

https://tests.stockfishchess.org/tests/view/65286c5b3125598fc7ebaaaf https://tests.stockfishchess.org/tests/view/65295c533125598fc7ebbe3e

what are these tests :o
I was imagining something like @TierynnB later posted. Looks interesting and is perhaps the correct thing to do. I'll merge for sudden death, but it be nice to replace this in the future with a more general approach.

@Disservin Disservin closed this in 23493de Mar 14, 2024
@TierynnB TierynnB deleted the sd_better_mtg branch March 14, 2024 21:35
linrock pushed a commit to linrock/Stockfish that referenced this pull request Mar 27, 2024
Due to the 50 estimated move horizon, once a sudden death game got below
1 second, the time allocation for optimumTime would go into the negative
and SF would start instamoving.

To counter this, once limits.time is below 1 second, the move horizon
will start decreasing, at a rate of 1 move per 20ms. This was just what
seemed a reasonable rate of decay.

Fishtest sudden death TC 5+0
https://tests.stockfishchess.org/tests/live_elo/65ee2cdf0ec64f0526c43bbb
LLR: 2.99 (-2.94,2.94) <0.00,2.00>
Total: 3348 W: 1070 L: 727 D:1551
Ptnml(0-2): 46, 277, 738, 514, 99

Fishtest SD TC 10+0
https://tests.stockfishchess.org/tests/live_elo/65ee401e0ec64f0526c43cf7
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 3780 W: 1097 L: 808 D: 1875
Ptnml(0-2): 11, 353, 919, 550, 57

Neutral Non-Regression STC 10+0.1
https://tests.stockfishchess.org/tests/live_elo/65ee45ff0ec64f0526c43d68
LLR: 2.95 (-2.94,2.94) <-1.75, 0.25>
Total: 123616 W: 32054 L: 31927 D:59635
Ptnml(0-2): 493, 14323, 32105, 14338, 549

Neutral Non-Regression LTC 60+0.6
https://tests.stockfishchess.org/tests/live_elo/65ef1eec0ec64f0526c44bc4
LLR: 2.95 (-2.94,2.94) <-1.75, 0.25>
Total: 130482 W: 32961 L: 32855 D:64666
Ptnml(0-2): 88, 13412, 38123, 13542, 76

closes official-stockfish#5112

Bench: 2002517
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants