Re: Does the ENVI_SVM_DOIT function have memory leak problem? [message #59483] |
Sun, 30 March 2008 18:51 |
Neve
Messages: 4 Registered: March 2008
|
Junior Member |
|
|
On Mar 30, 9:22 pm, Spon <christoph.b...@gmail.com> wrote:
> If there's any image information stored in off-screen pixmap buffers,
> then you could try getting rid of these with something like:
>
> While !Window NE -1 DO WDelete
>
> I know I've had a similar problem if I use XInterAnimate with the /
> KEEP_PIXMAPS keyword set.
>
> Take care,
> Chris
I didn't use any IDL graphics window in my pro. But I tried what you
said. It didn't work either. Thanks anyway.
|
|
|
Re: Does the ENVI_SVM_DOIT function have memory leak problem? [message #59484 is a reply to message #59483] |
Sun, 30 March 2008 06:22  |
Spon
Messages: 178 Registered: September 2007
|
Senior Member |
|
|
On Mar 30, 11:56 am, Neve <jingzheng2...@gmail.com> wrote:
> I used the "Heap_gc, /verbose" statement to see if there's still any
> "garbage" in the memory after I removed the original image, the ROIs
> and the classification result. But there was none. Yet some amount of
> memory was occupied. It's really weird.
>
> Neve
If there's any image information stored in off-screen pixmap buffers,
then you could try getting rid of these with something like:
While !Window NE -1 DO WDelete
I know I've had a similar problem if I use XInterAnimate with the /
KEEP_PIXMAPS keyword set.
Take care,
Chris
|
|
|
Re: Does the ENVI_SVM_DOIT function have memory leak problem? [message #59485 is a reply to message #59484] |
Sun, 30 March 2008 03:56  |
Neve
Messages: 4 Registered: March 2008
|
Junior Member |
|
|
On Mar 29, 12:34 am, Jean H <jghas...@DELTHIS.ucalgary.ANDTHIS.ca>
wrote:
> Do 1.0/numFeatures
>
> not sure it would have any effect on the memory though...
> you can try to add a heap_gc statement every now and then..
>
> Jean
>
Sorry, Jean. It seems that I replied to your email yesterday.
The "1.0/numFeatures" statement does not have effect on the memory. I
have checked that. I have also tried the heap_gc statement. It didn't
work. The problem still exists.
I used the "Heap_gc, /verbose" statement to see if there's still any
"garbage" in the memory after I removed the original image, the ROIs
and the classification result. But there was none. Yet some amount of
memory was occupied. It's really weird.
Anyway, thank you very much for you reply.
Neve
|
|
|
Re: Does the ENVI_SVM_DOIT function have memory leak problem? [message #59505 is a reply to message #59485] |
Fri, 28 March 2008 09:34  |
Jean H.
Messages: 472 Registered: July 2006
|
Senior Member |
|
|
> Pro test
> ori_data_path = 'D:\bhtmref'
> envi_open_file, ori_data_path, r_fid=ori_img_fid
> envi_file_query, ori_img_fid, dims=ori_img_dims, nb=ori_img_nb
> numFeatures = ori_img_nb
> Feature_Subset = indgen(numFeatures)
> Para_C = 100
> Para_gamma = 1/numFeatures
==> will always be 0
Do 1.0/numFeatures
not sure it would have any effect on the memory though...
you can try to add a heap_gc statement every now and then..
Jean
> out_name = 'D:\clsrst'
> envi_restore_rois,'D:\test.roi'
> tr_roi_ids = envi_get_roi_ids(fid=fid)
> help, /memory
> print, '=================='
> ; Call the svm classification doit routine, using the optimized
> parameters
> envi_doit, 'envi_svm_doit', $
> fid=ori_img_fid, pos=Feature_Subset, dims=ori_img_dims, $
> out_name=out_name, roi_ids=tr_roi_ids , $
> penalty=Para_C, kernel_gamma= Para_gamma
> help, /memory
> ; Remove the original image and training ROI IDS
> envi_file_mng, id=ori_img_fid, /remove
> help, /memory
> envi_delete_rois, tr_roi_ids
>
> End
|
|
|