Created
March 18, 2014 15:58
-
-
Save ChrisBeaumont/9623018 to your computer and use it in GitHub Desktop.
Test Planck Toast
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from toasty import toast, healpix_sampler, normalizer | |
from astropy.io import fits | |
import logging | |
#print progress | |
FORMAT = ' %(asctime)-15s %(message)s' | |
logging.basicConfig(format=FORMAT) | |
logger = logging.getLogger('toasty.tile') | |
logger.setLevel(logging.DEBUG) | |
data = fits.open('/Users/beaumont/Desktop/HFI_CompMap_ThermalDustModel_2048_R1.20.fits')[1].data['TEMP'] | |
vmin, vmax = 10, 40 | |
scaling = 'linear' | |
contrast = 1 | |
bias = 0.5 | |
sampler = normalizer(healpix_sampler(data, coord='G', nest=True), | |
vmin, vmax, | |
scaling, bias, contrast) | |
toast(sampler, 3, 'toast') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment