ENH: in case of an invalid header ensure that the output dataset is centered for world coordinates