Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Identity Operator - Domain and Range geometry should be the same #1980

Open
MargaretDuff opened this issue Nov 8, 2024 · 1 comment
Open
Assignees
Labels
bug Something isn't working

Comments

@MargaretDuff
Copy link
Member

Description

In the Identity Operator, domain and range geometry can be set to be different:

def __init__(self, domain_geometry, range_geometry=None):
if range_geometry is None:
range_geometry = domain_geometry
super(IdentityOperator, self).__init__(domain_geometry=domain_geometry,
range_geometry=range_geometry)

However, the forward and adjoint operators just return their input. They do not use the range geometry:

def direct(self,x,out=None):
r'''Returns the input data :math:`x`
Parameters
----------
x : DataContainer or BlockDataContainer
Input data
out : DataContainer or BlockDataContainer, optional
If out is not None the output of the Operator will be filled in out, otherwise a new object is instantiated and returned. The default is None.
Returns
-------
DataContainer or BlockDataContainer
:math:`\mathrm{Id}(x) = x`
'''
if out is None:
return x.copy()
else:
out.fill(x)
return out

Propose that the option to pass a range geometry is removed.

Discussed with @bosschmidt at the CIL user meeting hackathon.

@MargaretDuff MargaretDuff added the bug Something isn't working label Nov 8, 2024
@MargaretDuff MargaretDuff self-assigned this Nov 8, 2024
@github-project-automation github-project-automation bot moved this to Todo in CIL work Nov 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Todo
Development

No branches or pull requests

2 participants
@MargaretDuff and others