Spatially resolved measurements of the magnetocaloric effect and the local magnetic field using thermography