I'm trying to predict next label in a pattern based on previous labels using recurrent neural network. In total I have 100 labels
Example of input pattern:
1) orange, apple, banana, lemon -> grape 2) apple, banana, pineapple, mango -> orange 3) lychee, orange, grapefruit, apple -> lemon
Although this is a bogus example but it explains the problem pretty well. My target variable is a member of the input sequence set.
What I want to do now is as there is no ordinal relation between my input pattern, I dont want to simply label encode the data as the model might implicitly learn from the ordinal nature of label encoding, so I want to go for one-hot encoding.
But I'm having a hard time understanding how to create input feature space for input of one hot encoding. Should I have pattern input as:
[1,0,0,0..,0],[0,1,0,0..,0],[0,0,1,0..0],[0,0,0,1..,0] or should it be just one matrix with 1 in place of all the labels present in the data and 0 where they aren't present something like