第八星系人气爱 发表于 2024-3-2 15:54:33

CDO使用简介(二)


作者:第八星系 - 李智
邮箱:lizhi258147369@163.com

1.8重采样
查看重采样前的网格信息。
!cdo griddes nbp_Lmon_CanESM5_hist-aer_r11i1p1f1_gn_185001-202012.nc> gridold
!cat gridold

因为此文件空间范围为全球,为了提升速度,我们先裁剪小区域。
!cdo sellonlatbox,100,110,25,30 nbp_Lmon_CanESM5_hist-aer_r11i1p1f1_gn_185001-202012.nc nbp_small_Lmon_CanESM5_hist-aer_r11i1p1f1_gn_185001-202012.nc



#查看网格
<div>!cdo griddes nbp_small_Lmon_CanESM5_hist-aer_r11i1p1f1_gn_185001-202012.nc
</div>

写重采样后的文件的网格信息。
%%file gridnew
gridtype= lonlat
xsize   = 11
ysize   = 5
xfirst    = 100
xinc      = 1
yfirst    = 25
yinc      = 1

!cat gridnew


!<span style="background-color: rgb(255, 255, 255);">cdo remapbil,gridnewnbp_small_Lmon_CanESM5_hist-aer_r11i1p1f1_gn_185001-202012.ncnbp_new_small_Lmon_CanESM5_hist-aer_r11i1p1f1_gn_185001-202012.nc</span>

#查看网格
!cdo griddes nbp_new_small_Lmon_CanESM5_hist-aer_r11i1p1f1_gn_185001-202012.nc


#查看各种采样方法
!cdo -h remapb



微信搜索“第八星系人造大气理论爱好者”公众号,关注获取文章数据


页: [1]
查看完整版本: CDO使用简介(二)