Commit 4ba18e98 authored by Philipp Arras's avatar Philipp Arras
Browse files

Simplify interface of PoissonLogLikelihood

parent 943ef47a
Pipeline #31317 passed with stages
in 2 minutes and 7 seconds
......@@ -6,15 +6,15 @@ from ..sugar import log, makeOp
class PoissonLogLikelihood(Energy):
def __init__(self, position, lamb, d):
def __init__(self, lamb, d):
s: Sky model object
value = 0.5 * s.vdot(s), i.e. a log-Gauss distribution with unit
super(PoissonLogLikelihood, self).__init__(position)
self._lamb =
super(PoissonLogLikelihood, self).__init__(lamb.position)
self._lamb = lamb
self._d = d
lamb_val = self._lamb.value
......@@ -29,7 +29,7 @@ class PoissonLogLikelihood(Energy):
self._curvature = SandwichOperator.make(self._lamb.gradient, metric)
def at(self, position):
return self.__class__(position, self._lamb, self._d)
return self.__class__(, self._d)
def value(self):
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