Cannot construct DataBuffer - RAM usage doesn't go down after error

I have 32 GB RAM and i am caching on a drive with more than enough space. It occupies about 23GB of RAM when executing Stack creation of Sentinel 1 preprocessed data. After reaching 42% when creating the stack it stops and says ‘Cannot create DataBuffer’.

After that the RAM does not go down at all, even hours after usage. I have to close the program every time to enhance the performance of other SNAP utilities.

My product looks like this after permittivity retrieval with Band math through modified Dubois Model:
image

This is normal for Java applications. In most cases the majority of RAM used by Java is used for heap space, controlled by the Xmx parameter. Java uses garbage collection to free up heap space by removing no-longer needed objects in memory. If you have a task that requires a lot of memory,
you won’t be able to do other non-trivial tasks at the same time. There are some performance issues in SNAP 8 related to handling “no-data” values. If the extents of the images being stacked are very different, the calculation will be generating a lot of “no-data” values.

Please provide more details: What OS are you using? Are you using gpt CreateStack or the GUI? What SNAP version and have you installed the latest updates? What are you using for “Output Extents”? What is the extent and spatail resolution of the desired final stack?

Thank you for the reply.

OS: Windows 10
GUI CreateStack
ESA SNAP 8.0, Updates were done hours ago prior to executing create Stack
Output Extent: Master
I want to keep the same spatial resolution of my stack, in this case 10m

You don’t mention the extent of the stack footprint on the earth’s surface. Java has quite sophisticated processing for large images, but this comes at a cost so it can take a very long time to complete a large calculation. If your processing requires a lot more than 32MB, the 23MB may be used to process image tiles and you should see high CPU loads until the full stack has been processed. If you need too many tiles, Java could be spending a lot of time on the complex memory manipulations without making much progress.

I guess it’s the area covered with my multi temporal data. Which is about 374km2. The strange thing is that i just created a stack but it broke for some reason and couldn’t be used anymore (it had big stripes (10% of overall width) over the images), and when i tried to create a new one it just says it cannot create DataBuffer

The big stripes may be a symptom of Java running low on heap space, a graphics driver problem, or trying to view data before Java has finished the calculations. Many operations in SNAP can be done efficiently on large images by using tiles, but working close to the limits of your hardware is like running a marathon. Basic specifications for a human should be adequate to run a marathon, but in practice not all can do it. You can start by looking for issues in the SNAP messages.log and Windows Reliability Monitor.