C2-W2- key errors in Exercises 4

Hello,

I am having errors in Exercises 4.

can you please help me?

Hi @Arif_Yetik, welcome to our community!

In this exercise you have to go through these instructions below inside train.py file. Please let me know if you did so…

  1. Open the file src/train.py. Go through the comments to understand its content.
  2. Find and review the configure_model() function, which contains the RoBERTa model configuration.
  3. Map the sentiment values in the dataset [-1, 0, 1] to a 0-indexed list of classes used by BERT, updating the function as follows:

config = RobertaConfig.from_pretrained( PRE_TRAINED_MODEL_NAME, num_labels=len(classes), id2label={ 0: -1, 1: 0, 2: 1, }, label2id={ -1: 0, 0: 1, 1: 2, } )

  1. Save the file src/train.py.

Hi @Raul, I am very happy to be part of community!

thanks for advise, It worked.