mirror of
https://github.com/wassname/TTS.git
synced 2026-10-21 12:01:01 +08:00
if reinit option is used run runtime rrror to partially iniot the model
This commit is contained in:
1 parent
6edd8bc6dd
commit
e1573440ba
1 file changed
+2
@@ -392,6 +392,8 @@ def main(args):
|
||||
# TODO: fix optimizer init, model.cuda() needs to be called before
|
||||
# optimizer restore
|
||||
# optimizer.load_state_dict(checkpoint['optimizer'])
|
||||
if len(c.reinit_layers) > 0:
|
||||
raise RuntimeError
|
||||
model.load_state_dict(checkpoint['model'])
|
||||
except:
|
||||
print(" > Partial model initialization.")
|
||||
|
||||
Reference in new issue
Block a user