comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: divise image envi-idl
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: divise image envi-idl [message #70958 is a reply to message #70947] Wed, 19 May 2010 10:33 Go to previous messageGo to previous message
jeanh is currently offline  jeanh
Messages: 79
Registered: November 2009
Member
outname is still wrong (you DO want to keep some space there... read my
previous post)

Jean


On 19/05/2010 10:17 AM, Antoine Cheula wrote:
> "Jeff N.
>
> "You need to read the image data into memory if you want to subscript
> it this way."
>
> That was the problem. I still have a problem to save my divide images
> with the function envi_write_envi_file...
>
> Now, my program look like this :
>
> pro tuilage
>
> ENVI, /RESTORE_BASE_SAVE_FILES
> ENVI_BATCH_INIT
>
> image = 'C:\Documents and Settings\Administrateur\Mes documents
> \cooccurrence+1+2'
> envi_open_file, image, r_fid=fidimage, /NO_REALIZE
>
> if (fidimage eq -1) then begin
> print, 'error nestor'
> endif
>
> envi_file_query, fidimage, dims = dimimage, NB=NBimage, NL=NLimage,
> NS=NSimage, Bnames=Bnamesimage, data_type = data_type
> pos = lindgen(NBimage)
>
> openr, lun, image, /get_lun
> espace = fltarr(NSimage, NLimage, NBimage)
>
> READU,lun, espace
>
> result = fltarr(NSimage/5, NLimage/2, NBimage)
>
> for i = 0, (NSimage-NSimage/5), NSimage/5 do begin
> for j = 0, (NLimage-NLimage/2), NLimage/2 do begin
>
> result = espace[i:i+((NSimage/5)-1),j:j+((NLimage/2)-1),
> 0:NBimage-1]
>
>
> envi_write_envi_file, result, data_type=4, nb=NBimage,
> nl=NLimage/2, $
> ns=NSimage/5, BNAMES=BNamesimages, $
> outname = STRCOMPRESS('C:\Documents and Settings\Administrateur
> \Mes documents\'+string(i/(NSimage/5))+string(j/(NLimage/2)),/
> REMOVE_ALL)
>
> endfor
> endfor
>
> end
>
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: x-y offsets
Next Topic: Why do I get the string in ytitle in vertical direction

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sat Oct 11 09:23:04 PDT 2025

Total time taken to generate the page: 1.51771 seconds