[misc] May last round of bug corrections
This commit is contained in:
+15
-16
@@ -109,15 +109,15 @@ def quiver(ax, map_h, map_v, extent, key_v=None, label="", **kwargs):
|
||||
# add vector key
|
||||
if key_v is None:
|
||||
key_v = (max_v + min_v) / 2.0
|
||||
ax.quiverkey(
|
||||
vec_field,
|
||||
0.6,
|
||||
0.98,
|
||||
key_v,
|
||||
f"${key_v:g}$ {label}",
|
||||
labelpos="E",
|
||||
coordinates="figure",
|
||||
)
|
||||
ax.quiverkey(
|
||||
vec_field,
|
||||
0.6,
|
||||
0.98,
|
||||
key_v,
|
||||
f"${key_v:g}$ {label}",
|
||||
labelpos="E",
|
||||
coordinates="figure",
|
||||
)
|
||||
|
||||
|
||||
def line_integral_convolution(ax, map_h, map_v, extent, **kwargs):
|
||||
@@ -793,7 +793,7 @@ class Plotter(Aggregator, BaseProcessor):
|
||||
except AttributeError:
|
||||
cbar = plt.colorbar()
|
||||
if label is not None:
|
||||
if text_embeded:
|
||||
if colorbar_embeded:
|
||||
cbar.set_label(" " + label, color=overtext_color, loc="bottom")
|
||||
else:
|
||||
cbar.set_label(label)
|
||||
@@ -824,14 +824,13 @@ class Plotter(Aggregator, BaseProcessor):
|
||||
plot_overlay = self.overlays[plot_overlay]
|
||||
xlim = plt.xlim()
|
||||
ylim = plt.ylim()
|
||||
try:
|
||||
if len(overlays_kwargs) > i:
|
||||
plot_overlay(ax_los, im_extent, **overlays_kwargs[i])
|
||||
except IndexError:
|
||||
else:
|
||||
plot_overlay(ax_los, im_extent)
|
||||
finally:
|
||||
# Restore previous limits in case overlays changed it
|
||||
plt.xlim(xlim)
|
||||
plt.ylim(ylim)
|
||||
|
||||
plt.xlim(xlim)
|
||||
plt.ylim(ylim)
|
||||
|
||||
return PlotInfo(
|
||||
plot_type=PlotType.IMAGE,
|
||||
|
||||
Reference in New Issue
Block a user