(example)
| 213 | return model_inputs |
| 214 | |
| 215 | def print_dataset_example(example): |
| 216 | print("input_ids", example["input_ids"]) |
| 217 | print("inputs", tokenizer.decode(example["input_ids"])) |
| 218 | print("label_ids", example["labels"]) |
| 219 | print("labels", tokenizer.decode(example["labels"])) |
| 220 | |
| 221 | if training_args.do_train: |
| 222 | if "train" not in raw_datasets: |