Skip to content

Setup Kaggle Environment #9

Description

@visuallization

Hi there,

I found your project on youtube and it is such a good explanation of the alpha zero algorithm. Thank you very much for that! :)
I was wondering if there is some example code how to setup the kaggle environment to play against the agent.

I know you do something like this:

from kaggle_environments import make

# Setup a tictactoe environment.
env = make("tictactoe")

# Basic agent which marks the first available cell.
def my_agent(obs):
  return [c for c in range(len(obs.board)) if obs.board[c] == 0][0]

# Run the basic agent against a default agent which chooses a "random" move.
env.run([my_agent, "random"])

# Render an html ipython replay of the tictactoe game.
env.render(mode="ipython")

But I am currently not 100% sure how to provide the trained connect2 agent, especially with the latest.pth file.

Cheers & thanks again,
Florentin

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions