[Computer-go] A cautionary tale about randomness, Part 2
tesujisoftware at gmail.com
Fri Sep 7 20:26:19 PDT 2012
On Sat, Sep 8, 2012 at 4:45 PM, Dave Dyer <ddyer at real-me.net> wrote:
>>Are there performance reasons that made you try anything different?
> That's the whole point. Ideally, if the position has 100 legal moves,
> generating 1 ought to be 100x faster than generating them all and
> throwing 99 of them away.
Only if all 100 legal moves are different from the legal moves in the
But note that I didn't say generate all legal moves. Instead I said to
generate all possible moves, which you only need to do once ever. The
legality test can come after the random selection. That obviously
leads to more tries than when you restrict selection from legal moves,
but that happens in your own case just as much.
More information about the Computer-go