aboutsummaryrefslogtreecommitdiffstats
path: root/fg21sim/utils/healpix.py
Commit message (Collapse)AuthorAgeFilesLines
* healpix.py: Implement "ang2pix_ring" and "pix2ang_ring" with JITAaron LI2016-10-251-0/+213
| | | | | | | | | | To optimize "map_grid_to_healpix()" in `grid.py` which uses "healpy.ang2pix()" using `numba.jit`, implement the latter's functionality explicitly with `numba.jit` support. The implementation simply mimic the corresponding functions "ang2pix_ring_z_phi()" and "pix2ang_ring_z_phi()" in HEALPix's "src/C/subs/chealpix.c". Thanks!
* healpix.py: Optimize "_calc_hpx_indicies()" and "_calc_hpx_row_idx()"_Aaron LI2016-10-251-60/+68
| | | | | Also place "_calc_hpx_row_idx()" before "_calc_hpx_indicies()", which is required by `numba`.
* utils: healpix2hpx & hpx2healpix: Remove "header" parameterAaron LI2016-10-111-35/+20
| | | | | | | | * healpix2hpx(), hpx2healpix(): Remove the "header" parameter, thus the "data" parameter can only be either the filename or a HDU; * healpix2hpx(): Remove the check on "ORDERING", since "read_fits_healpix()" always return the HEALPix data in RING ordering; * Small updates to the log messages and comments.
* utils: Update documentations, also fix stylesAaron LI2016-10-111-32/+40
|
* utils/healpix.py: log that HPX indices calculation may take a while.Aaron LI2016-10-101-0/+1
|
* utils: Preseve the dtype when read/write FITS filesAaron LI2016-10-101-3/+6
| | | | | | | | * utils/fits.py: hack the dtype to ignore the byteorder (FITS data use big endianness, e.g., dtype(">f4")) * utils/healpix.py: explicit convert the dtype and log the dtype * bin/healpix2hpx, bin/hpx2healpix: remove the --float argument * other minor fixes/updates
* Use newly added "read_fits_healpix()"Aaron LI2016-10-091-3/+3
| | | | Also remove a unused variable in "galactic/synchrotron.py"
* utils/healpix.py: fix logging import; minor style fixesAaron LI2016-10-091-10/+5
|
* utils/healpix.py: Fix logger nameAaron LI2016-09-291-1/+1
|
* utils/healpix.py: Add various log INFO messagesAaron LI2016-09-291-6/+22
| | | | Also fix a bug about "append_comment".
* utils/healpix.py: remove duplicated headerAaron LI2016-09-271-2/+0
|
* utils/healpix.py: HEALPix data and HPX projection conversionsAaron LI2016-09-271-0/+340
* healpix2hpx: reorganize HEALPix data in HPX projection * hpx2healpix: recover the HEALPix data from HPX projection Thanks: M. Calabretta: WCSLIB: HPXcvt TODO: Add test codes