在Barbs中使用transform_first关键字
我正在尝试从 HRRR 模型中绘制风倒钩,而倒钩大约需要 58-63 秒图中的 50-55 秒。我注意到倒刺没有“transform_first”关键字,那么有没有其他方法可以加速倒刺?
ax1.barbs(x,y,uwind,vwind,length=5,regrid_shape=15,color='black',alpha=0.6,transform=ccrs.PlateCarree())
regrid_shape = 12
只是稍微快一点。
我专门寻找速度。
I am trying to plot wind barbs from the HRRR model and Barbs takes about 50-55 seconds of the 58-63 second plot. I noticed that barbs doesnt have the "transform_first" keyword, so is there an alternative way to speed up barbs?
ax1.barbs(x,y,uwind,vwind,length=5,regrid_shape=15,color='black',alpha=0.6,transform=ccrs.PlateCarree())
regrid_shape = 12
is only mildly faster.
Im looking specifically for speed.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
事实证明 regrid_shape 非常昂贵;所以我只是删除了 regrid_shape 关键字。我手动稀疏阵列以获得更好的性能。
regrid_shape 还映射到 cartopy 贴图的“范围”,而不是模型网格空间。这样做是完全有意义的,因此要小心可能与您的地图范围不太匹配的区域模型。
Turns out that regrid_shape is very expensive; so i just removed regrid_shape keyword. I manually thinned the arrays for better performance.
regrid_shape also maps to the "extent" of the cartopy map, not to the model grid space. It makes total sense to do that, so be careful for regional models that may not quite match your map extent.