Skip to content
Snippets Groups Projects
Commit 833e54b4 authored by Martin Bauer's avatar Martin Bauer
Browse files

lbmpy phase plot: no warning if there are not contours

parent 750099d2
No related merge requests found
...@@ -77,7 +77,7 @@ def phase_plot(phase_field: np.ndarray, linewidth=1.0, clip=True) -> None: ...@@ -77,7 +77,7 @@ def phase_plot(phase_field: np.ndarray, linewidth=1.0, clip=True) -> None:
assert len(phase_field.shape) == 3 assert len(phase_field.shape) == 3
with warnings.catch_warnings(): with warnings.catch_warnings():
warnings.simplefilter("ignore", lineno=1230) warnings.simplefilter("ignore")
for i in range(phase_field.shape[-1]): for i in range(phase_field.shape[-1]):
scalar_field_alpha_value(phase_field[..., i], next(color_cycle), clip=clip, interpolation='bilinear') scalar_field_alpha_value(phase_field[..., i], next(color_cycle), clip=clip, interpolation='bilinear')
if linewidth: if linewidth:
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment