爱气象,爱气象家园! 

气象家园

 找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索
查看: 4620|回复: 2

geometry_type attribute must be 'polygon' or 'polyline'

[复制链接]
发表于 2017-12-13 17:33:20 | 显示全部楼层 |阅读模式

登录后查看更多精彩内容~

您需要 登录 才可以下载或查看,没有帐号?立即注册

x
怎么把边界shp文件添加到ncl脚本中那?

将脚本直接添加在wrf_Precip.ncl后面:
filename="/home/syrus/data/WRFDomain/shp/Qinghai-Tibet_Plateau.shp"
  pres             = True
  pres@gsLineColor = "blue"
  pres@gsLineThicknessF =2
poly=gsn_add_shapefile_polylines(wks,plot,filename,pres)

draw(plot)
frame(wks)

end
出现错误:
(0)    Working on time: 2007-02-01_00:00:00
(0)    Working on time: 2007-02-01_06:02:29
(0)    Working on time: 2007-02-01_12:00:59
(0)    Error: gsn_add_shapefile_polylines: geometry_type attribute must be 'polygon' or 'polyline'
(0)           No shapefile information will be added.

如下图所示:

问题1:history_interval         = 180,为什么跑出来的数据时间是混乱的
问题2:Error: gsn_add_shapefile_polylines: geometry_type attribute must be 'polygon' or 'polyline'
(0)           No shapefile information will be added.
其中Qinghai-Tibet_Plateau.shp是从气象家园上下载的shp文件

谢谢大家



2017-12-13 17-24-22 的屏幕截图.png
2017-12-13 17-25-10屏幕截图.png
密码修改失败请联系微信:mofangbao
发表于 2018-4-23 19:12:04 | 显示全部楼层
请问楼主解决了么?我也是提示 geometry_type attribute must be 'polygon' or 'polyline'
密码修改失败请联系微信:mofangbao
 楼主| 发表于 2018-5-4 20:39:48 | 显示全部楼层
白衣风月倾天下 发表于 2018-4-23 19:12
请问楼主解决了么?我也是提示 geometry_type attribute must be 'polygon' or 'polyline'

时间长,没有弄了,有一次是下载的shp文件有问题。然后刚开始一直怀疑是自己的代码问题,后来换了一个边界数据,就好了。但不记得是否是这个问题的解决方法。
密码修改失败请联系微信:mofangbao
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

Copyright ©2011-2014 bbs.06climate.com All Rights Reserved.  Powered by Discuz! (京ICP-10201084)

本站信息均由会员发表,不代表气象家园立场,禁止在本站发表与国家法律相抵触言论

快速回复 返回顶部 返回列表