Skip to content
Snippets Groups Projects
Commit c9c10514 authored by Alfonso's avatar Alfonso
Browse files

prima versione rmf

parent 66c74b6c
No related branches found
No related tags found
No related merge requests found
Showing
with 21 additions and 0 deletions
SCRIVI UN READ ME GIGANTE CHE SPIEGA IL TUO CODICE
RISCHI DI NON RICORDARE UN CAZZO DEGLI SCRIPT CHE CREI
#printa tutte le info di un file fits
#sostituisci il path del file .fits
from astropy.io import fits
# Percorso del file FITS
file_path = '/home/alfonso/Scrivania/THESEUS/XGIS-X_0deg_reqEOL_v8.rmf'
# Apri il file FITS
with fits.open(file_path) as hdul:
# Stampa un sommario delle HDU nel file
hdul.info()
# Itera su tutte le HDU e stampa l'header e i dati
for hdu in hdul:
print(f"\nHeader HDU {hdul.index(hdu)}:")
print(hdu.header)
print("\nDati:")
print(hdu.data)
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment