Commit 55439304 authored by Reimar H Leike's avatar Reimar H Leike

removed clipping from point sources

parent c77eb4d0
......@@ -43,8 +43,6 @@ class PointSources(Model):
@memo
def value(self):
points = self.position['points'].local_data
# MR FIXME?!
points = np.clip(points, None, 8.2)
points = Field.from_local_data(self.position['points'].domain, points)
return self.IG(points, self._alpha, self._q)
......@@ -57,8 +55,6 @@ class PointSources(Model):
self._alpha,
scale=self._q),
self._alpha, scale=self._q)
# FIXME
outer_inv = np.clip(outer_inv, 1e-20, None)
outer = 1/outer_inv
grad = Field.from_local_data(self.position['points'].domain,
inner*outer)
......@@ -75,6 +71,4 @@ class PointSources(Model):
@staticmethod
def inverseIG(u, alpha, q):
res = norm.ppf(invgamma.cdf(u, alpha, scale=q))
# # FIXME
# res = np.clip(res, 0, None)
return res
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment