Ensure the point at r=0 has correct value and not nan

This commit is contained in:
Guilhem Lavaux 2014-12-02 17:36:52 +01:00
parent 83324fdbd1
commit 00d8d619ef
2 changed files with 6 additions and 2 deletions

View file

@ -11,6 +11,7 @@ import ksz
from ksz.constants import *
from cosmotool import interp3d
import numpy as np
from scipy import ndimage
from scipy.special import sinc
@ -159,10 +160,10 @@ def generate_from_catalog(dmin,dmax,Nside,perturb=0.0,y=0.0,do_random=False,do_h
ksz_hubble_template[idx] += m*DA
ne.evaluate('ksz_template*ksz_normalization', out=ksz_template)
ne.evaluate('ksz_hubble_template*ksz_normalization', out=ksz_hubble_template)
result =ksz_template, ksz_mask
if do_hubble:
ne.evaluate('ksz_hubble_template*ksz_normalization', out=ksz_hubble_template)
return result + ( ksz_hubble_template,)
else:
return result