SenticGCNBert confi...

Clear all

# Question SenticGCNBert config file

20 Posts
4 Users
2 Likes
133 Views
Posts: 7
Member
(@joeylim)
Active Member
Joined: 2 weeks ago

Thanks for assisting us still in trying to resolve this issue! I have copied the code from github and edited it as instructed above as shown in the picture but there is still an error. It keeps flagging that the config .json file is the .bin file thus saying that the config file is not a valid json file.

Hope to hear from you soon!! Thank you!!

AISG Staff
(@raymond_aisg)
Joined: 4 months ago

Eminent Member
Posts: 23

@joeylim Hi,

Sorry for the late reply. The reason for the error is that the input to the from_pretrained method should be the folder path and not the file itself, could you kindly try the following instead?



config = config_class.from_pretrained("C:\\Users\\user\\Desktop\\SGnlp test\\senticgcnbert")

model = model_class.from_pretrained("C:\\Users\\user\\Desktop\\SGnlp test\\senticgcnbert", config=config)

return model



Hope this helps.

Posts: 7
Member
(@joeylim)
Active Member
Joined: 2 weeks ago

I have changed it to the file path and it still shows an error of no such of directory. Attached is the output of the code too with the error. Is the last line "You should probably TRAIN this model on a down-stream task to be able to use it for predictions and inference." the expected output? If so how will I be able to train this model on a down-stream task?

I hope to hear from you soon on other suggestions still.

Thank you!

AISG Staff
(@raymond_aisg)
Joined: 4 months ago

Eminent Member
Posts: 23

@joeylim Hi,

To be honest, I am a little confused, based on your screenshot, it indicates that the model has at least successfully loaded from the directory despite the message. May I know which model weights are you loading for the screenshot above?

Because you were looking at the evaluation script from the beginning, I had wrongly assumed that you had already trained a model, thus looking to evaluate your trained model. Please note that the evaluation script does not output the inference but instead only prints a list of metrics relevant to the model.

Could you kindly share with me your use case for the SenticGCN model? Are you looking to perform batch inference? If yes, you do not need the evaluation script.

To train the SenticGCN model, you can refer to this short guide here,

Or the full documentation for more details,

Page 3 / 3
Share: