Visualizing energy-relevant phase transitions within individual palladium hydride nanoparticles