RomanCuts
RomanCuts
A class to create cutouts from Roman WFI simulated images created by TRExS group
using the RImTimSim
package.
The class provides access to: - Per frame WCS - Season average WCS - Cutout cubes (ntime, npix, npix) from the simulated FFI stack - Save cubes to disk as ASDF
__init__
Initializes the class with field, scs, filter, and file_list.
Parameters:
-
field
(int
) –The field number.
-
sca
(int
) –The instrument Sensor Chip Assembly number.
-
filter
(str
, default:'F146'
) –The filter string (e.g., "F146"). Default is "F146".
-
file_list
(list
, default:[]
) –A list of file paths. Default is an empty list.
make_cutout
make_cutout(
radec: Tuple = (None, None),
rowcol: Tuple[int, int] = (0, 0),
size: Tuple[int, int] = (15, 15),
dithered: bool = False,
)
Creates a cutout from the data.
Parameters:
-
radec
(tuple of floats or None
, default:(None, None)
) –Right ascension and declination coordinates (ra, dec). If None, rowcol is used. Default is (None, None).
-
rowcol
(tuple of ints or None
, default:(0, 0)
) –Row and column pixel coordinates (row, col). If None, radec is used. Default is (0, 0).
-
size
(tuple of ints
, default:(15, 15)
) –Size of the cutout in pixels (rows, columns). Default is (15, 15).
save_cutout
Saves the cutout to a file.
Parameters:
-
output
(str
, default:None
) –The output file path. If None, a default filename is generated.
-
format
(str
, default:'asdf'
) –The file format ("asdf" or "fits"). Default is "asdf".