Commit 36d73304 authored by Yuxin Wu's avatar Yuxin Wu

fix build

parent a36ad180
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
# Author: Yuxin Wu <ppwwyyxx@gmail.com> # Author: Yuxin Wu <ppwwyyxx@gmail.com>
import tensorflow as tf import tensorflow as tf
from datetime import datetime
import os import os
import shutil import shutil
import glob import glob
...@@ -71,9 +72,10 @@ class ModelSaver(Callback): ...@@ -71,9 +72,10 @@ class ModelSaver(Callback):
def _before_train(self): def _before_train(self):
# graph is finalized, OK to write it now. # graph is finalized, OK to write it now.
time = datetime.now().strftime('%m%d-%H%M%S')
self.saver.export_meta_graph( self.saver.export_meta_graph(
os.path.join(self.checkpoint_dir, os.path.join(self.checkpoint_dir,
'graph-{}.meta'.format(logger.get_time_str())), 'graph-{}.meta'.format(time)),
collection_list=self.graph.get_all_collection_keys()) collection_list=self.graph.get_all_collection_keys())
def _trigger(self): def _trigger(self):
......
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