Hi,
To fine-tune a MarianMT (or any other seq2seq model in the library), you don’t need to feed the source and target sentences at once to the tokenizer. Instead, they should be tokenized separately:
from transformers import MarianTokenizer

tokenizer =  MarianTokenizer.from_pretrained(“Helsinki-NLP/opus-mt-en-de”)

input_ids = tokenizer(“I am stuck with text_pair argument of Tokenizer.”, return_tensors="pt").input_ids
labels = tokenizer(“Ich stecke mit text_pair Argument von Tokenizer fest.”, return_tensors="pt").input_ids

You can then train as follows:
outputs = model(input_ids=input_ids, labels=labels)
loss = outputs.loss

This is because we feed the encoder of the seq2seq model only the encoded input sentence (as input_ids). The decoder’s output will then be compared against the labels to compute the loss.
The text_pair use case is only when we would provide sentence A [SEP] sentence B to a model, which is done for example when using BERT to classify the relationship between 2 sentences, or for question answering, where we feed question [SEP] context to the model.