raise IOError when the snapshot is not in a valid format
variations is now an iterator
compute chi2 between the fiducial and the observation