juniorjliu的个人博客分享 http://blog.sciencenet.cn/u/juniorjliu

博文

MODIS MRT批处理备忘

已有 6082 次阅读 2010-3-9 21:36 |个人分类:科研笔记|系统分类:科研笔记|关键词:遥感| 遥感

rem Set the MRT_HOME environmental var to the MRT installation directory.

set MRT_HOME=D:Modis

rem Set the MRTDATADIR environmental var to the MRT data directory.

set MRTDATADIR=D:Modisdata

rem Set the PATH environment variable to include the MRT executables.

set Path=%MRT_HOME%bin;%Path%

dir d:2008_lst_nationmod11a2.a2008*.hdf /s/b > 2008_lst_nation.txt

for /f "tokens=4,5,7 delims=:." %%i in (2008_lst_nation.txt) do @echo d:2008_lst_nationmod11A2.%%i.%%j.005.%%k.hdf >> %%i.txt

dir a2008*.txt /s/b > tmp.txt

for /f "tokens=3 delims=:." %%i in (tmp.txt) do @echo %%i >> list.txt

for /f %%i in (list.txt) do prm.bat %%i

 

 

 

%MRT_HOME%binmrtmosaic -i %1.txt -o %1.hdf -s "1 1 1 1 1 1 1 1 1 1 1 1 "

@echo INPUT_FILENAME = D:2008_lst_nation_tif%1.hdf >> %1.prm

@echo SPECTRAL_SUBSET = ( 1 1 1 1 1 1 1 1 1 1 1 1 ) >> %1.prm

@echo SPATIAL_SUBSET_TYPE = INPUT_LAT_LONG >> %1.prm

@echo SPATIAL_SUBSET_UL_CORNER = ( 40.0 117.48665604 ) >> %1.prm
@echo SPATIAL_SUBSET_LR_CORNER = ( 20.0 117.059554972 ) >> %1.prm

@echo OUTPUT_FILENAME = D:2008_lst_nationa2008001.tif >> %1.prm

@echo RESAMPLING_TYPE = NEAREST_NEIGHBOR >> %1.prm

@echo OUTPUT_PROJECTION_TYPE = UTM >> %1.prm

@echo OUTPUT_PROJECTION_PARAMETERS = (  >> %1.prm
@echo 0.0 0.0 0.0 >> %1.prm
@echo 0.0 0.0 0.0 >> %1.prm
@echo 0.0 0.0 0.0 >> %1.prm
@echo 0.0 0.0 0.0 >> %1.prm
@echo 0.0 0.0 0.0 ) >> %1.prm

@echo DATUM = WGS84 >> %1.prm

@echo UTM_ZONE = 50 >> %1.prm

%MRT_HOME%binresample -p %1.prm -o %1.tif

del /f %1.txt %1.prm



http://blog.sciencenet.cn/blog-412470-301432.html

上一篇:idl二次开发 envi备忘录
下一篇:地表真实温度,辐射温度,亮度温度的区别

0

发表评论 评论 (0 个评论)

数据加载中...

Archiver|手机版|科学网 ( 京ICP备14006957 )

GMT+8, 2020-1-20 13:30

Powered by ScienceNet.cn

Copyright © 2007- 中国科学报社

返回顶部