Skip to content

Commit

Permalink
Update learning rate for #116 and other small error
Browse files Browse the repository at this point in the history
  • Loading branch information
johnml1135 committed Aug 29, 2024
1 parent 368120f commit af0194c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion machine/jobs/nmt_engine_build_job.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def _train_model(
) as model_trainer:
model_trainer.train(progress=phase_progress, check_canceled=check_canceled)
model_trainer.save()
train_corpus_size = model_trainer.stats.train_corpus_size
train_corpus_size = parallel_corpus.count()
return train_corpus_size, float("nan")

def _batch_inference(
Expand Down
6 changes: 4 additions & 2 deletions machine/jobs/settings.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,17 @@ default:
train_params:
do_train: true
optim: adamw_torch
warmup_steps: 4000
warmup_steps: 1000
per_device_train_batch_size: 16
gradient_accumulation_steps: 4
label_smoothing_factor: 0.2
group_by_length: true
gradient_checkpointing: true
lr_scheduler_type: cosine
learning_rate: 0.0002
fp16: true
save_strategy: no
max_steps: 20000
max_steps: 5000
generate_params:
device: 0
num_beams: 2
Expand Down

0 comments on commit af0194c

Please sign in to comment.