Skip to content
Snippets Groups Projects
Commit 4629ab87 authored by Matthias König's avatar Matthias König
Browse files

lstm hidden reset

parent 72a2932c
No related branches found
No related tags found
No related merge requests found
......@@ -132,6 +132,8 @@ class AttentionCamera(BaseCamera):
super(AttentionCamera, self).__init__(cam_path)
self.det_frame = None
self.agent = load_attention_agent(model_path, model)
if hasattr(self.agent, "reset"):
self.agent.reset()
def get_frame(self):
with self.frame_lock:
......
......@@ -140,6 +140,10 @@ class AttentionPolicyController(BasePolicyController):
def drive(self):
self.stop.value = False
if hasattr(self.agent, "reset"):
self.agent.reset()
self.cam.agent.reset()
alpha = 0.9
while True:
start = time.time()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment