Tony wrote:Dann Corbit wrote:
As to whether it is like Fruit and/or Toga -- again be your own judge.
In this case, the eval is the same and the search is different.
Are you serious ???
I had a look at the Sloppy sourcecode and if you don't see that it's a Fruit rewrite by putting stuff into multiple static functions where they were in one function then you must have seen different code.
Stuff like
Code: Select all
static bool
null_move_pruning(Chess *chess, int beta, int *depth, bool in_pv)
static U32
iid(Chess *chess, int alpha, int beta, int depth)
static int
mate_distance_pruning(Board *board, int *alpha, int *beta, int ply)
Do exactly the same as in Fruit, only the latter has them in Search() There is nothing new, only the Can_Win function comes from Crafty, not Fruit.
If you didn't see that, than your claims about wether a program looks like another program are worth zero.
Tony
I also use negamax search with beta cutoffs. Pretty Fruity, huh?
You are aware that Fabien didn't invent null move pruning and IID (not sure about mate distance pruning), right?
Let's see. First Sloppy's null move pruning:
When to NOT null move:
- when in pv: very common, not a Fruit feature
- previous move was a null move: very common, not a Fruit feature
- when in check: again, not a Fruit feature, just common sense
- depth <= 2: after a lot of testing, this value worked best. Nothing to do with Fruit.
- beta is a mate score: just common sense
- material <= VAL_KNIGHT: definitely not from Fruit
- eval < beta: again, common sense
The rest of the null move pruning is pretty much a textbook example of null-move pruning. Nothing that Fruit should get exclusive credit for.
Sloppy's internal iterative deepening (used for getting a "best move" to try first):
Code: Select all
val = search(chess, alpha, beta, depth, true, NULL);
if (val <= alpha)
val = search(chess, -VAL_INF, beta, depth, true, NULL);
Wow, no way anyone but Fabien could have thought of this! As for deciding when to do IID and how many plies to reduce, that was tweaked after sufficient testing.
As I said earlier in this discussion, the mate distance pruning is from Fruit. But then again, it has pretty much zero effect on playing style or strength.
And can_win() is from Crafty? Yeah, crafty has an integer called "can_win" somewhere in the evaluation. Sloppy has a boolean function called "can_win" in the search. And that's where the similarities end. I also have a variable called alpha. Better change that before someone notices.
The most Fruity part of Sloppy's search that actually affects the playing style and strength is futility pruning. But then again, it's futility pruning at its simplest, and a very widely used feature even by those who haven't seen Fruit's source code.