Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ift
NIFTy
Commits
0a97a9ae
Commit
0a97a9ae
authored
Sep 03, 2019
by
Philipp Arras
Browse files
Multifrequency plotting with only one frequency
parent
646f0dbf
Changes
1
Hide whitespace changes
Inline
Side-by-side
nifty5/plot.py
View file @
0a97a9ae
...
...
@@ -348,8 +348,12 @@ def _plot2D(f, ax, **kwargs):
if
len
(
dom
)
==
2
:
if
(
not
isinstance
(
dom
[
1
],
RGSpace
))
or
len
(
dom
[
1
].
shape
)
!=
1
:
raise
TypeError
(
"need 1D RGSpace as second domain"
)
rgb
=
_rgb_data
(
f
.
to_global_data
())
have_rgb
=
True
if
dom
[
1
].
shape
[
0
]
==
1
:
from
.sugar
import
from_global_data
f
=
from_global_data
(
f
.
domain
[
0
],
f
.
to_global_data
()[...,
0
])
else
:
rgb
=
_rgb_data
(
f
.
to_global_data
())
have_rgb
=
True
foo
=
kwargs
.
pop
(
"norm"
,
None
)
norm
=
{}
if
foo
is
None
else
{
'norm'
:
foo
}
...
...
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