brain

package
v0.0.0-...-4fb7718 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 3, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ShuffleMoves

func ShuffleMoves(moves []g.SnakeMove) []g.SnakeMove

Types

type Heuristics

type Heuristics map[g.SnakeId]float64

type MASTTable

type MASTTable struct {
	// contains filtered or unexported fields
}

type MCTSConfig

type MCTSConfig struct {
	ExplorationConstant float64
	AlphaConstant       float64
	VoronoiWeighting    float64
	FoodWeightA         float64
	FoodWeightB         float64
	BigSnakeReward      float64
}

type MctsGame

type MctsGame struct {
	// contains filtered or unexported fields
}

func CreateMctsGame

func CreateMctsGame(h, w int) MctsGame

func (*MctsGame) MCTS

func (mc *MctsGame) MCTS(board *g.FastBoard, config *MCTSConfig, txn *newrelic.Transaction) g.SnakeMove

type Node

type Node struct {
	// contains filtered or unexported fields
}

func ShuffleNodes

func ShuffleNodes(nodes []*Node) []*Node

type Payoff

type Payoff struct {
	// contains filtered or unexported fields
}

type Rewards

type Rewards map[g.SnakeId]SnakeScore

type SnakeScore

type SnakeScore struct {
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL