mirror of
https://github.com/gryf/coach.git
synced 2025-12-17 19:20:19 +01:00
Simulating the act on the trainer. (#65)
* Remove the use of daemon threads for Redis subscribe. * Emulate act and observe on trainer side to update internal vars.
This commit is contained in:
committed by
Balaji Subramaniam
parent
fe6857eabd
commit
fde73ced13
@@ -31,7 +31,14 @@ def training_worker(graph_manager, checkpoint_dir):
|
||||
# evaluation offset
|
||||
eval_offset = 1
|
||||
|
||||
graph_manager.setup_memory_backend()
|
||||
|
||||
while(steps < graph_manager.improve_steps.num_steps):
|
||||
|
||||
graph_manager.phase = core_types.RunPhase.TRAIN
|
||||
graph_manager.fetch_from_worker(num_steps=graph_manager.agent_params.algorithm.num_consecutive_playing_steps.num_steps)
|
||||
graph_manager.phase = core_types.RunPhase.UNDEFINED
|
||||
|
||||
if graph_manager.should_train():
|
||||
steps += 1
|
||||
|
||||
|
||||
Reference in New Issue
Block a user