Electron self-energy in quantum dots