Pass the training arguments to [Trainer] along with the model, dataset, processor, and data collator.

from transformers import Trainer
trainer = Trainer(
     model=model,
     args=training_args,
     data_collator=data_collator,
     train_dataset=processed_dataset,
     tokenizer=processor,
 )

Call [~Trainer.train] to finetune your model.

trainer.train() 

Once training is completed, share your model to the Hub with the [~Trainer.push_to_hub] method to share your final model on the 🤗 Hub: