[vtkusers] Memory problem

David Gobbi david.gobbi at gmail.com
Thu Jul 15 11:11:11 EDT 2010


Memory fragmentation is a severe problem on 32-bit windows systems.
Switching to Win64, Unix, or a Mac will mostly eliminate memory
fragmentation.

If you are wondering about streaming from disk (i.e. only reading part
of the volume at a time) it is usually only possible when reading data
slice-by-slice, so it is not useful for doing MPRs.  So you must have
at least enough memory to read the whole volume, and for best
performance you should call Update on the reader to make sure it loads
the whole volume because streaming from disk is very slow.

To save memory, it is important to put your slice extraction filter
immediately after the reader.  If you put any other sort of filter
after the reader, then there is a chance that that filter will operate
on the whole extent of the image instead of acting on just the slices
that you are currently viewing.

  David


On Thu, Jul 15, 2010 at 8:36 AM, Lic. José M. Rodriguez Bacallao
<jmrbcu at gmail.com> wrote:
> I am interested in this too. I am using python.
>
> On 7/15/10, Raúl Ferriz <raul at torresyvalero.com> wrote:
>> Hi all!
>>
>> I have some memory problems with VTK. I'm trying to load very big DICOM
>> series through gdcm and show Axial, Sagittal and Coronal images. Also I
>> render a 3d visualization of the dicom. All work good until I try to
>> load a very big DICOM, I have 2 Gb of ram, and another machine with 1,5
>> Gb of ram. I have one dicom that load perfectly on first machine, but
>> fails with an "Unable to allocate xxxx of 8 bytes" (sorry I don't
>> remember the number, but this is not really very important). On the
>> other machine this dicom works good, but when I unload and reload some
>> other dicoms, evetually it fails with same error. I had concluded that
>> on first machine fails after some memory fragmentation, because I'm sure
>> that all not needed memory is freed. But on second machine (1.5Gb) there
>> is not enough memory to allocate that Dicom fully on memory.
>>
>> Is there a way to avoid this problem? Can streaming be the solution?
>> _______________________________________________
>> Powered by www.kitware.com
>>
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>>
>> Please keep messages on-topic and check the VTK FAQ at:
>> http://www.vtk.org/Wiki/VTK_FAQ
>>
>> Follow this link to subscribe/unsubscribe:
>> http://www.vtk.org/mailman/listinfo/vtkusers
>>
>
>
> --
> Lic. José M. Rodriguez Bacallao
> Centro de Biofisica Medica
> -----------------------------------------------------------------
> Todos somos muy ignorantes, lo que ocurre es que no todos ignoramos lo mismo.
>
> Recuerda: El arca de Noe fue construida por aficionados, el titanic
> por profesionales
> -----------------------------------------------------------------
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>



More information about the vtkusers mailing list