werner-duvaud / muzero-general

MuZero
https://github.com/werner-duvaud/muzero-general/wiki/MuZero-Documentation
MIT License
2.5k stars 611 forks source link

Scrabble implementation - How to include Player's rack observation #167

Closed nicolasnijssen closed 2 years ago

nicolasnijssen commented 3 years ago

I'm working on an implementation of Scrabble.

The board state is represented by a matrix with shape 15×15×27 (26 letters +1 wildcard, value 0/1) and the rack state 7×27 (rack always contains 7 tiles, value 0/1). How can I include the player's rack into the observation ?

Because the board and rack observation have different dimensions, it's not possible to concatenate these and use the concatenation as the "game" observation . However I'm having difficulties with finding the correct way to use the player's rack observation in the network.

Where/How do I include the rack observation ? Is there any example present in the repository, that makes use of player's hand of cards/tiles ?

JohnPPP commented 3 years ago

Hi,

I think you might have two solutions;

Sharing that I did both solutions in an env. Even thought it was not very big array, I found almost no difference in training.

Hope it helps

ahainaut commented 2 years ago

Closing this since @JohnPPP proposed a solution. Feel free to re open for any other suggestions.