爱气象,爱气象家园! 

气象家园

 找回密码
 立即注册

QQ登录

只需一步,快速开始

新浪微博登陆

只需一步, 快速开始

搜索
查看: 5887|回复: 6

读取grib2经纬度范围

[复制链接]

新浪微博达人勋

发表于 2016-10-27 11:48:37 | 显示全部楼层 |阅读模式
数据资料
我看过提问的智慧: 没看过(看完再来提问)

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

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

x
本人是程序员,需要从grib2文件中读取经纬度范围和X方向网格点和Y方向网格点,哪位大侠帮帮忙{:eb511:}{:eb511:}{:eb511:},数据在附件里

pcpratio.2016.09.22.0000.240m.grib2

813.73 KB, 下载次数: 5

密码修改失败请联系微信:mofangbao

新浪微博达人勋

发表于 2016-10-27 13:39:26 | 显示全部楼层
xdef 7184 linear 66.488596 0.00988694922392079
ydef 3573 linear 23.145524 0.00909090909090909
密码修改失败请联系微信:mofangbao

新浪微博达人勋

 楼主| 发表于 2016-10-27 15:23:34 | 显示全部楼层
男紫汗 发表于 2016-10-27 13:39
xdef 7184 linear 66.488596 0.00988694922392079
ydef 3573 linear 23.145524 0.00909090909090909

非常感谢您百忙中抽时间回答我的问题,真是帮了一个大忙,在请教一个问题,如何根据某个经纬度获取到对应位置要素值?有什么方法可以获取呢?
密码修改失败请联系微信:mofangbao

新浪微博达人勋

发表于 2016-10-27 16:19:13 | 显示全部楼层
广东-华仔 发表于 2016-10-27 15:23
非常感谢您百忙中抽时间回答我的问题,真是帮了一个大忙,在请教一个问题,如何根据某个经纬度获取到对应 ...

用MeteoInfo读取的数据信息:
File Name: E:\Temp\pcpratio.2016.09.22.0000.240m.grib2
File type: GRIB2 Collection (GRIB-2)
Dimensions: 3
        x = 4897;
        y = 3337;
        time = 1;
X Dimension: Xmin = -2447232.1999999997; Xmax = 2448767.8000000003; Xsize = 4897; Xdelta = 1000.0
Y Dimension: Ymin = -1689810.9; Ymax = 1646189.1; Ysize = 3337; Ydelta = 1000.0
Global Attributes:
        : Originating_or_generating_Center = "COnsortium for Small scale MOdelling (COSMO)"
        : Originating_or_generating_Subcenter = "0"
        : GRIB_table_version = "2,1"
        : Type_of_generating_process = "Forecast"
        : file_format = "GRIB-2"
        : Conventions = "CF-1.6"
        : history = "Read using CDM IOSP GribCollection v3"
        : featureType = "GRID"
Variations: 6
        int LambertConformal_Projection);
                LambertConformal_Projection: grid_mapping_name = "lambert_conformal_conic"
                LambertConformal_Projection: latitude_of_projection_origin = 41.0
                LambertConformal_Projection: longitude_of_central_meridian = 102.0
                LambertConformal_Projection: standard_parallel = 41.0
                LambertConformal_Projection: earth_radius = 6371229.0
        float x(x);
                x: standard_name = "projection_x_coordinate"
                x: units = "km"
        float y(y);
                y: standard_name = "projection_y_coordinate"
                y: units = "km"
        double reftime);
                reftime: units = "Minute since 2016-09-22T00:00:00Z"
                reftime: standard_name = "forecast_reference_time"
                reftime: long_name = "GRIB reference time"
                reftime: calendar = "proleptic_gregorian"
        double time(time);
                time: units = "Minute since 2016-09-22T00:00:00Z"
                time: standard_name = "time"
                time: long_name = "GRIB forecast or observation time"
                time: calendar = "proleptic_gregorian"
        float VAR0-1-241_FROM_250-0--1_surface(time,y,x);
                VAR0-1-241_FROM_250-0--1_surface: long_name = "Unknown Parameter 0-1-241 @ Ground or water surface"
                VAR0-1-241_FROM_250-0--1_surface: units = ""
                VAR0-1-241_FROM_250-0--1_surface: missing_value = NaNf
                VAR0-1-241_FROM_250-0--1_surface: grid_mapping = "LambertConformal_Projection"
                VAR0-1-241_FROM_250-0--1_surface: coordinates = "reftime time y x "
                VAR0-1-241_FROM_250-0--1_surface: Grib_Variable_Id = "VAR_0-1-241_L1"
                VAR0-1-241_FROM_250-0--1_surface: Grib2_Parameter = 0, 1, 241
                VAR0-1-241_FROM_250-0--1_surface: Grib2_Parameter_Discipline = "Meteorological products"
                VAR0-1-241_FROM_250-0--1_surface: Grib2_Parameter_Category = "Moisture"
                VAR0-1-241_FROM_250-0--1_surface: Grib2_Level_Type = "Ground or water surface"
                VAR0-1-241_FROM_250-0--1_surface: Grib2_Generating_Process_Type = "Forecast"
密码修改失败请联系微信:mofangbao

新浪微博达人勋

发表于 2016-10-27 16:23:21 | 显示全部楼层
........................................
密码修改失败请联系微信:mofangbao

新浪微博达人勋

发表于 2016-10-28 15:05:35 | 显示全部楼层
广东-华仔 发表于 2016-10-27 15:23
非常感谢您百忙中抽时间回答我的问题,真是帮了一个大忙,在请教一个问题,如何根据某个经纬度获取到对应 ...

读取资料啊
密码修改失败请联系微信:mofangbao

新浪微博达人勋

 楼主| 发表于 2016-11-1 16:15:46 | 显示全部楼层
MeteoInfo 发表于 2016-10-27 16:19
用MeteoInfo读取的数据信息:
File Name: E:\Temp\pcpratio.2016.09.22.0000.240m.grib2
File type: GR ...

谢谢王老师的回答,有个问题请教您:X Dimension: Xmin = -2447232.1999999997; Xmax = 2448767.8000000003,这个看不懂,是什么意思呢?
密码修改失败请联系微信:mofangbao
您需要登录后才可以回帖 登录 | 立即注册 新浪微博登陆

本版积分规则

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

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

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