2
$\begingroup$

I have a many to one LSTM model for multiclass classification. For reference, this is the architecture of the model

    model.add(LSTM(147, input_shape=(1000, 147)))
    model.add(Dense(5, activation='softmax'))
    model.compile(loss='categorical_crossentropy',
                  optimizer='rmsprop',
                  metrics=['accuracy'])

The model is trained in 5 types of sequences is able to effectively classify each sequence I feed into the model with high accuracy. Now my new objective is to combine these sequences together to form a new sequence.
For e.g
I denote the elements from the class '1' with the sequence:
[1,1,1,1,1,1,1]
So when I input the above sequence into the LSTM model for prediction, it classifies the sequence as class '1' with accuracy of 0.99

And I denote the elements from class '2' with the sequence:
[2,2,2]
LIkewise for the above sequence, the LSTM model will classify the sequence as class '2' with accuracy of 0.99

Now I combine these sequences together and feed it into the model :
New sequence : [1,1,1,1,1,1,1,2,2,2]
However the model does not seem to be sensitive to the presence of the class '2' sequence and still classifies the sequence as class '1' with accuracy of 0.99.

How do I make the model more "sensitive", meaning that I would expect the LSTM model to still maybe predict class '1' but with a drop in accuracy? Or is the LSTM incapable of detecting the inclusion of class '2' sequences?

Thanks.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.