Fixed the NaNs