Does a model trained in keras (tensorflow backend) saves the weights with max accuracy and minimum losses or does it simply saves the weights from the last epoch? If it is the latter then how do I save the best weights?
The weights update by default, they do not get saved anywhere, they are just in the programs memory.
But you can choose to save the weights manually or define a callback to do so. You should checkout the ModelCheckpoint callback. It will give you the power to decide what criterion you want to save the weights on.