Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions Pinchemel/FlappyAgent.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@

import numpy as np
from keras.models import load_model

model = load_model("model_flappy_best_score.dqf")

def FlappyPolicy(state, screen):
qval = model.predict(np.array(list(state.values())).reshape(1,8), batch_size=1)

return 119 * (np.argmax(qval[0]))
File renamed without changes.
Binary file added Pinchemel/__pycache__/FlappyAgent.cpython-36.pyc
Binary file not shown.
Loading