Probing structural and electronic dynamics with ultrafast electron microscopy