Yacoub,
Would add to Tom's questions which are all valid--especially clearing the Temp space between runs. Can you add more memory?
Since the Aster DEM processing runs to completion on a 64-bit Windows 7 with 4GB available RAM it suggests it is a memory management issue under your XPsp3 32-bit system. That is to say, the processing fits and runs to completion in the full 4GB user-mode memory space of a 32-bit program in 64-bit address space.
So, is your Windows XPsp3 system limited by BIOS to 2 GB RAM, and can you add RAM? Or is it a laptop that is already maxed out? Adding at least another 1GB of RAM should allow the 32-bit OS some head space to complete the processing in available 2GB per-process user-mode memory address space.
You might also need to add a /3GB flag to the boot.ini file which would expand available user address space, and allow each process its full 2GB limit--but don't set this flag unless you ARE able to add additional RAM!
Some additional tweaks of 32-bit programs to set LargeAddressAware values can be helpful to increase per-process address space beyond 2GB (notably for python.exe and pythonw.exe). But I would not pursue those just yet as it would add another variable and the existing unmodified programs run to completion under 64-bit OS in when not memory constrained.
Stuart