Skip to content

Commit

Permalink
Merge pull request #57 from kthyng/mypyfix
Browse files Browse the repository at this point in the history
Mypyfix
  • Loading branch information
kthyng authored Apr 26, 2023
2 parents 729ed0a + 39589c7 commit 6bc1f16
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions ocean_model_skill_assessor/plot/map.py
Original file line number Diff line number Diff line change
Expand Up @@ -223,16 +223,16 @@ def plot_map(
else:
bbox = [min(min_lons), min(min_lats), max(max_lons), max(max_lats)]

kwargs_plot = {}
kwargs_plot: Dict[str, Union[str, list]] = {}

# plot stations
inds = (min_lons == max_lons) | (types == "point")
if inds.sum() > 0:
if legend:
kwargs_plot["label"] = list(station_names[inds])
assert isinstance(colors_data, list)
ax.set_prop_cycle(color=colors_data)
else:
assert isinstance(colors_data, list)
kwargs_plot["color"] = colors_data
# # import pdb; pdb.set_trace()
# ax.scatter(
Expand Down Expand Up @@ -271,7 +271,6 @@ def plot_map(
kwargs_plot["label"] = list(station_names[inds])
ax.set_prop_cycle(color=colors_data)
else:
assert isinstance(colors_data, list)
kwargs_plot["color"] = colors_data # [inds]
ax.plot(
[min_lons[inds], max_lons[inds]],
Expand All @@ -289,7 +288,6 @@ def plot_map(
kwargs_plot["label"] = list(station_names[inds])
ax.set_prop_cycle(color=colors_data)
else:
assert isinstance(colors_data, list)
kwargs_plot["color"] = colors_data # [inds]
ax.plot(
[
Expand Down

0 comments on commit 6bc1f16

Please sign in to comment.