model.predict() accuracy extremely low on training dataset
The problem with the way the prediction is done in the code found in the question is that the generator is shuffling the data (even though the shuffle=True is commented out, True is the default). Additionally, the batch_size in the code is set to 16. Setting batch_size = 1 produced the correct output for me, and the resulting accuracy increased to what I was expecting.
Oh, and don't use the same generator to test the predict function!
Hope this helps someone! :)