汇流运行记录

2023-11-07 06:38
文章标签 运行 记录 汇流

本文主要是介绍汇流运行记录,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

运行汇流文件:

[root@Liuy /home/VIC_hanjiang/rout]# rout /home/VIC_hanjiang/rout/rout_input.STEHENDAY =          365  NMONTHS =           121  STEHE                  35 139Routing station: STEHEsearching catchment...Number of grid cells upstream of present station          16reading grid_UH...making grid UH...making UH_S grid...it takes a while...NOTE:  your new UH_S grid file will be written in thedirectory you run from, and will be calledSTEHE.uh_ssave this file and specify it in your stationlocation file to avoid this step in the futureAt line 90 of file unit_hyd_routines.f (unit = 98)Fortran runtime error: Cannot open file 'STEHE.uh_s': File exists

2020.02.08已制作好汇流所需参数:

[root@Liuy /home/VIC_Routing-1.1_Fortran/samp_inputs]# rout /home/VIC_hanjiang/rout/rout_input.STEHENDAY =          365  NMONTHS =           121  XUNHE                  34  15Routing station: XUNHEsearching catchment...Number of grid cells upstream of present station          62reading grid_UH...making grid UH...making UH_S grid...it takes a while...NOTE:  your new UH_S grid file will be written in thedirectory you run from, and will be calledXUNHE.uh_ssave this file and specify it in your stationlocation file to avoid this step in the futuregrid cell           1  out of          62grid cell           2  out of          62grid cell           3  out of          62grid cell           4  out of          62grid cell           5  out of          62grid cell           6  out of          62grid cell           7  out of          62grid cell           8  out of          62grid cell           9  out of          62grid cell          10  out of          62grid cell          11  out of          62grid cell          12  out of          62grid cell          13  out of          62grid cell          14  out of          62grid cell          15  out of          62grid cell          16  out of          62grid cell          17  out of          62grid cell          18  out of          62grid cell          19  out of          62grid cell          20  out of          62grid cell          21  out of          62grid cell          22  out of          62grid cell          23  out of          62grid cell          24  out of          62grid cell          25  out of          62grid cell          26  out of          62grid cell          27  out of          62grid cell          28  out of          62grid cell          29  out of          62grid cell          30  out of          62grid cell          31  out of          62grid cell          32  out of          62grid cell          33  out of          62grid cell          34  out of          62grid cell          35  out of          62grid cell          36  out of          62grid cell          37  out of          62grid cell          38  out of          62grid cell          39  out of          62grid cell          40  out of          62grid cell          41  out of          62grid cell          42  out of          62grid cell          43  out of          62grid cell          44  out of          62grid cell          45  out of          62grid cell          46  out of          62grid cell          47  out of          62grid cell          48  out of          62grid cell          49  out of          62grid cell          50  out of          62grid cell          51  out of          62grid cell          52  out of          62grid cell          53  out of          62grid cell          54  out of          62grid cell          55  out of          62grid cell          56  out of          62grid cell          57  out of          62grid cell          58  out of          62grid cell          59  out of          62grid cell          60  out of          62grid cell          61  out of          62grid cell          62  out of          62making convolution.../home/VIC_hanjiang/results/fluxes_32.8262_109.3981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_32.9262_109.3981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.0262_109.3981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.1262_109.3981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.2262_109.3981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_32.8262_109.2981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_32.9262_109.2981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.0262_109.2981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.1262_109.2981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.2262_109.2981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.3262_109.2981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.4262_109.2981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_32.9262_109.1981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.0262_109.1981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.1262_109.1981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.2262_109.1981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.3262_109.1981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.4262_109.1981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.5262_109.1981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.0262_109.0981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.1262_109.0981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.2262_109.0981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.3262_109.0981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.4262_109.0981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.5262_109.0981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.1262_108.9981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.2262_108.9981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.3262_108.9981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.4262_108.9981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.5262_108.9981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.6262_108.9981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.1262_108.8981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.2262_108.8981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.3262_108.8981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.4262_108.8981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.5262_108.8981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.6262_108.8981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.7262_108.8981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.3262_108.7981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.4262_108.7981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.5262_108.7981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.6262_108.7981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.7262_108.7981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.8262_108.7981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.3262_108.6981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.4262_108.6981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.5262_108.6981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.6262_108.6981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.7262_108.6981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.8262_108.6981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.5262_108.5981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.6262_108.5981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.7262_108.5981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.8262_108.5981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.5262_108.4981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.6262_108.4981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.7262_108.4981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.8262_108.4981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.6262_108.3981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.7262_108.3981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.6262_108.2981 NOT FOUND, INSERTING ZEROS/home/VIC_hanjiang/results/fluxes_33.7262_108.2981 NOT FOUND, INSERTING ZEROS62  files not found, zero runoff/baseflow usedwriting data...
At line 21 of file write_routines.f (unit = 30)
Fortran runtime error: Cannot open file '/vic/VIC_hanjiang/rout/results/XUNHE.day': No such file or directory

报错:

1.径流量输出文件带有.txt后缀;

解决方案(R):

##提取全部文件名并转为向量格式
path <- "C:/Users/Liuy/Documents/results"f1 <- dir(path)
f2 <- as.character(f1)
f2##批量替换!gsub()可以用于字段的删减、增补、替换和切割,可以处理一个字段也可以处理由字段组成的向量。
##具体的使用方法为:gsub("目标字符", "替换字符", 对象)f2 <- gsub(".txt","",f2)
f2##源文件夹文件重命名
##由于f1是dir()直接赋值过来,因此其代表了系统文件名,而f1的顺序与f2一一对应,仅仅是对字符串进行了查找替换操作,因此可以放心利用file.rename()重命名文件file.rename(f1, f2) #函数形式为file.rename(from, to),from为原始文件名向量,to为新的文件名向量

2.自动识别出的经纬度坐标与径流输出经纬度不匹配(参数文件问题)制作的文件存在偏移

如:

改为0480即匹配在一起了。

更改后:

[root@Liuy /home/VIC_Routing-1.1_Fortran/samp_inputs]# rout /home/VIC_hanjiang/rout/rout_input.STEHENDAY =          365  NMONTHS =           121  XUNHE                  34  15Routing station: XUNHEsearching catchment...Number of grid cells upstream of present station          62reading grid_UH...making grid UH...making UH_S grid...it takes a while...NOTE:  your new UH_S grid file will be written in thedirectory you run from, and will be calledXUNHE.uh_ssave this file and specify it in your stationlocation file to avoid this step in the future
At line 90 of file unit_hyd_routines.f (unit = 98)
Fortran runtime error: Cannot open file 'XUNHE.uh_s': File exists

这是由于在站点文件中默认不存在站点单位线文件,程序会根据一套算法计算出单位先,然后保存为xxx.uh_s文件。

所以下次计算的时候就可以将上次生成的单位线文件直接拿过来用,不过需要在站点文件中将NONE更改为单位线文件位置,从而缩短计算时间。

发现其跑到了VIC_routing示例文件中,这是由于生成的单位线文件自动写入当前运行文件夹。在VIC_hanjiang/rout下运行即可。

 

 



 

[root@Liuy /home/VIC_hanjiang/rout]# rout /home/VIC_hanjiang/rout/rout_input.STEHENDAY =          365  NMONTHS =           121  XUNHE                  34  15Routing station: XUNHEsearching catchment...Number of grid cells upstream of present station          62reading grid_UH...making grid UH...making UH_S grid...it takes a while...NOTE:  your new UH_S grid file will be written in thedirectory you run from, and will be calledXUNHE.uh_ssave this file and specify it in your stationlocation file to avoid this step in the futuregrid cell           1  out of          62grid cell           2  out of          62grid cell           3  out of          62grid cell           4  out of          62grid cell           5  out of          62grid cell           6  out of          62grid cell           7  out of          62grid cell           8  out of          62grid cell           9  out of          62grid cell          10  out of          62grid cell          11  out of          62grid cell          12  out of          62grid cell          13  out of          62grid cell          14  out of          62grid cell          15  out of          62grid cell          16  out of          62grid cell          17  out of          62grid cell          18  out of          62grid cell          19  out of          62grid cell          20  out of          62grid cell          21  out of          62grid cell          22  out of          62grid cell          23  out of          62grid cell          24  out of          62grid cell          25  out of          62grid cell          26  out of          62grid cell          27  out of          62grid cell          28  out of          62grid cell          29  out of          62grid cell          30  out of          62grid cell          31  out of          62grid cell          32  out of          62grid cell          33  out of          62grid cell          34  out of          62grid cell          35  out of          62grid cell          36  out of          62grid cell          37  out of          62grid cell          38  out of          62grid cell          39  out of          62grid cell          40  out of          62grid cell          41  out of          62grid cell          42  out of          62grid cell          43  out of          62grid cell          44  out of          62grid cell          45  out of          62grid cell          46  out of          62grid cell          47  out of          62grid cell          48  out of          62grid cell          49  out of          62grid cell          50  out of          62grid cell          51  out of          62grid cell          52  out of          62grid cell          53  out of          62grid cell          54  out of          62grid cell          55  out of          62grid cell          56  out of          62grid cell          57  out of          62grid cell          58  out of          62grid cell          59  out of          62grid cell          60  out of          62grid cell          61  out of          62grid cell          62  out of          62making convolution...1  of          62 : /home/VIC_hanjiang/results/fluxes_32.8262_109.3980Error reading time-series data, insufficient data or missing input file/home/VIC_hanjiang/results/fluxes_32.8262_109.3980writing data...
At line 21 of file write_routines.f (unit = 30)
Fortran runtime error: Cannot open file '/vic/VIC_hanjiang/rout/results/XUNHE.day': No such file or directory

径流输出文件内容与汇流模型不匹配。

原因,径流输出自带解释行和标题行,汇流模型无法识别。

VIC_4中可在全局参数output部分设置:

PRT_HEADER 为FALSE

从而实现输出结果不保留解释文件与头文件。但是VIC_5中将其弃用:

[root@Liuy /home/VIC_hanjiang/rout]# vic_classic.exe -g/home/VIC_hanjiang/parameters/global_param.hanjiang.txt
---------------------------------------------------------------------------
Traceback (most recent call last):
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf0) [0x7fd191940830]
vic_classic.exe() [0x44eafa]
vic_classic.exe() [0x457bf9]
[ERROR] ./src/get_global_param.c:663: errno: None: PRT_HEADER has been deprecated. All output files include a header including pertinent metadata.

解决方案:批量去除径流模型输出前三行(R)。

LINUX_bash

[root@Liuy /home/VIC_hanjiang/results]# for i in `ls`;do sed -i '1,3d' $i;done

使用sed命令,sed -i表示将改动直接写入到原文件里。‘1,3d’表示删除1-3行。

 



[root@Liuy /home/VIC_hanjiang/rout]#  rout /home/VIC_hanjiang/rout/rout_input.STEHENDAY =          365  NMONTHS =           121  XUNHE                  34  15Routing station: XUNHEsearching catchment...Number of grid cells upstream of present station          62reading grid_UH...making grid UH...reading UH_S grid from filemaking convolution...1  of          62 : /home/VIC_hanjiang/results/fluxes_32.8262_109.39802  of          62 : /home/VIC_hanjiang/results/fluxes_32.9262_109.39803  of          62 : /home/VIC_hanjiang/results/fluxes_33.0262_109.39804  of          62 : /home/VIC_hanjiang/results/fluxes_33.1262_109.39805  of          62 : /home/VIC_hanjiang/results/fluxes_33.2262_109.39806  of          62 : /home/VIC_hanjiang/results/fluxes_32.8262_109.2980
......58  of          62 : /home/VIC_hanjiang/results/fluxes_33.8262_108.498059  of          62 : /home/VIC_hanjiang/results/fluxes_33.6262_108.398060  of          62 : /home/VIC_hanjiang/results/fluxes_33.7262_108.398061  of          62 : /home/VIC_hanjiang/results/fluxes_33.6262_108.298062  of          62 : /home/VIC_hanjiang/results/fluxes_33.7262_108.2980writing data...
At line 21 of file write_routines.f (unit = 30)
Fortran runtime error: Cannot open file '/vic/VIC_hanjiang/rout/results/XUNHE.day': No such file or directory

原因:全局文件中路径打错啦!!!

应该是/home/VIC_hanjiang/rout/results/

汇流模块会自动写入各种(逐日,月)汇流结果。



[root@Liuy /home/VIC_hanjiang/rout/results]# rout /home/VIC_hanjiang/rout/rout_input.STEHENDAY =          365  NMONTHS =           121  XUNHE                  34  15Routing station: XUNHEsearching catchment...Number of grid cells upstream of present station          62reading grid_UH...making grid UH...reading UH_S grid from filemaking convolution...1  of          62 : /home/VIC_hanjiang/results/fluxes_32.8262_109.39802  of          62 : /home/VIC_hanjiang/results/fluxes_32.9262_109.3980
......57  of          62 : /home/VIC_hanjiang/results/fluxes_33.7262_108.498058  of          62 : /home/VIC_hanjiang/results/fluxes_33.8262_108.498059  of          62 : /home/VIC_hanjiang/results/fluxes_33.6262_108.398060  of          62 : /home/VIC_hanjiang/results/fluxes_33.7262_108.398061  of          62 : /home/VIC_hanjiang/results/fluxes_33.6262_108.298062  of          62 : /home/VIC_hanjiang/results/fluxes_33.7262_108.2980writing data...1  YOUFG                  47  15Routing station: YOUFGsearching catchment...Number of grid cells upstream of present station         669reading grid_UH...making grid UH...making UH_S grid...it takes a while...NOTE:  your new UH_S grid file will be written in thedirectory you run from, and will be calledYOUFG.uh_ssave this file and specify it in your stationlocation file to avoid this step in the futuregrid cell           1  out of         669grid cell           2  out of         669grid cell           3  out of         669grid cell           4  out of         669......grid cell         662  out of         669grid cell         663  out of         669grid cell         664  out of         669grid cell         665  out of         669grid cell         666  out of         669grid cell         667  out of         669grid cell         668  out of         669grid cell         669  out of         669making convolution...1  of         669 : /home/VIC_hanjiang/results/fluxes_32.4262_110.69802  of         669 : /home/VIC_hanjiang/results/fluxes_32.7262_110.69803  of         669 : /home/VIC_hanjiang/results/fluxes_32.8262_110.6980
......663  of         669 : /home/VIC_hanjiang/results/fluxes_33.5262_106.3980664  of         669 : /home/VIC_hanjiang/results/fluxes_33.6262_106.3980665  of         669 : /home/VIC_hanjiang/results/fluxes_32.9262_106.2980666  of         669 : /home/VIC_hanjiang/results/fluxes_33.2262_106.2980667  of         669 : /home/VIC_hanjiang/results/fluxes_33.3262_106.2980668  of         669 : /home/VIC_hanjiang/results/fluxes_33.4262_106.2980669  of         669 : /home/VIC_hanjiang/results/fluxes_33.5262_106.2980writing data...1  JINZG                  51  19Routing station: JINZGsearching catchment...Number of grid cells upstream of present station          89reading grid_UH...making grid UH...making UH_S grid...it takes a while...NOTE:  your new UH_S grid file will be written in thedirectory you run from, and will be calledJINZG.uh_ssave this file and specify it in your stationlocation file to avoid this step in the futuregrid cell           1  out of          89grid cell           2  out of          89grid cell           3  out of          89grid cell           4  out of          89
......grid cell          85  out of          89grid cell          86  out of          89grid cell          87  out of          89grid cell          88  out of          89grid cell          89  out of          89making convolution...1  of          89 : /home/VIC_hanjiang/results/fluxes_33.4262_111.29802  of          89 : /home/VIC_hanjiang/results/fluxes_33.5262_111.29803  of          89 : /home/VIC_hanjiang/results/fluxes_33.3262_111.1980
......85  of          89 : /home/VIC_hanjiang/results/fluxes_33.9262_109.698086  of          89 : /home/VIC_hanjiang/results/fluxes_34.0262_109.698087  of          89 : /home/VIC_hanjiang/results/fluxes_34.1262_109.698088  of          89 : /home/VIC_hanjiang/results/fluxes_33.9262_109.598089  of          89 : /home/VIC_hanjiang/results/fluxes_34.0262_109.5980writing data...1  DANJA                  55  16Routing station: DANJAsearching catchment...Number of grid cells upstream of present station         147reading grid_UH...making grid UH...making UH_S grid...it takes a while...NOTE:  your new UH_S grid file will be written in thedirectory you run from, and will be calledDANJA.uh_ssave this file and specify it in your stationlocation file to avoid this step in the futuregrid cell           1  out of         147grid cell           2  out of         147grid cell           3  out of         147
......grid cell         142  out of         147grid cell         143  out of         147grid cell         144  out of         147grid cell         145  out of         147grid cell         146  out of         147grid cell         147  out of         147making convolution...1  of         147 : /home/VIC_hanjiang/results/fluxes_33.5262_111.79802  of         147 : /home/VIC_hanjiang/results/fluxes_33.6262_111.7980
......144  of         147 : /home/VIC_hanjiang/results/fluxes_34.0262_109.6980145  of         147 : /home/VIC_hanjiang/results/fluxes_34.1262_109.6980146  of         147 : /home/VIC_hanjiang/results/fluxes_33.9262_109.5980147  of         147 : /home/VIC_hanjiang/results/fluxes_34.0262_109.5980writing data...1  HANJA                  51  14Routing station: HANJAsearching catchment...Number of grid cells upstream of present station         697reading grid_UH...making grid UH...making UH_S grid...it takes a while...NOTE:  your new UH_S grid file will be written in thedirectory you run from, and will be calledHANJA.uh_ssave this file and specify it in your stationlocation file to avoid this step in the futuregrid cell           1  out of         697grid cell           2  out of         697
......grid cell         688  out of         697grid cell         689  out of         697grid cell         690  out of         697grid cell         691  out of         697grid cell         692  out of         697grid cell         693  out of         697grid cell         694  out of         697grid cell         695  out of         697grid cell         696  out of         697grid cell         697  out of         697making convolution...1  of         697 : /home/VIC_hanjiang/results/fluxes_32.7262_111.19802  of         697 : /home/VIC_hanjiang/results/fluxes_32.8262_111.1980......694  of         697 : /home/VIC_hanjiang/results/fluxes_33.2262_106.2980695  of         697 : /home/VIC_hanjiang/results/fluxes_33.3262_106.2980696  of         697 : /home/VIC_hanjiang/results/fluxes_33.4262_106.2980697  of         697 : /home/VIC_hanjiang/results/fluxes_33.5262_106.2980writing data...1  ZONGK                  56  15Routing station: ZONGKsearching catchment...Number of grid cells upstream of present station         871reading grid_UH...making grid UH...making UH_S grid...it takes a while...NOTE:  your new UH_S grid file will be written in thedirectory you run from, and will be calledZONGK.uh_ssave this file and specify it in your stationlocation file to avoid this step in the futuregrid cell           1  out of         871grid cell           2  out of         871grid cell           3  out of         871
......grid cell         866  out of         871grid cell         867  out of         871grid cell         868  out of         871grid cell         869  out of         871grid cell         870  out of         871grid cell         871  out of         871making convolution...1  of         871 : /home/VIC_hanjiang/results/fluxes_33.5262_111.79802  of         871 : /home/VIC_hanjiang/results/fluxes_33.6262_111.7980
......866  of         871 : /home/VIC_hanjiang/results/fluxes_33.6262_106.3980867  of         871 : /home/VIC_hanjiang/results/fluxes_32.9262_106.2980868  of         871 : /home/VIC_hanjiang/results/fluxes_33.2262_106.2980869  of         871 : /home/VIC_hanjiang/results/fluxes_33.3262_106.2980870  of         871 : /home/VIC_hanjiang/results/fluxes_33.4262_106.2980871  of         871 : /home/VIC_hanjiang/results/fluxes_33.5262_106.2980writing data...
Note: The following floating-point exceptions are signalling: IEEE_INVALID_FLAG IEEE_UNDERFLOW_FLAG IEEE_DENORMAL

一顿搜索后发现可能是由于汇流编写使用Fortran70,而现在使用95的原因。(其实并不影响输出结果!!)

暂且不管。由于Fortran编写的不太稳定。

这里使用大神(再次膜拜)自己用c编写的汇流程序。https://github.com/Sibada/CRout

[root@Liuy ~]# crout /home/VIC_hanjiang/rout/rout_input.STEHE
CRout Direction format: defaultFlow direction file:         /home/VIC_hanjiang/rout/STEHE.fdirFlow velocity file:  .false.Diffusion file:      1.50Fraction file:        .false.Station location file         800VIC output path       .false.     11111 decimal places.--Runoff data at column 0 and 1Routing output path   .true.Error: routing calculating date format incorrect: /home/VIC_hanjiang/rout/STEHE.fract

发现VIC output path怎么是.false 111 

说明CRout输入参数读取顺序与原有的不匹配。需检查src/crout.cpp中的读取顺序。



[root@Liuy ~]# crout /home/VIC_hanjiang/rout/rout_input.STEHE
CRout Direction format: defaultFlow direction file:         /home/VIC_hanjiang/rout/STEHE.fdirFlow velocity file:  uniform value 1.5Diffusion file:      uniform value 800Fraction file:        /home/VIC_hanjiang/rout/STEHE.fractStation location file         /home/VIC_hanjiang/rout/STEHE.stnlocVIC output path       /home/VIC_hanjiang/results/fluxes_     4 decimal places.--Runoff data at column 0 and 1Routing output path   /home/VIC_hanjiang/rout/results/Slope UH file /home/VIC_hanjiang/rout/UH.allTime period of routing calculation:      1990-1-1 -> 1990-12-31Time period of output data:              1990-1-1 -> 1990-12-31-----Station: XUNHE, location: 34,15 -----------------------> Reading station UH file...-> Grids num of current basin: 61-> Routing calculating...Warning: VIC output file /home/VIC_hanjiang/results/fluxes_31.3262_105.9980 not found.corresponding value will be set to zero.
Segmentation fault (core dumped)

报错气象文件未发现,但是报错的 fluxes_31.3262_105.9980位置不在研究区内,说明其汇流地理位置的计算和Fortran的不一致?并不是!

只是由于本次运行使用了fortran制作的站点单位线文件,而c制作的单位线文件每一行前两个字符增加了网格位置,因此使用fortran制作的单位线文件来运行crout将会读入错误信息,需要重新制作单位线文件。将其保存在/home/CRout-master/中。

[root@Liuy /home/CRout-master]# crout /home/VIC_hanjiang/rout/rout_input.STEHE
CRout Direction format: defaultFlow direction file:         /home/VIC_hanjiang/rout/STEHE.fdirFlow velocity file:  uniform value 1.5Diffusion file:      uniform value 800Fraction file:        /home/VIC_hanjiang/rout/STEHE.fractStation location file         /home/VIC_hanjiang/rout/STEHE.stnlocVIC output path       /home/VIC_hanjiang/results/fluxes_     4 decimal places.--Runoff data at column 3 and 4Routing output path   /home/VIC_hanjiang/rout/results/Slope UH file /home/VIC_hanjiang/rout/UH.allTime period of routing calculation:      1990-1-1 -> 1990-12-31Time period of output data:              1990-1-1 -> 1990-12-31ncol is 58nrow is 29xll is 106.048yll is 31.3762csize is 0.1-----Station: XUNHE, location: 34,15 -----------------------> Reading station UH file...-> Grids num of current basin: 62-> Routing calculating...- Grid 1/62 complete.- Grid 2/62 complete.- Grid 3/62 complete.
......- Grid 61/62 complete.- Grid 62/62 complete.-> Writing routing simulation data per day...-> Writing routing simulation data per month...-----Station: YOUFG, location: 47,15 -----------------------> Reading station UH file...-> Grids num of current basin: 669-> Routing calculating...- Grid 6/669 complete.- Grid 12/669 complete.- Grid 18/669 complete.- Grid 24/669 complete.
......- Grid 660/669 complete.- Grid 666/669 complete.-> Writing routing simulation data per day...-> Writing routing simulation data per month...-----Station: JINZG, location: 51,19 -----------------------> Reading station UH file...-> Grids num of current basin: 89-> Routing calculating...- Grid 1/89 complete.- Grid 2/89 complete.- Grid 3/89 complete.- Grid 4/89 complete.- Grid 5/89 complete.- Grid 6/89 complete.- Grid 7/89 complete.
......- Grid 88/89 complete.- Grid 89/89 complete.-> Writing routing simulation data per day...-> Writing routing simulation data per month...-----Station: DANJA, location: 55,16 -----------------------> Reading station UH file...-> Grids num of current basin: 147-> Routing calculating...- Grid 1/147 complete.- Grid 2/147 complete.- Grid 3/147 complete.- Grid 4/147 complete.
......- Grid 145/147 complete.- Grid 146/147 complete.- Grid 147/147 complete.-> Writing routing simulation data per day...-> Writing routing simulation data per month...-----Station: HANJA, location: 51,14 -----------------------> Reading station UH file...-> Grids num of current basin: 697-> Routing calculating...- Grid 6/697 complete.- Grid 12/697 complete.- Grid 18/697 complete.- Grid 24/697 complete.- Grid 30/697 complete.
......- Grid 678/697 complete.- Grid 684/697 complete.- Grid 690/697 complete.- Grid 696/697 complete.-> Writing routing simulation data per day...-> Writing routing simulation data per month...-----Station: ZONGK, location: 56,15 -----------------------> Reading station UH file...-> Grids num of current basin: 871-> Routing calculating...- Grid 8/871 complete.- Grid 16/871 complete.- Grid 24/871 complete.
......- Grid 848/871 complete.- Grid 856/871 complete.- Grid 864/871 complete.-> Writing routing simulation data per day...-> Writing routing simulation data per month...Done. (4s costs)

运行成功!

汇流结果:(具体单位??)

DAY和MONTH文件(应该是平均径流量)——每月的值等于该月每天值求和后平均

DAY_MM和MONTH_MM文件——每月的值等于该月每天值求和

 

这篇关于汇流运行记录的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/361897

相关文章

SpringBoot3应用中集成和使用Spring Retry的实践记录

《SpringBoot3应用中集成和使用SpringRetry的实践记录》SpringRetry为SpringBoot3提供重试机制,支持注解和编程式两种方式,可配置重试策略与监听器,适用于临时性故... 目录1. 简介2. 环境准备3. 使用方式3.1 注解方式 基础使用自定义重试策略失败恢复机制注意事项

Python UV安装、升级、卸载详细步骤记录

《PythonUV安装、升级、卸载详细步骤记录》:本文主要介绍PythonUV安装、升级、卸载的详细步骤,uv是Astral推出的下一代Python包与项目管理器,主打单一可执行文件、极致性能... 目录安装检查升级设置自动补全卸载UV 命令总结 官方文档详见:https://docs.astral.sh/

统一返回JsonResult踩坑的记录

《统一返回JsonResult踩坑的记录》:本文主要介绍统一返回JsonResult踩坑的记录,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,望不吝赐教... 目录统一返回jsonResult踩坑定义了一个统一返回类在使用时,JsonResult没有get/set方法时响应总结统一返回

Go学习记录之runtime包深入解析

《Go学习记录之runtime包深入解析》Go语言runtime包管理运行时环境,涵盖goroutine调度、内存分配、垃圾回收、类型信息等核心功能,:本文主要介绍Go学习记录之runtime包的... 目录前言:一、runtime包内容学习1、作用:① Goroutine和并发控制:② 垃圾回收:③ 栈和

java对接海康摄像头的完整步骤记录

《java对接海康摄像头的完整步骤记录》在Java中调用海康威视摄像头通常需要使用海康威视提供的SDK,下面这篇文章主要给大家介绍了关于java对接海康摄像头的完整步骤,文中通过代码介绍的非常详细,需... 目录一、开发环境准备二、实现Java调用设备接口(一)加载动态链接库(二)结构体、接口重定义1.类型

Java -jar命令如何运行外部依赖JAR包

《Java-jar命令如何运行外部依赖JAR包》在Java应用部署中,java-jar命令是启动可执行JAR包的标准方式,但当应用需要依赖外部JAR文件时,直接使用java-jar会面临类加载困... 目录引言:外部依赖JAR的必要性一、问题本质:类加载机制的限制1. Java -jar的默认行为2. 类加

java -jar命令运行 jar包时运行外部依赖jar包的场景分析

《java-jar命令运行jar包时运行外部依赖jar包的场景分析》:本文主要介绍java-jar命令运行jar包时运行外部依赖jar包的场景分析,本文给大家介绍的非常详细,对大家的学习或工作... 目录Java -jar命令运行 jar包时如何运行外部依赖jar包场景:解决:方法一、启动参数添加: -Xb

apache的commons-pool2原理与使用实践记录

《apache的commons-pool2原理与使用实践记录》ApacheCommonsPool2是一个高效的对象池化框架,通过复用昂贵资源(如数据库连接、线程、网络连接)优化系统性能,这篇文章主... 目录一、核心原理与组件二、使用步骤详解(以数据库连接池为例)三、高级配置与优化四、典型应用场景五、注意事

eclipse如何运行springboot项目

《eclipse如何运行springboot项目》:本文主要介绍eclipse如何运行springboot项目问题,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,望不吝赐教... 目js录当在eclipse启动spring boot项目时出现问题解决办法1.通过cmd命令行2.在ecl

SpringBoot实现文件记录日志及日志文件自动归档和压缩

《SpringBoot实现文件记录日志及日志文件自动归档和压缩》Logback是Java日志框架,通过Logger收集日志并经Appender输出至控制台、文件等,SpringBoot配置logbac... 目录1、什么是Logback2、SpringBoot实现文件记录日志,日志文件自动归档和压缩2.1、