create_background_3d_hdu
- pyirf.io.create_background_3d_hdu(background_3d, reco_energy_bins, fov_lon_bins, fov_lat_bins, alignment='ALTAZ', extname='BACKGROUND', **header_cards)[source]
Create a fits binary table HDU in GADF format for the background 3d table. Assumes ALTAZ coordinates. See the specification at https://gamma-astro-data-formats.readthedocs.io/en/latest/irfs/full_enclosure/bkg/index.html#bkg-2d
- Parameters:
- background_3d: astropy.units.Quantity[(MeV s sr)^-1]
Background rate, must have shape (n_energy_bins, n_fov_offset_bins, n_fov_offset_bins)
- reco_energy_bins: astropy.units.Quantity[energy]
Bin edges in reconstructed energy
- fov_lon_bins: astropy.units.Quantity[angle]
Bin edges in the field of view system, becomes the DETX values
- fov_lat_bins: astropy.units.Quantity[angle]
Bin edges in the field of view system, becomes the DETY values
- alignment: str
Whether the FOV coordinates are aligned with the ALTAZ or RADEC system, more details at https://gamma-astro-data-formats.readthedocs.io/en/latest/general/coordinates.html
- extname: str
Name for BinTableHDU
- **header_cards
Additional metadata to add to the header, use this to set e.g. TELESCOP or INSTRUME.