JaxLinearOperator: Fix error in adjoint_times when supplying manually implemented transpose function
Compare changes
+ 2
− 1
@@ -122,7 +122,8 @@ class JaxLinearOperator(LinearOperator):
Beginning with 2nd June, only the "Single Sign On" option for login to the GitLab web interface will be possible. If you don't have an MPCDF wide second factor so far, please get one at our SelfService (https://selfservice.mpcdf.mpg.de). The GitLab internal second factor will not work.
The apply-method of JaxLinearOperator
expects func_T
to return a tuple of values because jax.linear_transform
does so. If the user supplies a manually implemented transpose function implementation which returns just a plain value array, this assumption is broken, causing a processing error in the apply
method.
To fix this, this patch wraps manually supplied transpose function implementations in a lambda function that encapsulates their result in a tuple.