Skip to content
Snippets Groups Projects
Commit f3dea2e4 authored by Philipp Arras's avatar Philipp Arras
Browse files

Merge branch 'linearization_logic_fixups' into 'NIFTy_6'

Linearization logic fixups

See merge request !427
parents f507f3aa 951f490f
Branches
Tags
1 merge request!427Linearization logic fixups
Pipeline #71314 passed
...@@ -27,10 +27,6 @@ class Operator(metaclass=NiftyMeta): ...@@ -27,10 +27,6 @@ class Operator(metaclass=NiftyMeta):
domain, and can also provide the Jacobian. domain, and can also provide the Jacobian.
""" """
VALUE_ONLY = 0
WITH_JAC = 1
WITH_METRIC = 2
@property @property
def domain(self): def domain(self):
"""The domain on which the Operator's input Field is defined. """The domain on which the Operator's input Field is defined.
...@@ -202,7 +198,7 @@ class Operator(metaclass=NiftyMeta): ...@@ -202,7 +198,7 @@ class Operator(metaclass=NiftyMeta):
return self.apply(x.trivial_jac()).prepend_jac(x.jac) return self.apply(x.trivial_jac()).prepend_jac(x.jac)
elif isinstance(x, (Field, MultiField)): elif isinstance(x, (Field, MultiField)):
return self.apply(x) return self.apply(x)
raise TypeError('Operator can only consume Field, MultiFields and Linearizations') return self @ x
def ducktape(self, name): def ducktape(self, name):
from .simple_linear_operators import ducktape from .simple_linear_operators import ducktape
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment