from local

This commit is contained in:
dohe0342 2022-12-10 13:45:02 +09:00
parent 7407084e91
commit b3d1fdde04
2 changed files with 3 additions and 0 deletions

View File

@ -1131,12 +1131,15 @@ def run(rank, world_size, args, wb=None):
if params.multi_optim:
logging.info("Using seperate optimizers over encoder, decoder ...")
enc_param = []
dec_names = []
dec_param = []
for n, p in model.named_parameters():
name = n.split('.')[1]
if name == 'encoder' and 'feature_extractor' not in n:
enc_param.append(p)
elif 'feature_extractor' not in n:
dec_names.append(n)
dec_param.append(p)
if wb is None: