Electrical and optical properties of self-assembled quantum dots