【发布时间】:2020-12-22 07:56:01
【问题描述】:
我从 Chirps 获取 tif.gz 格式的数据,我尝试R.utils::gunzip 获取地图,但出现错误。
file<-"./chirps-v2.0.1981.01.01.tif.gz"
R.utils::gunzip(file,remove=F)
错误:
Error in readBin(inn, what = raw(0L), size = 1L, n = BFR.SIZE) :
error reading from the connection
In addition: Warning message:
In readBin(inn, what = raw(0L), size = 1L, n = BFR.SIZE) :
invalid or incomplete compressed data
如果解压缩这些文件有更好的替代方案,那将是一个很好的解决方案。提前谢谢你。
我试过这些,但没有用 R: read GeoTiff from gz file with a connection and raster package Decompress gz file using R
【问题讨论】:
-
这表明文件已损坏。我会再次下载它,确保您没有获得缓存版本。