Cannot construct DataBuffer

Hello,
I am trying to clip my area of interest using Land/Sea Mask. In the “Use vector as mask” , I have put the shape file of interest.
when I run , I get this error " Cannot Construct data buffer " . Please help!

This is the error:

java.lang.RuntimeException: Cannot construct DataBuffer.
at com.sun.media.jai.util.DataBufferUtils.constructDataBuffer(DataBufferUtils.java:132)
at com.sun.media.jai.util.DataBufferUtils.createDataBufferFloat(DataBufferUtils.java:214)
at javax.media.jai.ComponentSampleModelJAI.createDataBuffer(ComponentSampleModelJAI.java:271)
at javax.media.jai.RasterFactory.createWritableRaster(RasterFactory.java:691)
at javax.media.jai.PlanarImage.createWritableRaster(PlanarImage.java:1982)
at javax.media.jai.SourcelessOpImage.computeTile(SourcelessOpImage.java:130)
at org.esa.snap.core.image.VirtualBandOpImage.computeTile(VirtualBandOpImage.java:237)
at com.sun.media.jai.util.SunTileScheduler.scheduleTile(SunTileScheduler.java:904)
Caused: org.esa.snap.core.gpf.OperatorException: Cannot construct DataBuffer.
at org.esa.snap.core.gpf.internal.OperatorExecutor$GPFImagingListener.errorOccurred(OperatorExecutor.java:376)
at com.sun.media.jai.util.SunTileScheduler.sendExceptionToListener(SunTileScheduler.java:1646)
at com.sun.media.jai.util.SunTileScheduler.scheduleTile(SunTileScheduler.java:921)
at javax.media.jai.OpImage.getTile(OpImage.java:1129)
at javax.media.jai.PlanarImage.getData(PlanarImage.java:2085)
at org.esa.snap.core.image.VirtualBandOpImage.addDataToReferredRasterDataSymbols(VirtualBandOpImage.java:309)
at org.esa.snap.core.image.VirtualBandOpImage.computeTile(VirtualBandOpImage.java:235)
at com.sun.media.jai.util.SunTileScheduler.scheduleTile(SunTileScheduler.java:904)
at javax.media.jai.OpImage.getTile(OpImage.java:1129)
at javax.media.jai.PlanarImage.cobbleFloat(PlanarImage.java:3254)
at javax.media.jai.PlanarImage.getData(PlanarImage.java:2181)
at com.bc.ceres.glevel.MultiLevelImage.getData(MultiLevelImage.java:64)
at org.esa.snap.core.gpf.internal.OperatorContext.getSourceTile(OperatorContext.java:407)
at org.esa.snap.core.gpf.internal.OperatorContext.getSourceTile(OperatorContext.java:393)
at org.esa.snap.core.gpf.internal.OperatorImage.computeRect(OperatorImage.java:73)
at javax.media.jai.SourcelessOpImage.computeTile(SourcelessOpImage.java:137)
at com.sun.media.jai.util.SunTileScheduler.scheduleTile(SunTileScheduler.java:904)
at javax.media.jai.OpImage.getTile(OpImage.java:1129)
at com.sun.media.jai.util.RequestJob.compute(SunTileScheduler.java:247)
[catch] at com.sun.media.jai.util.WorkerThread.run(SunTileScheduler.java:468)

How many RAM do you have?? This is a specific error when the system does not have sufficient RAM memory.

1 Like

I have 4GB of RAM . So,that must be the reason then. Thankyou.

@anup_upadhyaya For S1A to run ok you must have at least 16 gb of RAM. Sorry for that but your pc needs an extra boost of memory. Cheers!

1 Like

Hello everyone,

i face the DataBuffer error when i process the TOPS Deburst tool. According to suggestions already present in the forum i had:

  • Increased the RAM from 11364m to 13000m (by tools>options>performance; i try to perform this setting in snap.conf file but i can’t change it from there.) ;
  • set chace size at 4096 MB.

Even after those settings, the issue persist.

I notice another thing since i use SNAP: i had processed different stocks of images for PS-InSAR SNAP-STAMPS processing purposes (7 images, 14images and so on). The last process that I made involved 28 images and no such error was present. Now i process a stock of 28 images but i faced the DataBuffer problem; i have changed nothing. I use the same SLC products.
Maybe, i think, in all those attempts some useless files have been created and SNAP uses resources to manage those files. Can this be the problem? If yes, how i clean the process after each attempt?

Sorry if i ask something obvious: for sure, i have several lacks in informatics (I’m civil engineer and i just started with this topic). Also, sorry if the solution is already present in some of the past FAQ, but i read “DataBuffer Errors” and similar and i cant solve my problem.

In general, has someone any idea to solve this issue?

I use SNAP from Desktop; Windows 10; SNAP 8.0; 16 GB RAM; Asus- Intel(R) Core™ i7-8750H CPU.

Thanks for reading,
My best,
Othmane.