after fine tune the pytorch llm(IDEFICS9b) on the data set the train results is not showing val loss how to collect it and then plot it with training loss?
training_args = TrainingArguments(
output_dir=f"{model_name}-vqa1",
learning_rate=3e-5,
fp16=True,
per_device_train_batch_size=16,
per_device_eval_batch_size=16,
gradient_accumulation_steps=1,
dataloader_pin_memory=False,
save_total_limit=3,
evaluation_strategy="steps",
save_strategy="steps",
save_steps=10,
eval_steps=10,
logging_steps=10,
max_steps=1000,
remove_unused_columns=False,
push_to_hub=False,
label_names=["labels"],
load_best_model_at_end=True,
report_to=None,
optim="paged_adamw_8bit",
)
trainer = Trainer(
model=model,
args=training_args,
train_dataset=train_ds,
eval_dataset=eval_ds,
)
train_results = trainer.train()
the train results is as follows:
TrainOutput(global_step=10, training_loss=2.2117252349853516, metrics={'train_runtime': 15.7995, 'train_samples_per_second': 10.127, 'train_steps_per_second': 0.633, 'total_flos': 470670709819392.0, 'train_loss': 2.2117252349853516, 'epoch': 0.02})