本文整理汇总了Python中WLanalysis.txt2map_fcn方法的典型用法代码示例。如果您正苦于以下问题:Python WLanalysis.txt2map_fcn方法的具体用法?Python WLanalysis.txt2map_fcn怎么用?Python WLanalysis.txt2map_fcn使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类WLanalysis
的用法示例。
在下文中一共展示了WLanalysis.txt2map_fcn方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: array
# 需要导入模块: import WLanalysis [as 别名]
# 或者: from WLanalysis import txt2map_fcn [as 别名]
plot_dir = tSZ_dir+'plot/'
centers = array([[34.5, -7.5], [134.5, -3.25],[214.5, 54.5],[ 332.75, 1.9]])
PPA512 = 2.4633625
sizes = (1330, 800, 1120, 950)
sizedeg_arr = array([(sizes[Wx-1]/512.0)**2*12.0 for Wx in range(1,5)])
prefix_arr = ('nilc_ymap', 'milca_ymap', 'GARY_ymap', 'JCH_ymap50')
sigmaG_arr = array([4.246, 4.246, 0, 4.246, 1.97]) #smoothing for the 4 maps, last number is for CIB maps
####### create maps, and plot them out ######
if create_maps:
for fn in os.listdir(tSZ_dir+'planck/'):
if fn[-3:]=='txt':
print fn
print fn[:-3]+'npy'
full_fn = tSZ_dir+'planck/'+fn
imap=WLanalysis.txt2map_fcn(full_fn, offset = False)
if fn[-3:]=='npy':
imap = load(tSZ_dir+'planck/'+fn)
if 'mask' in fn:
imshow(imap, origin='lower', vmin=0, vmax=1)
elif '857' in fn:
imshow(imap, origin='lower')
elif 'JCH_ymap' in fn:
imshow(imap, origin='lower', vmin=-2e-5, vmax=2e-5)
elif 'GARY' in fn:
imap = WLanalysis.smooth(imap, 2.5*4)
imshow(imap, origin='lower', vmin=-2e-5, vmax=2e-5)
else:
#imshow(imap, origin='lower', vmin=-3*std(imap), vmax=3*std(imap))
imshow(imap, origin='lower', vmin=-3e-6, vmax=3e-6)
title(fn[:-4])