Commit 6a8759d2 authored by Lukas Platz's avatar Lukas Platz

cleanup

parent 2e60bc93
Pipeline #51977 failed with stages
in 14 minutes and 29 seconds
......@@ -90,18 +90,18 @@ def _ConvolutionOperator(domain, kernel, space=None, without_mean=False):
wgt = WeightApplier(domain, space, 1)
op = HT(diag(HT.adjoint(wgt)))
if without_mean:
return _ApplicationWithoutMeanOperator(domain, op)
return _ApplicationWithoutMeanOperator(op)
else:
return op
class _ApplicationWithoutMeanOperator(EndomorphicOperator):
def __init__(self, domain, op):
def __init__(self, op):
self._capability = self.TIMES | self.ADJOINT_TIMES
self._domain = domain
if op.domain != op.target:
raise TypeError("Operator needs to be endomorphic")
self._domain = op.domain
self._op = op
if (op.domain != domain) or (op.domain != op.target):
raise TypeError("domains incompatible")
def apply(self, x, mode):
self._check_input(x, mode)
......
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