mirror of
https://github.com/iperov/DeepFaceLab.git
synced 2025-07-16 10:03:41 -07:00
added sumbmodules
This commit is contained in:
parent
69f381dfa1
commit
e8394a86e7
2 changed files with 26 additions and 15 deletions
|
@ -85,6 +85,12 @@ def trainerThread (s2c, c2s, e,
|
|||
if model.get_target_iter() != 0:
|
||||
if is_reached_goal:
|
||||
io.log_info('Model already trained to target iteration. You can use preview.')
|
||||
if os.path.exists(answer_filename):
|
||||
with open(answer_filename, 'rb') as file:
|
||||
parameters = pickle.load(file)
|
||||
if parameters['NoInteractiveMode']:
|
||||
model_save()
|
||||
os._exit(0)
|
||||
else:
|
||||
io.log_info('Starting. Target iteration: %d. Press "Enter" to stop training and save model.' % ( model.get_target_iter() ) )
|
||||
else:
|
||||
|
@ -164,6 +170,12 @@ def trainerThread (s2c, c2s, e,
|
|||
model_save()
|
||||
is_reached_goal = True
|
||||
io.log_info ('You can use preview now.')
|
||||
if os.path.exists(answer_filename):
|
||||
with open(answer_filename, 'rb') as file:
|
||||
parameters = pickle.load(file)
|
||||
if parameters['NoInteractiveMode']:
|
||||
model_save()
|
||||
os._exit(0)
|
||||
need_save = False
|
||||
while time.time() - last_save_time >= save_interval_min*60:
|
||||
last_save_time += save_interval_min*60
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue