Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ift
NIFTy
Commits
41bcbbf9
Commit
41bcbbf9
authored
Aug 31, 2016
by
theos
Browse files
FFTOperator now works for non trivial field_types.
parent
5edee410
Changes
1
Hide whitespace changes
Inline
Side-by-side
nifty/operators/fft_operator/fft_operator.py
View file @
41bcbbf9
...
...
@@ -39,7 +39,10 @@ class FFTOperator(LinearOperator):
def
_times
(
self
,
x
,
spaces
,
types
):
spaces
=
utilities
.
cast_axis_to_tuple
(
spaces
,
len
(
x
.
domain
))
if
spaces
is
None
:
axes
=
None
# this case means that x lives on only one space, which is
# identical to the space in the domain of `self`. Otherwise the
# input check of LinearOperator would have failed.
axes
=
x
.
domain_axes
[
0
]
else
:
axes
=
x
.
domain_axes
[
spaces
[
0
]]
...
...
@@ -59,7 +62,10 @@ class FFTOperator(LinearOperator):
def
_inverse_times
(
self
,
x
,
spaces
,
types
):
spaces
=
utilities
.
cast_axis_to_tuple
(
spaces
,
len
(
x
.
domain
))
if
spaces
is
None
:
axes
=
None
# this case means that x lives on only one space, which is
# identical to the space in the domain of `self`. Otherwise the
# input check of LinearOperator would have failed.
axes
=
x
.
domain_axes
[
0
]
else
:
axes
=
x
.
domain_axes
[
spaces
[
0
]]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment