Example #1
0
def fov_Ks():
    _src = _single_table_source()
    _fov = FieldOfView(header=_fov_header(),
                       waverange=(1.9, 2.4),
                       area=1 * u.m**2)
    _fov.extract_from(_src)
    return _fov
Example #2
0
    def test_returns_an_imagehdu(self):
        src_table = so._table_source()
        src_table.fields[0]["x"] = [-15,-5,0,0] * u.arcsec
        src_table.fields[0]["y"] = [0,0,5,15] * u.arcsec

        hdr = ho._fov_header()  # 20x20" @ 0.2" --> [-10, 10]"
        wav = [1.9, 2.1] * u.um
        fov = FieldOfView(hdr, wav)

        fov.extract_from(src_table)

        waveset = np.linspace(wav[0], wav[1], 51)
        hdu = fov_utils.make_cube_from_table(fov.fields[0], fov.spectra,
                                             waveset, fov.header)

        assert isinstance(hdu, fits.ImageHDU)
def fov_hdr():
    return hdrs._fov_header()
Example #4
0
def fov_hdr():
    return _fov_header()
Example #5
0
def _fov_197_202_um():
    """ A FOV compatible with 3 slices of so._cube_source()"""
    hdr = ho._fov_header()  # 20x20" @ 0.2" --> [-10, 10]"
    wav = [1.97000000001, 2.02] * u.um  # Needs [1.98, 2.00, 2.02] µm --> 3 slices
    fov = FieldOfView(hdr, wav, area=1*u.m**2)
    return fov
Example #6
0
def _fov_190_210_um():
    """ A FOV compatible with 11 slices of so._cube_source()"""
    hdr = ho._fov_header()  # 20x20" @ 0.2" --> [-10, 10]"
    wav = [1.9, 2.1] * u.um
    fov = FieldOfView(hdr, wav, area=1 * u.m ** 2)
    return fov