Add check_dimensions routine. Add import astropy.io.fits.