"tests/vscode:/vscode.git/clone" did not exist on "ab428207a79ca3920d8b83793eb61899899244f2"
Unverified Commit 76d3d72e authored by Lukasz Kaiser's avatar Lukasz Kaiser Committed by GitHub
Browse files

Merge pull request #4822 from buckman-google/master

Fixed minor bug in STEVE which sometimes prevented resuming experiments.
parents 2689c9ae c1da1ae5
...@@ -155,6 +155,7 @@ class Learner(object): ...@@ -155,6 +155,7 @@ class Learner(object):
self.resume_from_checkpoint(epoch) self.resume_from_checkpoint(epoch)
def _log(self): def _log(self):
if self.denom > 0:
logstring = "(%3.2f sec) h%-8.2f e%-8d s%-8d f%-8d\t" % (time.time() - self._log_time, self.hours, self.epoch, self.update_i + 1, self.total_frames) + ', '.join(["%8f" % x for x in (self.running_total / self.denom).tolist()]) logstring = "(%3.2f sec) h%-8.2f e%-8d s%-8d f%-8d\t" % (time.time() - self._log_time, self.hours, self.epoch, self.update_i + 1, self.total_frames) + ', '.join(["%8f" % x for x in (self.running_total / self.denom).tolist()])
print("%s\t%s" % (self.learner_name, logstring)) print("%s\t%s" % (self.learner_name, logstring))
with open(self.log_path, "a") as f: f.write(logstring + "\n") with open(self.log_path, "a") as f: f.write(logstring + "\n")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment