Hi. I created a Sequence Classifier but it is only returning True Positive of B-O class. I have total of 4 classes. There is a class imbalance as B-O is almost 80-90% of the dataset but my professor told me it should not give 0’s for other classes.
The structure of my project is
word2vec for vectorization
seqeval for compute_metrics
RNN from PyTorch
class RNN(nn.Module)
SGD optimizer with lr = 1e-3
This is the result of my epoch
Train Loss: 0.555 | Train Overall Precision: 82.43% | Train Overall Recall: 89.58% | Train Overall F1: 0.86 | Train Overall Accuracy: 82.43%
Valid Loss: 0.499 | Valid Overall Precision: 85.22% | Valid Overall Recall: 91.12% | Valid Overall F1: 0.88 | Valid Overall Accuracy: 85.22%
I have tried changing learning rates, hidden-layers and basically everything. I even tried the same with LSTM and it was only detecting B-O. Could you potentially tell where the problem can be?
Please help. I will share the relevant code but if you could tell me which part to share
@ptrblck