[parser] support omegaconf (#7793)
This commit is contained in:
@@ -63,9 +63,6 @@ def run_dpo(
|
||||
else:
|
||||
ref_model = None
|
||||
|
||||
# Update arguments
|
||||
training_args.remove_unused_columns = False # important for multimodal and pairwise dataset
|
||||
|
||||
# Initialize our Trainer
|
||||
trainer = CustomDPOTrainer(
|
||||
model=model,
|
||||
|
||||
@@ -59,9 +59,6 @@ def run_kto(
|
||||
else:
|
||||
ref_model = create_ref_model(model_args, finetuning_args)
|
||||
|
||||
# Update arguments
|
||||
training_args.remove_unused_columns = False # important for multimodal and pairwise dataset
|
||||
|
||||
# Initialize our Trainer
|
||||
trainer = CustomKTOTrainer(
|
||||
model=model,
|
||||
|
||||
@@ -48,9 +48,6 @@ def run_rm(
|
||||
template=template, model=model, pad_to_multiple_of=8, **tokenizer_module
|
||||
)
|
||||
|
||||
# Update arguments
|
||||
training_args.remove_unused_columns = False # important for multimodal and pairwise dataset
|
||||
|
||||
# Initialize our Trainer
|
||||
trainer = PairwiseTrainer(
|
||||
model=model,
|
||||
|
||||
@@ -65,11 +65,6 @@ def run_sft(
|
||||
**tokenizer_module,
|
||||
)
|
||||
|
||||
# Override the decoding parameters of Seq2SeqTrainer
|
||||
training_args.generation_max_length = training_args.generation_max_length or data_args.cutoff_len
|
||||
training_args.generation_num_beams = data_args.eval_num_beams or training_args.generation_num_beams
|
||||
training_args.remove_unused_columns = False # important for multimodal dataset
|
||||
|
||||
# Metric utils
|
||||
metric_module = {}
|
||||
if training_args.predict_with_generate:
|
||||
|
||||
Reference in New Issue
Block a user