datamllab / rlcard

Reinforcement Learning / AI Bots in Card (Poker) Games - Blackjack, Leduc, Texas, DouDizhu, Mahjong, UNO.
http://www.rlcard.org
MIT License
2.78k stars 615 forks source link

About Dou Dizhu game state #281

Open HJia42 opened 1 year ago

HJia42 commented 1 year ago

Hi I was reading up the RLCard page about Dou Dizhu and it mentioned an action state of 27472 or just 309 by combining reduncencies. I was wondering where self.state_shape = [[790], [901], [901]] came from?

daochenzha commented 1 year ago

@HJia42 790, 901, 901 are the state shapes, which means the landlord has 790 features, and the other two players have 901, 901 features. These features are the result of concatenating many card planes.

For example, for the landlord, the features are defined here https://github.com/datamllab/rlcard/blob/master/rlcard/envs/doudizhu.py#L50-L57

In total, there are 790 features.