Skip to content

Commit 7148e75

Browse files
committed
bug: fix plot pol save name args
1 parent 997e4bb commit 7148e75

3 files changed

Lines changed: 16 additions & 2 deletions

File tree

CHANGELOG

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
0.1.10
2+
- bug: save name for plot pol had old mpl args
13
0.1.9
24
- tests: add prismatic and refiner tests (#81, #83)
35
- tests: add more tests (#81, #82)

temul/topotem/polarisation.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -573,8 +573,8 @@ def plot_polarisation_vectors(
573573
# plt.tight_layout()
574574
if save is not None:
575575
plt.savefig(fname=save + '_' + plot_style + '.png',
576-
transparent=True, frameon=False, bbox_inches='tight',
577-
pad_inches=None, dpi=300, labels=False)
576+
transparent=True, bbox_inches='tight',
577+
pad_inches=None, dpi=300)
578578
return ax
579579

580580

tests/test_topotem_polarisation.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,18 @@ def test_plot_polarisation_vectors_overlay_unit_vector(
103103
overlay=overlay, unit_vector=unit_vector)
104104

105105

106+
def test_plot_polarisation_vectors_simple(
107+
get_dummy_xyuv, handle_plots):
108+
"""Check the available overlay, unit_vector."""
109+
sublatticeA, sublatticeB, x, y, u, v = get_dummy_xyuv
110+
_ = pol.plot_polarisation_vectors(
111+
x, y, u, v, image=sublatticeA.image, save="cool_name",
112+
overlay=False, plot_style='colormap',
113+
title='Vector Arrows', cmap='viridis',
114+
monitor_dpi=50, unit_vector=False
115+
)
116+
117+
106118
@pytest.mark.parametrize(
107119
"sampling, units",
108120
[

0 commit comments

Comments
 (0)