Nanobit commited on
Commit
0e74b64
1 Parent(s): c0f50d9

Add eval_batch_size for evaluation

Browse files
Files changed (2) hide show
  1. README.md +1 -0
  2. src/axolotl/utils/trainer.py +1 -0
README.md CHANGED
@@ -85,6 +85,7 @@ output_dir: ./completed-model
85
  # training hyperparameters
86
  batch_size: 8
87
  micro_batch_size: 2
 
88
  num_epochs: 3
89
  warmup_steps: 100
90
  learning_rate: 0.00003
 
85
  # training hyperparameters
86
  batch_size: 8
87
  micro_batch_size: 2
88
+ eval_batch_size: 2
89
  num_epochs: 3
90
  warmup_steps: 100
91
  learning_rate: 0.00003
src/axolotl/utils/trainer.py CHANGED
@@ -47,6 +47,7 @@ def setup_trainer(cfg, train_dataset, eval_dataset, model, tokenizer):
47
 
48
  training_args = transformers.TrainingArguments(
49
  per_device_train_batch_size=cfg.micro_batch_size,
 
50
  gradient_accumulation_steps=cfg.gradient_accumulation_steps,
51
  num_train_epochs=cfg.num_epochs,
52
  learning_rate=cfg.learning_rate,
 
47
 
48
  training_args = transformers.TrainingArguments(
49
  per_device_train_batch_size=cfg.micro_batch_size,
50
+ per_device_eval_batch_size=cfg.eval_batch_size,
51
  gradient_accumulation_steps=cfg.gradient_accumulation_steps,
52
  num_train_epochs=cfg.num_epochs,
53
  learning_rate=cfg.learning_rate,