I have stopped reading when I noticed you have an inconsistency in the naming of the first paramter of your LSTMNet consturcto input_dim, and your initialization of that parameter, which is seq_length.  I think it would be good to fix such inconsistencies, keep everything tidy.