> Failure during submission

Hello,

I'm trying to submit my results but I got the next error message:

Traceback (most recent call last):
File "/tmp/codalab/tmpt7H3AT/run/program/evaluate.py", line 50, in
scores = evalMultiClassTask(gold_file, submit_file)
File "/tmp/codalab/tmpt7H3AT/run/program/emoevales_evaluate.py", line 41, in evalMultiClassTask
GOLD_DATA[2] = GOLD_DATA.apply(lambda r: label2id[r['pred']], axis=1)
File "/opt/conda/lib/python2.7/site-packages/pandas/core/frame.py", line 3972, in apply
return self._apply_standard(f, axis, reduce=reduce)
File "/opt/conda/lib/python2.7/site-packages/pandas/core/frame.py", line 4064, in _apply_standard
results[i] = func(v)
File "/tmp/codalab/tmpt7H3AT/run/program/emoevales_evaluate.py", line 41, in
GOLD_DATA[2] = GOLD_DATA.apply(lambda r: label2id[r['pred']], axis=1)
KeyError: (nan, u'occurred at index 92')

Since the error traceback only mentions an error regarding the use of the GOLD_DATA dataframe, I don't know what I could be doing wrong so I'd highly appreciate any direction to correctly submit my results.

Kind regards,
Daniel

Posted by: daveni @ May 17, 2021, 6:46 p.m.

Please, check that you are providing answers for all entries in test file.

Kind regards.

Posted by: amontejo @ May 17, 2021, 7:30 p.m.

That was the problem, thanks for your quick reply!

Posted by: daveni @ May 18, 2021, 10:10 a.m.

Hi,

I had the same error,

Could you tell me how did you fix it?

Thanks

Posted by: JorgeFlores @ May 20, 2021, 11:58 a.m.

Hi Jorge,

You should have 1656 samples in the test set. I was using pandas to read the test dataset and it seems there are some quotes in the tweets, so you have to take care of this issue by setting the quoting parameter to None when reading the file.

I hope you find this helpful,
Daniel

Posted by: daveni @ May 20, 2021, 2:02 p.m.

Hi Daniel,

Thanks so much for your response, that was my problem, I only had 1625 predictions,

I'm going to fix it!

Again thanks,

Jorge Flores

Posted by: JorgeFlores @ May 20, 2021, 3:47 p.m.
Post in this thread