ENVI_CONVERT_FILE_MAP_PROJECTION processing times [message #77496] |
Fri, 02 September 2011 14:23 |
Martin Landsfeld
Messages: 2 Registered: September 2011
|
Junior Member |
|
|
Hello,
I am remapping some GeoCover imagery to conform to our SRTM data. The
GeoCover is in the UTM projection at 28.5 meters and the SRTM is in a
Geographic projection at 0.0008333 degree resolution. I can do the
conversion interactively in ENVI and it takes about 67 seconds. The
files are large with:
SRTM at 7208 x 9608 pixels
GeoCover at 26857x19517 pixels
I would like to run the conversions in IDL using the batch ENVI
function ENVI_CONVERT_FILE_MAP_PROJECTION but when I do, it takes
nearly 2 hours to process the same files on the same machine, a
Windows 2008 Server with 4, 2.2GHz. Quad-Core processors and 32GB RAM.
Has anyone else noticed this slowdown when using ENVI batch?
I ran some other tests by subsetting the GeoCover file and got these
results:
time for 10000x10000 subset = 290 s, 4.8 min
time for 15000x15000 subset = 1648.2 s, 27 min
time for entire 26857x19517 = 6336.2 seconds, 105 min
I don't think there is anything wrong with my code as the output looks
fine. I'll throw that up anyway.
Thanks!
init_time = SYSTIME(/sec)
ENVI_OPEN_FILE, srtm_file_path, R_FID=srtm_fid
if (srtm_fid eq -1) then message, 'SRTM file not found'
ENVI_FILE_QUERY, srtm_fid, DIMS=dims, NB=nb, $
DATA_TYPE=data_type, NS=ns, NL=nl
srtm_proj = ENVI_GET_PROJECTION(fid = srtm_fid,
pixel_size=srtm_pix_size)
ENVI_FILE_MNG, ID=srtm_fid, /REMOVE
ENVI_OPEN_FILE, gcov_file_path, R_FID=gcov_fid
if (gcov_fid eq -1) then message, 'GeoCover file not found'
ENVI_FILE_QUERY, gcov_fid, DIMS=dims, NB=nb
pos = LINDGEN(nb)
ENVI_CONVERT_FILE_MAP_PROJECTION, fid=gcov_fid, $
pos=pos, dims=[dims,dims,dims], o_proj=srtm_proj, $
o_pixel_size=srtm_pix_size, $
out_name=out_name, warp_method=2, $
resampling=2, background=0
PRINT, 'processing time = ', SYSTIME(/sec) - init_time, format='(a,
f6.1)'
ENVI_FILE_MNG, ID=gcov_fid, /REMOVE
|
|
|