Skip to content
Snippets Groups Projects
Commit 18c50ed5 authored by Lionel GUEZ's avatar Lionel GUEZ
Browse files

Bug fix: use `wind_cartopy`

parent cf105012
No related branches found
No related tags found
No related merge requests found
......@@ -6,6 +6,7 @@ import sys
import matplotlib.pyplot as plt
import argparse
import netCDF4
import wind_cartopy
parser = argparse.ArgumentParser()
parser.add_argument("-s", "--scale", default = 20, type = float,
......@@ -70,11 +71,12 @@ with netCDF4.Dataset(args.input_file) as f:
lat_2d[undef_velocity].reshape(-1), transform = src_crs,
marker = "*", color = "violet", linestyle = "None")
else:
quiver_return = ax.quiver(longitude[lon_mask], latitude[lat_mask],
ugos[lat_mask][:, lon_mask],
vgos[lat_mask][:, lon_mask],
scale = args.scale, scale_units = "width",
transform = src_crs)
quiver_return = wind_cartopy.plot(ax, longitude[lon_mask],
latitude[lat_mask],
ugos[lat_mask][:, lon_mask],
vgos[lat_mask][:, lon_mask],
scale = args.scale,
scale_units = "width")
ax.quiverkey(quiver_return, 0.9, 0.9, 1, r"1 m s$^{-1}$",
coordinates = "figure")
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment