Hello!
In your code for the emotion detection task (link: https://github.com/sismetanin/emosense-semeval2019-task3-emocontext/blob/master/EmoSense%20at%20SemEval2019%20Task%203%20EmoContext.ipynb)
Did you encounter this error:
OSError: Unable to open file (unable to open file: name = 'models/bidirectional_LSTM_best_weights_0010-0.9125.hdf5', errno = 2, error message = No such file or directory', flags = 0, o_flags = 0)
While running this line [29]:
model.load_weights("models/bidirectional_LSTM_best_weights_0010-0.9125.hdf5")
I've tried !pip install h5py
and import h5py
but neither helped.
Although I'm getting this error, it doesn't stop the classification report from being created, However, the report I'm getting is entirely different from what you have (see below). I suspect the differences in our reports are due to the above OSError.
f1_e 0.0
precision_e 0.0
recoll_e 0.0
precision recall f1-score support
0 0.85 1.00 0.92 2338
1 0.00 0.00 0.00 142
2 0.00 0.00 0.00 125
3 0.00 0.00 0.00 150
accuracy 0.85 2755
macro avg 0.21 0.25 0.23 2755
weighted avg 0.72 0.85 0.78 2755
UndefinedMetricWarning: Precision and F-score are ill-defined and being set to 0.0 in labels with no predicted samples. Use
zero_division parameter to control this behavior.
To solve this, I tried setting zero_division=0
or 1 and neither helped.
Please help if you can! Thanks :)