fix: 修复HLS处理中坐标系复制逻辑错误.
This commit is contained in:
parent
0d3f6e212c
commit
517d190c0e
@ -92,9 +92,9 @@ def open_hls(
|
||||
# (Add) 缩放计算后会丢源属性和坐标系, 需要复制源数据坐标系与属性
|
||||
# 先根据是否裁剪情况判断需要复制的坐标系
|
||||
if clip:
|
||||
da.rio.write_crs(da_org.rio.crs, inplace=True)
|
||||
else:
|
||||
da.rio.write_crs(roi.crs, inplace=True)
|
||||
else:
|
||||
da.rio.write_crs(da_org.rio.crs, inplace=True)
|
||||
# 再复制源数据属性
|
||||
da.attrs = da_org.attrs.copy()
|
||||
da.attrs["scale_factor"] = 1.0
|
||||
|
Loading…
x
Reference in New Issue
Block a user