rlcard.agents.human_agents.gin_rummy_human_agent

Subpackages

rlcard.agents.human_agents.gin_rummy_human_agent.gin_rummy_human_agent

Project: Gui Gin Rummy File name: gin_rummy_human_agent.py Author: William Hale Date created: 3/14/2020

class rlcard.agents.human_agents.gin_rummy_human_agent.gin_rummy_human_agent.HumanAgent(num_actions)

Bases: object

A human agent for Gin Rummy. It can be used to play against trained models.

eval_step(state)

Predict the action given the current state for evaluation. The same to step here.

Parameters

state (numpy.array) – an numpy array that represents the current state

Returns

the action predicted (randomly chosen) by the random agent

Return type

action (int)

step(state)

Human agent will display the state and make decisions through interfaces

Parameters

state (dict) – A dictionary that represents the current state

Returns

The action decided by human

Return type

action (int)