AFAIK transformers hum because alternating magnetic field causes pieces of laminated core to slightly deform and vibrate and that is simply a byprocess of how transformers work. However for the same model, the same power load and the same age some transformers hum more than others. The latter is sometimes claimed to coils being winded slightly less tightly so that over the transformer lifetime it first vibrates less and that vibration causes coils to stretch a little bit and allow for more vibration. Another scenario is when a transformer ages and laminated pieces slightly grind the thin insulation between themselves.
I'd guess that increased vibration should require some power to work and that would decrease transformer efficiency.
Does transformer humming cause any notable waste of energy?