Interplay between local structure, vibrational and electronic properties on CuO under pressure