Transportation and the generation of electricity accounted for most of the emissions that contribute to climate change in 2017.