Buoy (ship)¶
目录
Data directory structure¶
The Buoy(ship) data is organized as xml files every 15 minutes combined with surface data :
> ls -la /g3/tianwh/share/conobs/rec_RSURF_20190* -rw-r--r-- 1 tianwh obs 11482070 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060100_g_06.dat -rw-r--r-- 1 tianwh obs 11654320 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060106_g_06.dat -rw-r--r-- 1 tianwh obs 11637320 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060112_g_06.dat -rw-r--r-- 1 tianwh obs 11630570 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060118_g_06.dat -rw-r--r-- 1 tianwh obs 11549820 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060200_g_06.dat -rw-r--r-- 1 tianwh obs 11672570 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060206_g_06.dat -rw-r--r-- 1 tianwh obs 11687820 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060212_g_06.dat -rw-r--r-- 1 tianwh obs 11619320 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060218_g_06.dat -rw-r--r-- 1 tianwh obs 11566570 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060300_g_06.dat -rw-r--r-- 1 tianwh obs 11562820 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060306_g_06.dat -rw-r--r-- 1 tianwh obs 11619320 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060312_g_06.dat -rw-r--r-- 1 tianwh obs 11468820 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060318_g_06.dat -rw-r--r-- 1 tianwh obs 11398070 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060400_g_06.dat -rw-r--r-- 1 tianwh obs 11605820 9月 25 00:59 /g3/tianwh/share/conobs/rec_RSURF_2019060406_g_06.dat ...... > ls -la /g3/tianwh/share/conobs/rec_RGWST_* -rw-r--r-- 1 tianwh obs 93516320 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060100_g_06.dat -rw-r--r-- 1 tianwh obs 93554820 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060106_g_06.dat -rw-r--r-- 1 tianwh obs 93540820 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060112_g_06.dat -rw-r--r-- 1 tianwh obs 93005820 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060118_g_06.dat -rw-r--r-- 1 tianwh obs 93162320 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060200_g_06.dat -rw-r--r-- 1 tianwh obs 93525820 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060206_g_06.dat -rw-r--r-- 1 tianwh obs 93411320 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060212_g_06.dat -rw-r--r-- 1 tianwh obs 93466570 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060218_g_06.dat -rw-r--r-- 1 tianwh obs 93471570 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060300_g_06.dat -rw-r--r-- 1 tianwh obs 93224570 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060306_g_06.dat -rw-r--r-- 1 tianwh obs 93466320 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060312_g_06.dat -rw-r--r-- 1 tianwh obs 93426320 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060318_g_06.dat -rw-r--r-- 1 tianwh obs 93565070 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060400_g_06.dat -rw-r--r-- 1 tianwh obs 93464320 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060406_g_06.dat -rw-r--r-- 1 tianwh obs 93514320 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060412_g_06.dat -rw-r--r-- 1 tianwh obs 93420820 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060418_g_06.dat -rw-r--r-- 1 tianwh obs 93526820 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060500_g_06.dat -rw-r--r-- 1 tianwh obs 93393320 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060506_g_06.dat -rw-r--r-- 1 tianwh obs 93572570 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060512_g_06.dat -rw-r--r-- 1 tianwh obs 93435570 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060518_g_06.dat -rw-r--r-- 1 tianwh obs 93589820 9月 25 01:00 /g3/tianwh/share/conobs/rec_RGWST_2019060600_g_06.dat
Data format¶
CIMISS format data is looks like :
RSURF 2019 6 1 0 45928 6 9 9
00081 81.00 -5.53 -36.87 19.00 1.00 100.00
1013.20 23.05 21.35 347.00 0.00 999999.00 999999.00 999999.00 1011.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00
00081 81.00 -5.53 -36.87 19.00 1.00 0.00
1012.80 24.15 21.75 345.00 0.10 999999.00 999999.00 999999.00 1010.60 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00
00081 81.00 -5.53 -36.87 19.00 1.00 200.00
1012.90 22.25 21.25 333.00 0.00 999999.00 999999.00 999999.00 1010.70 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00
00086 86.00 -19.98 -43.96 1214.00 1.00 0.00
1016.00 20.75 14.25 289.00 1.80 999999.00 999999.00 999999.00 882.20 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00
00086 86.00 -19.98 -43.96 1214.00 1.00 100.00
1016.30 20.25 14.35 306.00 1.50 999999.00 999999.00 999999.00 882.30 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00
00086 86.00 -19.98 -43.96 1214.00 31.00 2100.00
1015.10 21.35 13.95 288.00 3.90 999999.00 999999.00 999999.00 881.70 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00
00086 86.00 -19.98 -43.96 1214.00 1.00 200.00
1016.30 20.45 14.35 283.00 2.50 999999.00 999999.00 999999.00 882.40 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00 8.00
01001 1001.00 70.94 -8.67 10.00 31.00 2200.00
1015.80 -0.40 -1.80 341.00 10.70 999999.00 999999.00 999999.00 1014.60 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01001 1001.00 70.94 -8.67 10.00 1.00 200.00
1014.60 -0.40 -1.97 337.00 10.30 999999.00 999999.00 999999.00 1013.40 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01001 1001.00 70.94 -8.67 10.00 1.00 100.00
1015.00 -0.40 -2.06 340.00 11.60 999999.00 999999.00 999999.00 1013.80 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01001 1001.00 70.94 -8.67 10.00 31.00 2300.00
1015.20 -0.40 -2.23 341.00 10.40 999999.00 999999.00 999999.00 1014.00 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01001 1001.00 70.94 -8.67 10.00 31.00 2100.00
1015.80 -0.20 -1.89 340.00 13.60 999999.00 999999.00 999999.00 1014.60 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01001 1001.00 70.94 -8.67 10.00 1.00 0.00
1015.00 -0.20 -1.58 344.00 12.10 999999.00 0.00 999999.00 1013.80 0.00 0.00 0.00 0.00 0.00 8.00 0.00 8.00 0.00
01002 1002.00 80.06 16.25 8.00 1.00 100.00
1020.50 -1.90 -2.89 109.00 6.80 999999.00 999999.00 999999.00 1019.70 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01002 1002.00 80.06 16.25 8.00 31.00 2200.00
1020.80 -0.20 -2.30 89.00 6.90 999999.00 999999.00 999999.00 1020.00 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01002 1002.00 80.06 16.25 8.00 31.00 2300.00
1020.70 -1.20 -2.59 111.00 6.30 999999.00 999999.00 999999.00 1019.80 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01002 1002.00 80.06 16.25 8.00 31.00 2100.00
1020.70 0.00 -1.96 85.00 7.20 999999.00 999999.00 999999.00 1019.90 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01002 1002.00 80.06 16.25 8.00 1.00 0.00
1020.70 -1.90 -3.02 119.00 7.30 999999.00 999999.00 999999.00 1019.80 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01002 1002.00 80.06 16.25 8.00 1.00 200.00
1020.30 -1.70 -2.96 111.00 8.60 999999.00 999999.00 999999.00 1019.50 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01003 1003.00 77.00 15.54 10.00 1.00 100.00
1014.70 -1.30 -2.83 110.00 13.70 999999.00 999999.00 999999.00 1013.30 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01003 1003.00 77.00 15.54 10.00 31.00 2300.00
1014.40 1.50 -3.16 62.00 7.60 999999.00 999999.00 999999.00 1013.00 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01003 1003.00 77.00 15.54 10.00 31.00 2200.00
1014.00 1.40 -3.26 59.00 12.50 999999.00 999999.00 999999.00 1012.60 0.00 0.00 0.00 0.00 0.00 8.00 8.00 8.00 0.00
01003 1003.00 77.00 15.54 10.00 31.00 2100.00
1013.50 1.40 -3.45 57.00 13.10 999999.00 999999.00 999999.00 1012.10 0.00 1.00 1.00 0.00 0.00 8.00 8.00 8.00 0.00
01003 1003.00 77.00 15.54 10.00 1.00 0.00
1014.40 1.10 -2.99 53.00 9.80 999999.00 0.00 999999.00 1013.00 0.00 0.00 0.00 0.00 0.00 8.00 0.00 8.00 0.00
RGWST 2019 6 1 0 374065 6 9 9
06110 6110.00 43.64 89.80 1385.00 31.00 2100.00
999999.00 13.80 999999.00 178.00 5.20 0.00 999999.00 999999.00 999999.00 7.00 0.00 7.00 0.00 0.00 0.00 9.00 9.00 7.00
06110 6110.00 43.64 89.80 1385.00 31.00 2300.00
999999.00 13.70 999999.00 172.00 7.00 0.00 999999.00 999999.00 999999.00 7.00 0.00 7.00 0.00 0.00 0.00 9.00 9.00 7.00
06110 6110.00 43.64 89.80 1385.00 1.00 0.00
999999.00 16.00 999999.00 194.00 3.90 0.00 999999.00 999999.00 999999.00 7.00 0.00 7.00 0.00 0.00 0.00 9.00 9.00 7.00
06110 6110.00 43.64 89.80 1385.00 1.00 100.00
999999.00 19.10 999999.00 160.00 5.90 0.00 999999.00 999999.00 999999.00 7.00 0.00 7.00 0.00 0.00 0.00 9.00 9.00 7.00
06110 6110.00 43.64 89.80 1385.00 1.00 200.00
999999.00 22.00 999999.00 332.00 3.30 0.00 999999.00 999999.00 999999.00 7.00 0.00 7.00 0.00 0.00 0.00 9.00 9.00 7.00
06110 6110.00 43.64 89.80 1385.00 31.00 2200.00
999999.00 13.40 999999.00 171.00 7.30 0.00 999999.00 999999.00 999999.00 7.00 0.00 7.00 0.00 0.00 0.00 9.00 9.00 7.00
07129 7129.00 44.85 84.70 455.00 1.00 0.00
999999.00 20.40 999999.00 39.00 1.50 0.00 999999.00 999999.00 999999.00 7.00 0.00 7.00 0.00 0.00 0.00 9.00 9.00 7.00
07129 7129.00 44.85 84.70 455.00 1.00 100.00
999999.00 24.30 999999.00 67.00 0.90 0.00 999999.00 999999.00 999999.00 7.00 0.00 7.00 0.00 0.00 0.00 9.00 9.00 7.00
07129 7129.00 44.85 84.70 455.00 31.00 2200.00
999999.00 17.60 999999.00 239.00 2.50 0.00 999999.00 999999.00 999999.00 7.00 0.00 7.00 0.00 0.00 0.00 9.00 9.00 7.00
07129 7129.00 44.85 84.70 455.00 1.00 200.00
999999.00 25.00 999999.00 166.00 1.60 0.00 999999.00 999999.00 999999.00 7.00 0.00 7.00 0.00 0.00 0.00 9.00 9.00 7.00
Data extractor¶
A python code is used to extract the desired information from this CIMISS file:
> cd /g5/nwpc_ep8/obsproc/nwprod/decoders
> rm cimiss_data_buoy
> ./read_nmc_cimiss_rsurf_rgwst.py -f /g3/tianwh/share/conobs/rec_RSURF_2019060406_g_06.dat
and
> ./read_nmc_cimiss_rsurf_rgwst.py -f /g3/tianwh/share/conobs/rec_RGWST_2019060406_g_06.dat
# it outputs the file like : gts_buoy_data_201906040600, will be linked as cimiss_data_buoy
If you want to batch process number of CIMISS files, you can use following command:
> # This command will find all CIMISS files and prcessing the file one by one
> rm cimiss_data_buoy
modifiy to :
files = glob.glob(os.path.join(filepath, "rec_RSURF_*"))
> decod_nmc_cimiss_rdrbu.py -d /g3/tianwh/share/conobs
modify to :
files = glob.glob(os.path.join(filepath, "rec_RGWST_*"))
> decod_nmc_cimiss_rdrbu.py -d /g3/tianwh/share/conobs
注解
For rec_RSURF and rec_RGWST data, all scripts have to be run seperately.
The information we want to extract from CIMISS is:
header_line = ff.FortranRecordReader('(A5, 8I8)') id_line = ff.FortranRecordReader('(A8, 6f10.2)') record_line = ff.FortranRecordReader('(18f10.2)') output_line = ff.FortranRecordWriter('(A8, 3f10.2, 5A8, 4f10.2, I8, 4f10.2)') with open(filepath) as fp: line = fp.readline() [RTYPE,yyyy,mon,dd1,hh,num_synop,num_head,num_dat,num_qcm] = header_line.read(line) output = open('gts_data_'+str(yyyy)+str(mon).zfill(2)+str(dd1).zfill(2)+str(hh).zfill(2)+'00', "w") output_buoy = open('gts_buoy_data_'+str(yyyy)+str(mon).zfill(2)+str(dd1).zfill(2)+str(hh).zfill(2)+'00', "w") for station in range(num_synop): line = fp.readline() [call_name, id, lat, lon, elv, day, hm] = id_line.read(line) yyyymmddhhMM = datetime(yyyy, mon, int(day), int(hm/100), int(hm - int(hm/100)*100 )) obstime = datetime(yyyy, mon, int(day), int(hm/100), int(hm - int(hm/100)*100)) line = fp.readline() [p,T,Td,dd,ff,r1,r6,r24,ps,flag_p,flag_T,flag_Td,flag_dd,flag_ff,flag_r1,flag_r6,flag_r24,flag_ps] = record_line.read(line) rmiss = 999999.0 if Td > 9999.0 : Td = rmiss if T > 9999.0 : T = rmiss if r1 > 9999.0 : r1 = rmiss if r6 > 9999.0 : r6 = rmiss if r24 > 9999.0 : r24 = rmiss if p > 9999.0 : p = rmiss if ps > 9999.0 : ps = rmiss if dd > 9999.0 : dd = rmiss if ff > 9999.0 : ff = rmiss if id > 0 and id < 99999.0: output.write(output_line.write([call_name, lat, lon, elv, obstime.strftime("%Y"), obstime.strftime("%m"), \ obstime.strftime("%d"), obstime.strftime("%H"), obstime.strftime("%M"), \ p, ps, T, Td, round(dd), ff, r1, r6, r24]) + "\n") else: output_buoy.write(output_line.write([call_name, lat, lon, elv, obstime.strftime("%Y"), obstime.strftime("%m"), \ obstime.strftime("%d"), obstime.strftime("%H"), obstime.strftime("%M"), \ p, ps, T, Td, round(dd), ff, r1, r6, r24]) + "\n")
the content of cimiss_data_surface is:
> less cimiss_data_buoy Koshigay 35.88 139.76 3.00 2019 07 25 01 00 999999.00 999999.00 28.80 999999.00 0 1.00 999999.00 999999.00 0.00 Numata 36.67 139.02 390.00 2019 07 25 01 00 999999.00 999999.00 28.20 999999.00 135 1.80 999999.00 999999.00 0.00 Yorii 36.10 139.18 128.00 2019 07 25 01 00 999999.00 999999.00 28.00 999999.00 112 1.40 999999.00 999999.00 0.00 Hanno 35.84 139.32 84.00 2019 07 25 01 00 999999.00 999999.00 999999.00 999999.00 999999 999999.00 999999.00 999999.00 0.00 Kamisato 36.38 138.90 183.00 2019 07 25 01 00 999999.00 999999.00 28.90 999999.00 112 1.10 999999.00 999999.00 0.00 Mitsumin 35.93 138.92 975.00 2019 07 25 01 00 999999.00 999999.00 999999.00 999999.00 999999 999999.00 999999.00 999999.00 0.00 Nakanojo 36.59 138.85 354.00 2019 07 25 01 00 999999.00 999999.00 28.40 999999.00 135 1.90 999999.00 999999.00 0.00 Harunasa 36.47 138.87 1088.00 2019 07 25 01 00 999999.00 999999.00 999999.00 999999.00 999999 999999.00 999999.00 999999.00 0.00 Fujiwara 36.86 139.06 700.00 2019 07 25 01 00 999999.00 999999.00 26.10 999999.00 158 1.30 999999.00 999999.00 0.00 Maebashi 36.40 139.06 112.00 2019 07 25 01 00 999999.00 1010.20 28.70 999999.00 135 2.20 999999.00 999999.00 0.00 Kurohone 36.50 139.28 285.00 2019 07 25 01 00 999999.00 999999.00 999999.00 999999.00 999999 999999.00 999999.00 999999.00 0.00 Kanna 36.11 138.90 357.00 2019 07 25 01 00 999999.00 999999.00 28.20 999999.00 68 2.60 999999.00 999999.00 0.00 Abiko 35.86 140.11 20.00 2019 07 25 01 00 999999.00 999999.00 28.90 999999.00 90 0.60 999999.00 999999.00 0.00 Funabash 35.71 140.04 28.00 2019 07 25 01 00 999999.00 999999.00 29.20 999999.00 202 1.60 999999.00 999999.00 0.00 Hatoyama 35.99 139.34 44.00 2019 07 25 01 00 999999.00 999999.00 28.80 999999.00 135 0.90 999999.00 999999.00 0.00 Tateyama 34.99 139.87 6.00 2019 07 25 01 00 999999.00 1011.30 29.50 999999.00 315 2.70 999999.00 999999.00 0.00 Tokoroza 35.77 139.41 119.00 2019 07 25 01 00 999999.00 999999.00 27.30 999999.00 338 0.80 999999.00 999999.00 0.00
Decoder source code¶
Source code directory:
> cd /g5/nwpc_ep8/obsproc/nwprod/decoders/decod_dccimissdrbu/sorc
Subroutines to decode buoy data
dbdcod.f
注解
open the files
open(10, file="../../cimiss_data_buoy", status="old")
read in the records:
DO WHILE ( more ) good = .true. C C* Get next report from bulletin. C C CALL DB_GRPT ( lenb, bulltn, jpos, mszrpt, dburpt, jret) read(10, *, iostat=jret, err=2020) + stnid, xlat, xlong, xelev, iyear, imonth, + imnday, ihour, imins, pmsl, pres, + temperature, td, windd, winds, r1, r6, r24 2020 continue write(dburpt,*) + stnid, xlat, xlong, xelev, iyear, imonth, + imnday, ihour, imins, pmsl, pres, + temperature, td, windd, winds, r1, r6, r24 mszrpt = len(trim(dburpt)) C nszrpt = mszrpt
Initialize array with missing values
C C* Initialize report parameters to missing. C CALL DB_INIT ( jret )Fill in observations
C* Save report ID. civals ( icstid ) = stnid C* It is an automatic station. C rivals ( irtost ) = 0.0 C irptdt(1) = iyear irptdt(2) = imonth irptdt(3) = imnday irptdt(4) = ihour irptdt(5) = imins C* Save date/time data interface array C rivals(iryear) = float ( irptdt(1) ) rivals(irmnth) = float ( irptdt(2) ) rivals(irdays) = float ( irptdt(3) ) rivals(irhour) = float ( irptdt(4) ) rivals(irminu) = float ( irptdt(5) ) C* Station dictionary location, elevation, latitude, C* longitude rivals ( irselv ) = xelev rivals ( irslat ) = xlat rivals ( irslon ) = xlong C* Get indicator for source and units of wind speed C* wind speed indicator * C* (WMO Code Table 1855) rivals ( irisws ) = FLOAT ( 1 ) .... .... if ( temperature .lt. 999999.0 ) + rivals ( irtmpc ) = temperature if ( pmsl .lt. 999999.0 ) + rivals ( irpmsl ) = pmsl if ( pres .lt. 999999.0 ) + rivals ( irpres ) = pres if ( td .lt. 999999.0 ) + rivals ( irdwpc ) = td if ( winds .lt. 999999.0 ) + rivals ( irsped ) = winds if ( windd .lt. 999999 ) + rivals ( irdrct ) = float ( windd )Make sure it read all observations before and after nhours
C* Report time for BUFR must not be more than nhours C* before the system time, and not more than C* 60 minutes after. C IF ( ( ier1 .ne. 0 ) .or. ( imdif .gt. nhours * 60 ) + .or. ( imdif .lt. -60 * nhours ) ) THEN
注解
- The path and file name of
cimiss_data_buoyfile are hard coded in the subroutines.
4. Compile the code
> make
Decode and convert to BUFR format¶
- enter into the exec directory:
> cd /g5/nwpc_ep8/obsproc/nwprod/decoders/decod_dccimissdrbu/exec [nwpc_ep8@login_a05 exec]$ ls -la 总用量 14090 drwxr-xr-x 3 nwpc_ep8 nwpep 4096 3月 19 20:54 . drwxr-xr-x 4 nwpc_ep8 nwpep 4096 3月 19 19:34 .. lrwxr-xr-x 1 nwpc_ep8 nwpep 34 3月 19 19:47 bufrtab.001 -> ../../decod_shared/fix/bufrtab.001 -rwxr-xr-x 1 nwpc_ep8 nwpep 877512 3月 19 20:36 decod_dccimissdrbu -rw-r--r-- 1 nwpc_ep8 nwpep 13538011 3月 19 20:51 decod_dccimissdrbu.log -rwxr-xr-x 1 nwpc_ep8 nwpep 533 3月 19 20:44 run.ksh drwxr-xr-x 2 nwpc_ep8 nwpep 4096 3月 19 20:47 tmp
2. run the decoder script
> run.ksh
> cat run.ksh
!/bin/bash
export DBNBUFRT=120
export TRANJB=/g5/nwpc_ep8/obsproc/nwprod/ush/tranjb
export tank_dir=/g5/nwpc_ep8/obsproc/nwprod/dcom/us007003
export DBNROOT=`pwd`
rm tmp/*
rm decod_dccimissdrbu.log
./decod_dccimissdrbu -v 3 -b 240 -d decod_dccimissdrbu.log -c $1 bufrtab.001
ls -la tmp/*
BUFR_FILES=$(echo tmp/BUFR*)
echo ${BUFR_FILES}
for file in ${BUFR_FILES}
do
${TRANJB} ${tank_dir} ${file}
done
注解
- -v 3 verbose level
- -c $1 : Set the current time (201809011600) used to calculate the time departures of the obs. data.
- -b 240 : Number of hours to decode prior to “current” time (default)
- The observations with date/time between current time - 240 hours and current time + 3 are kept.
4. The generated BUFR format file will be saved at
> ls -la tmp
-rw-rw-r-- 1 nwpc_ep8 nwpep 1599432 3月 19 21:02 BUFR.0.drbu.1.87459.1584651752.88
Transfer bufr data to BUFR Tanks¶
put data in BUFR tanks:
> /g5/nwpc_ep8/obsproc/nwprod/ush/tranjb /g5/nwpc_ep8/obsproc/nwprod/dcom/us007003 tmp/BUFR.0.drbu.1.87459.1584651752.88 > ls -al /g5/nwpc_ep8/obsproc/nwprod/dcom/us007003/20180901/b001/xx002 -rw-r--r-- 1 vagrant vagrant 4235328 Sep 27 04:42 /g5/nwpc_ep8/obsproc/nwprod/dcom/us007003/20180901/b001/xx002
注解
- if environmental variable SCREEN=ON :
- Define Run Time is the system time when the tranjb is running.
- Only observations with date/time between Run Time - 10 days and Run Time + 12 hours are kept.
for retrospective run, set SCREEN=OFF
/g5/nwpc_ep8/obsproc/nwprod/dcom/us007003/yyyymmdd/bmmm/xxsss(where mmm is WMO BUFR message type and xxx is local BUFR message subtype)001.002 (in dump group mnemonic sfcshp): Ship Buoy
BUFR format
Arranged by UTC day and continuously grow throughout the day, if you run decoders many time, the content of the file will grow
No QC (other than rudimentary checks inside decoders)
No duplicate checking
Interested users can use utility
debufrto check the content of the bufr file:> /g5/nwpc_ep8/obsproc/nwprod/util/exec/debufr /g5/nwpc_ep8/obsproc/nwprod/dcom/us007003/20180901/b001/xx002the output is in
debufr.out.