Yes.Thank you, Actually I finetuned a model via training with the trainer and evaluate on a test data. Now I wanted to load my model and use it on realdata world and as I said the model output the same class for my realdata. I was wondering if I wrote the code correctly. The preprocessing/training/evaluating/testing and saving best model work but when I tried to load the model for inference on new data. The model output same class for every sentence in my dataset even when I tried with the test_dataset I used to evaluate on. Could you help me, the model is supposed to be used by an app for professionnal usage.
best_model_from_training_testing = './checkpoint-900'
best_model= FlaubertForSequenceClassification.from_pretrained(best_model_from_training_testing, num_labels=3)
trainer = Trainer(best_model)
raw_pred, _, _ = trainer.predict(test_tokenized_dataset)         
predictedLabelOnCompanyData = np.argmax(raw_pred, axis=1)

run 1 : 1111111111111111111111111111
run2: 1111111111111111111111112222
run3: 333333333333333333333333

As you see the output keep changing  and is not fixed , I do not know How to solve it. Any idea could be helpful. Should I still use trainer for inference ?