In what order are the classses in the output of model.predict (keras)?
Yes. When you train a model, you are tweaking the weights to try to make the predictions match the labels in the training data by minimising the loss, and so the model is trained on the exact order you provide your labels in. Essentially your model is making predictions each time as part of the forward propagation phase of the training, and model.predict() simply performs a forward pass in exactly the same manner, so it's the same order.
When i train a model from a csv dataframe, is the output from model.predict in the same order as the columns from the Y dataframe?