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

Tempo #11

Open
thomasahle opened this issue Mar 7, 2014 · 8 comments
Open

Tempo #11

thomasahle opened this issue Mar 7, 2014 · 8 comments

Comments

@thomasahle
Copy link
Owner

Sunfish currently doesn't do 'tempo'. A mate in 6 is considered the same as a mate in 1.

@Ravenslofty
Copy link

I have this solved in my master. d6bb441

@thomasahle
Copy link
Owner Author

Interesting. Isn't it normally implemented by always subtracting a bit from the score returned in minmax?

@Ravenslofty
Copy link

Nope. If you always do that then you introduce a bug where a bad move searched shallowly is favoured over a good move searched deeply.

Matthew:out

@thomasahle
Copy link
Owner Author

But it doesn't have to be a big constant.
Otherwise, don't you have to do a lot of 'correcting' in the TT code, like
the describe on http://chessprogramming.wikispaces.com/Checkmate ?
Another approach I've thought about is to keep the global movenumber in the
Position representation. Then we could make MATE_SCORE-global_ply the value
of a checkmate. This might give new problems in TT though.

2014-03-13 18:16 GMT+01:00 ZirconiumX [email protected]:

Nope. If you always do that then you introduce a bug where a bad move
searched shallowly is favoured over a good move searched deeply.

Matthew:out


Reply to this email directly or view it on GitHubhttps://github.com//issues/11#issuecomment-37559774
.

Mvh. Thomas

@Ravenslofty
Copy link

Search deep enough and even 1 centipawn can make a difference.

It's better to have to deal with mate scores in the TT than having to deal with false mate scores in the TT.

Matthew:out

@thomasahle
Copy link
Owner Author

Have you tried testing the engines against each other and compared results?

@Recursing
Copy link
Contributor

A mate in 6 is considered the same as a mate in 1.

I "solve" this in my rust engine by exiting the search early on mate found, which while not correct 100% of the time is a good approximation, makes the engine appear faster and can very easily be done by making _search yield the score

@thomasahle
Copy link
Owner Author

I like the way this is done in Micromax: https://home.hccnet.nl/h.g.muller/delay.html

But I haven't found a position where it matters in the current sunfish, so I can't really test whether it improves anything.

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

No branches or pull requests

3 participants