<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def create_from_fitsfile(cls, fitsfile):
 """ Read a fits file and use it to make a mapping """

        from fermipy.skymap import Map
        index_map = Map.create_from_fits(fitsfile)
        mult_map = Map.create_from_fits(fitsfile, hdu=1)
        ff = fits.open(fitsfile)
        hpx = HPX.create_from_hdu(ff[0])
        mapping_data = dict(ipixs=index_map.counts,
                            mult_val=mult_map.counts,
                            npix=mult_map.counts.shape)
        return cls(hpx, index_map.wcs, mapping_data)