<font class="Apple-style-span" face="verdana, sans-serif"><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; "><div><font class="Apple-style-span" style="background-color: rgb(255, 255, 255);" color="#333333">Hi Zach and Sturla,</font></div>

<div><font class="Apple-style-span" style="background-color: rgb(255, 255, 255);" color="#333333"><br></font></div><div><font class="Apple-style-span" style="background-color: rgb(255, 255, 255);" color="#333333">Well I am a "she" :)) Thanks for your inputs.. I am using 32 bit python as have so many libraries integrated with it.. and moreover, i plan to put this volume rendered on a web page or distribute the exe in the end, so want to be minimal for the memory requirements on the clients' systems.. </font></div>

<div><font class="Apple-style-span" style="background-color: rgb(255, 255, 255);" color="#333333">the physical memory should not be a problem as I have 8GB RAM.. specially when the images are RGB then it gets into trouble as it adds the 4th dimension already in my case.. </font></div>

<div><font class="Apple-style-span" style="background-color: rgb(255, 255, 255);" color="#333333"><br></font></div><div><font class="Apple-style-span" style="background-color: rgb(255, 255, 255);" color="#333333">- asmi</font></div>

<div style="color: rgb(0, 0, 0); "><br></div><div style="color: rgb(0, 0, 0); "><font class="Apple-style-span" color="#3366FF" face="verdana, sans-serif"><span class="Apple-style-span" style="color: rgb(0, 0, 0); font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; "><br>

</span></font></div>---------- Forwarded message ----------<br>From: Sturla Molden <<a href="mailto:sturla@molden.no">sturla@molden.no</a>><br>To: Discussion of Numerical Python <<a href="mailto:numpy-discussion@scipy.org">numpy-discussion@scipy.org</a>><br>

Date: Tue, 1 Feb 2011 14:49:39 +0100<br>Subject: Re: [Numpy-discussion] create a numpy array of images<br><br>Den 1. feb. 2011 kl. 11.20 skrev "<a href="mailto:totonixsame@gmail.com" target="_blank" style="color: rgb(0, 0, 0); ">totonixsame@gmail.com</a>" <<a href="mailto:totonixsame@gmail.com" target="_blank" style="color: rgb(0, 0, 0); ">totonixsame@gmail.com</a>>:<br>

<br><blockquote class="gmail_quote" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0.8ex; border-left-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; padding-left: 1ex; color: rgb(0, 0, 0); ">

I have one more question: how to avoid the limitation of memoryerror in<br><blockquote class="gmail_quote" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0.8ex; border-left-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; padding-left: 1ex; ">

<br>numpy. as I have like 200 images to stack in the numpy array of say<br>1024x1344 resolution.. have any idea apart from downsampling?<br></blockquote><br>Take a look at numpy.memmap or h5py [1].<br><br></blockquote><br>

memmap will not help unless he uses 64 bit Python, in which case he can just buy more RAM if he has too little. I suspect he is running out of virtual memory, not physical, for which 64 bit is the easiest solution. It is not possible to compensate for lack of virtual memory (typically 2GB limit with 32 bit) by memory mapping file into the already exhausted memory space.<br>

<br>Using a database like h5py will help too, unless he tries to extract them all at once.<br><br>Sturla</span></font>