class Policy::QLearning

Defined in:

policy/q_learning.cr

Constructors

Class Method Summary

Instance Method Summary

Instance methods inherited from class Policy::Base

chosen_move(_board, _player, _moves) chosen_move, move_options(board) move_options, play(board, as_player) play, play_best(*args) play_best

Constructor Detail

def self.new #

[View source]

Class Method Detail

def self.policy #

[View source]

Instance Method Detail

def choose_exploiting_move(board, player, moves) #

[View source]
def choose_exploring_move(board, player, moves) #

[View source]
def discount : Float64 #

[View source]
def discount=(discount : Float64) #

[View source]
def explore_percent : Int32 #

[View source]
def explore_percent=(explore_percent : Int32) #

[View source]
def inspect #
Description copied from class Object

Returns an unambiguous and information-rich string representation of this object, typically intended for developers.

This method should usually not be overridden. It delegates to #inspect(IO) which can be overridden for custom implementations.

Also see #to_s.


[View source]
def learning_rate : Float64 #

[View source]
def learning_rate=(learning_rate : Float64) #

[View source]
def play(board, as_player) #

[View source]
def play_best(board, as_player) #

[View source]
def qsa : Qsa #

[View source]