code: def create_from_fitsfile(cls, fitsfile):
          
          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)
docs: Read a fits file and use it to make a mapping