/dports/astro/py-astropy/astropy-5.0/astropy/io/fits/tests/ |
H A D | test_compression_failures.py | 26 compress_hdu(hdu) 33 compress_hdu(hdu) 38 hdu.data = None 40 compress_hdu(hdu) 45 del hdu._header 47 compress_hdu(hdu) 54 compress_hdu(hdu) 61 compress_hdu(hdu) 66 del hdu._header[kw] 68 compress_hdu(hdu) [all …]
|
H A D | test_table.py | 624 hdu = hdul[1] 872 hdu = hdul[1] 1648 hdu.ver = 2 1716 assert type(hdu.data['x']) == type(hdu.data.x) # noqa 1717 assert (hdu.data['x'][0] == hdu.data.x[0]).all() 1718 assert (hdu.data['x'][1] == hdu.data.x[1]).all() 2695 hdu = hdul[1] 2706 hdu = hdul[1] 2971 hdu = hdul[1] 3345 assert hdu.header.index('TUNIT1') < hdu.header.index('TTYPE2') [all …]
|
H A D | test_hdulist.py | 79 hdul.append(hdu) 92 hdul.append(hdu) 120 hdul.append(hdu) 168 hdul.append(hdu) 352 hdul.append(hdu) 365 hdul.append(hdu) 443 hdu.writeto(sf) 499 hdu.close() 523 hdu.close() 960 hdu.writeto(buf) [all …]
|
H A D | test_convenience.py | 55 hdu = fits.table_to_hdu(table) 60 assert hdu.header.index('TUNIT1') < hdu.header.index('TTYPE2') 73 hdu = fits.table_to_hdu(table) 102 hdu = fits.table_to_hdu(table) 106 hdu.header.index('comments') 122 hdu = fits.table_to_hdu(table) 158 hdu = fits.table_to_hdu(table) 173 hdu = fits.table_to_hdu(table) 176 assert 'RAMP' not in hdu.header 297 for hdu in hdus: [all …]
|
H A D | test_image.py | 26 hdu = fits.ImageHDU() 27 assert hdu.name == '' 29 hdu.name = 'FOO' 50 hdu = fits.ImageHDU() 54 hdu.ver = 1 55 assert_ver_is(hdu, 1) 384 hdu.verify() 1740 assert hdu.name == hdu.header['EXTNAME'] 1828 del hdu 1929 hdu = hdul[1] [all …]
|
H A D | test_core.py | 191 hdu = fits.ImageHDU() 199 hdu = fits.ImageHDU() 233 hdu.verify('fix') 236 hdu = fits.ImageHDU() 242 hdu = fits.ImageHDU() 246 hdu.verify('ignore') 279 return hdu 394 hdu.name = 'sCi' 400 hdu.name = 'sCi' 404 hdu.name = 'sCi' [all …]
|
H A D | test_image_dask.py | 18 hdu = ImageHDU(data=dask_array_in_mem) 19 assert isinstance(hdu.data, da.Array) 23 hdu = ImageHDU(data=dask_array_in_mem) 24 hdulist = fits.HDUList([hdu]) 35 hdu.writeto(filename) 49 hdu.writeto(filename) 92 hdu.writeto(filename) 110 hdu = PrimaryHDU(data=array) 111 hdu.writeto(filename) 124 hdu.writeto(filename) [all …]
|
H A D | test_header.py | 492 hdu = fits.PrimaryHDU() 493 hdu.header.append(c) 1210 hdu = fits.PrimaryHDU() 1219 hdu.header = hdu.header + hdu2.header 1615 hdu = fits.ImageHDU() 1617 hdu.header.extend(hdu.header.fromtextfile(self.temp('header.txt')), 1627 hdu = fits.ImageHDU() 1629 hdu.header.extend(hdu.header.fromtextfile(self.temp('header.txt')), 2049 hdu.header.append() 2050 hdu.header.append() [all …]
|
H A D | test_connect.py | 420 t = Table.read(filename, hdu=hdu) 427 t = Table.read(filename, hdu=hdu) 435 Table.read(filename, hdu=hdu) 450 t1 = Table.read(filename, hdu=hdu) 460 t2 = Table.read(filename, hdu=hdu) 470 t3 = Table.read(filename, hdu=hdu) 495 t = Table.read(self.hdus1, hdu=hdu) 500 t = Table.read(self.hdus, hdu=hdu) 505 t = Table.read(self.hdus, hdu=hdu) 511 Table.read(self.hdus, hdu=hdu) [all …]
|
H A D | test_checksum.py | 10 from astropy.io.fits.hdu.base import _ValidHDU 46 hdu = fits.PrimaryHDU(n) 140 hdu = fits.GroupsHDU(x) 240 hdu = fits.ImageHDU(n) 241 comp_hdu = fits.CompImageHDU(hdu.data, hdu.header) 272 hdu = fits.ImageHDU(n) 273 comp_hdu = fits.CompImageHDU(hdu.data, hdu.header) 328 hdu = fits.ImageHDU(n) 358 hdu = fits.ImageHDU(n) 465 if not (hasattr(hdu, '_datasum') and hdu._datasum): [all …]
|
/dports/astro/py-astropy/astropy-5.0/astropy/io/fits/hdu/ |
H A D | hdulist.py | 546 return HDUList([hdu.copy() for hdu in self]) 619 hdu = PrimaryHDU(hdu.data, hdu.header) 636 hdu = ImageHDU(hdu.data, hdu.header) 639 hdu._new = True 668 hdu = ImageHDU(hdu.data, hdu.header) 676 hdu = PrimaryHDU(hdu.data, hdu.header) 853 hdu._prewriteto(checksum=hdu._output_checksum) 1221 self._data = data[hdu._data_offset + hdu._data_size:] 1303 hdu._prewriteto(checksum=hdu._output_checksum, inplace=True) 1356 mmaps = [(idx, _get_array_mmap(hdu.data), hdu.data) [all …]
|
/dports/astro/py-astropy/astropy-5.0/astropy/timeseries/io/ |
H A D | kepler.py | 42 hdu = hdulist['LIGHTCURVE'] 44 hdu = hdulist[1] 49 if hdu.header['EXTVER'] > 1: 51 … "implemented".format(hdu.header['TELESCOP'], hdu.header['EXTVER'])) 54 if hdu.header['TIMESYS'] != 'TDB': 56 … "implemented in {} reader".format(hdu.header['TIMESYS'], hdu.header['TELESCOP'])) 58 tab = Table.read(hdu, format='fits') 86 reference_date = Time(hdu.header['BJDREFI'], hdu.header['BJDREFF'], 87 scale=hdu.header['TIMESYS'].lower(), format='jd')
|
/dports/astro/py-astropy/astropy-5.0/astropy/io/misc/asdf/tags/fits/ |
H A D | fits.py | 30 hdu = fits.PrimaryHDU(data=data, header=header) 35 hdu = fits.ImageHDU(data=data, header=header) 36 hdus.append(hdu) 43 for hdu in hdulist: 45 for card in hdu.header.cards: 60 if hdu.data is not None: 61 if hdu.data.dtype.names is not None: 62 data = table.Table(hdu.data) 64 data = hdu.data 73 for hdu in data: [all …]
|
/dports/science/py-veusz/veusz-veusz-3.3.1/veusz/dataimport/ |
H A D | defn_fits.py | 144 def getImageWCS(self, hdu, dsname, attr): argument 148 if len(hdu.shape) != 2: 189 self.getImageWCS(hdu, dsname, attr) 204 data = hdu.data.field(colname) 207 def walkHdu(self, hdu, dsname, dsread): argument 210 if hdu.data is None: 213 elif hdu.is_image: 218 for col in hdu.data.columns: 247 hdu = fitsf[idx] 536 hdu = fitsf[hdu] [all …]
|
/dports/astro/gnuastro/gnuastro-0.16/lib/gnuastro/ |
H A D | fits.h | 128 gal_fits_name_save_as_string(char *filename, char *hdu); 163 gal_fits_hdu_datasum(char *filename, char *hdu); 169 gal_fits_hdu_format(char *filename, char *hdu); 175 gal_fits_hdu_open(char *filename, char *hdu, int iomode); 178 gal_fits_hdu_open_format(char *filename, char *hdu, int img0_tab1); 204 gal_fits_key_read(char *filename, char *hdu, gal_data_t *keysll, 250 char *filename, char *hdu); 257 char *filename, char *hdu); 279 gal_fits_img_info_dim(char *filename, char *hdu, size_t *ndim); 324 gal_fits_tab_info(char *filename, char *hdu, size_t *numcols, [all …]
|
/dports/graphics/py-scikit-image/scikit-image-0.19.0/skimage/io/_plugins/ |
H A D | fits_plugin.py | 45 for hdu in hdulist: 46 if isinstance(hdu, fits.ImageHDU) or \ 47 isinstance(hdu, fits.PrimaryHDU): 48 if hdu.data is not None: 49 img_array = hdu.data 88 for n, hdu in zip(range(len(hdulist)), hdulist): 89 if isinstance(hdu, fits.ImageHDU) or \ 90 isinstance(hdu, fits.PrimaryHDU): 94 data_size = hdu.size # size is int in Astropy 3.1.2 96 data_size = hdu.size()
|
/dports/astro/gnuastro/gnuastro-0.16/bin/arithmetic/ |
H A D | operands.c | 110 newnode->hdu=NULL; in operands_add_list() 170 gal_checkset_allocate_copy(p->globalhdu, &newnode->hdu); in operands_add() 172 newnode->hdu=gal_list_str_pop(&p->hdus); in operands_add() 181 newnode->hdu)==IMAGE_HDU in operands_add() 187 p->refdata.wcs=gal_wcs_read(filename, newnode->hdu, in operands_add() 203 newnode->hdu); in operands_add() 206 else newnode->hdu=NULL; in operands_add() 224 char *filename, *hdu; in operands_pop() local 238 hdu=operands->hdu; in operands_pop() 242 data=gal_array_read_one_ch(filename, hdu, NULL, p->cp.minmapsize, in operands_pop() [all …]
|
/dports/astro/astrometry/astrometry.net-0.85/util/ |
H A D | fix_sdss_idr.py | 16 def is_sdss_idr(hdu): argument 17 hdr = hdu.header 32 def fix_sdss_idr(hdu): argument 33 hdr = hdu.header.copy() 37 return hdu 48 return hdu 56 return hdu 62 newhdu._file = hdu._file 64 newhdu._datLoc = hdu._datLoc
|
/dports/astro/py-astropy/astropy-5.0/astropy/io/fits/ |
H A D | convenience.py | 68 from .hdu.table import BinTableHDU 111 hdu = hdulist[extidx] 112 header = hdu.header 211 hdu = hdulist[extidx] 212 data = hdu.data 222 hdu = hdulist[1] 223 data = hdu.data 230 hdr = hdu.header 448 if hdu.is_image and not isinstance(hdu, PrimaryHDU): 694 f.append(hdu) [all …]
|
H A D | __init__.py | 71 from . import hdu 77 from .hdu import * 79 from .hdu.groups import GroupData 80 from .hdu.hdulist import fitsopen as open 81 from .hdu.image import Section 87 convenience.__all__ + hdu.__all__ +
|
/dports/graphics/gimp-app/gimp-2.10.30/plug-ins/file-fits/ |
H A D | fits-io.c | 720 hdu = ff->hdu_list; in fits_add_hdu() 722 hdu = hdu->next_hdu; in fits_add_hdu() 1318 switch (hdu->bitpix) in fits_eval_pixrange() 2305 FitsHduList *hdu; in fits_to_pgmraw() local 2318 if (hdu == NULL) in fits_to_pgmraw() 2321 if (hdu->naxis < 2) in fits_to_pgmraw() 2329 fprintf (pgmout, "P5\n%d %d\n255\n", hdu->naxisn[0], hdu->naxisn[1]); in fits_to_pgmraw() 2341 nbytes = hdu->naxisn[0]*hdu->naxisn[1]; in fits_to_pgmraw() 2395 FitsHduList *hdu; in pgmraw_to_fits() local 2440 if (hdu == NULL) in pgmraw_to_fits() [all …]
|
/dports/astro/gnuastro/gnuastro-0.16/bin/script/ |
H A D | ds9-region.in | 34 hdu=1 83 -h, --hdu=STR HDU/extension of all input FITS files. 185 … -h|--hdu) hdu="$2"; check_v "$1" "$hdu"; shift;shift;; 186 -h=*|--hdu=*) hdu="${1#*=}"; check_v "$1" "$hdu"; shift;; 187 -h*) hdu=$(echo "$1" | sed -e's/-h//'); check_v "$1" "$hdu"; shift;; 306 else printf "# Input file: $input (hdu $hdu)\n" >> $out 331 asttable $input --hdu=$hdu --column=$col \ 346 asttable $input --hdu=$hdu --column=$col --column=$namecol \
|
H A D | radial-profile.in | 37 hdu=1 93 -h, --hdu=STR HDU/extension of all input FITS files. 199 … -h|--hdu) hdu="$2"; check_v "$1" "$hdu"; shift;shift;; 200 -h=*|--hdu=*) hdu="${1#*=}"; check_v "$1" "$hdu"; shift;; 201 -h*) hdu=$(echo "$1" | sed -e's/-h//'); check_v "$1" "$hdu"; shift;; 328 xcenter=$(astfits $inputs --hdu=$hdu | awk '/^NAXIS1/{print $3/2+0.5}') 329 ycenter=$(astfits $inputs --hdu=$hdu | awk '/^NAXIS2/{print $3/2+0.5}') 346 --wcsfile=$inputs --wcshdu=$hdu) 378 rmax=$(astfits $inputs --hdu=$hdu \ 433 astcrop $inputs --hdu=$hdu --center=$xcenter,$ycenter --mode=img \ [all …]
|
/dports/astro/py-astropy/astropy-5.0/docs/nddata/examples/ |
H A D | cutout2d_tofits.py | 14 hdu = fits.open(filename)[0] 15 wcs = WCS(hdu.header) 18 cutout = Cutout2D(hdu.data, position=position, size=size, wcs=wcs) 21 hdu.data = cutout.data 24 hdu.header.update(cutout.wcs.to_header()) 28 hdu.writeto(cutout_filename, overwrite=True)
|
/dports/science/py-asdf/asdf-2.8.1/asdf/ |
H A D | fits_embed.py | 28 def __init__(self, hdu): argument 29 self._hdu = hdu 84 for i, hdu in enumerate(self._hdulist): 85 if hdu is block._hdu: 86 if hdu.name == '': 91 FITS_SOURCE_PREFIX, hdu.name, hdu.ver) 101 for hdu in self._hdulist: 102 if hdu.data is None: 104 if base is util.get_array_base(hdu.data): 105 return _FitsBlock(hdu) [all …]
|