Not able to open Tiff image

Hi,

I am trying to open a TIFF image within SNAP and I get an error message:

‘A java.lang.ArrayIndexOutOfBoundsException exception has occurred’.

The file is 2.5gb in size. Could this be the problem?

Regards,

Pamela

Is this file an output of iCOR?
Actually also images bigger than 2.5 GB are supported.
Do you more details about the error?
Can you see more in the log file?
Can you attach the log file, please? You can find it by selecting from the menu Help / Show Log Directory. Make sure to reproduce the error first and then attach the messages.log file.

No, the file is not an output of iCOR. I actually layerstacked the sentinel 2 bands with 3 vegetation indices in ENVI (collocate wasn’t working in SNAP). So I saved it as a geotiff in ENVI. See attached the details in the log file.messages.log (70.8 KB)

This error happens due to a problem in one of the libraries we use.
The specific data type you use can not be handled correctly. We have this issue already in our bug tracker (SNAP-493).
Maybe you can change the data type in ENVI?

Thanks Marpet. I tried several datatypes in ENVI, some are not compatible with SNAP. Which type would you recommend?

I don’t know which data types are shown to you and how they are named.
The one you first tried is named SLONG8 in GeoTiff terms.
Maybe you try “Short”, if it is available.

Ok, great. Let me try that.

Hi All. I can open the .tif file on ArcGIS Pro, and the data is okay, but when I am trying to open it on SNAP I am getting an error; here is the error details,

java.lang.ArrayIndexOutOfBoundsException
java.lang.ArrayIndexOutOfBoundsException
Caused: java.util.concurrent.ExecutionException

  • at java.util.concurrent.FutureTask.report(FutureTask.java:122)*
  • at java.util.concurrent.FutureTask.get(FutureTask.java:192)*
  • at javax.swing.SwingWorker.get(SwingWorker.java:602)*
    [catch] at org.esa.snap.rcp.actions.window.OpenImageViewAction$1.done(OpenImageViewAction.java:228)
  • at javax.swing.SwingWorker$5.run(SwingWorker.java:737)*
  • at javax.swing.SwingWorker$DoSubmitAccumulativeRunnable.run(SwingWorker.java:832)*
  • at sun.swing.AccumulativeRunnable.run(AccumulativeRunnable.java:112)*
  • at javax.swing.SwingWorker$DoSubmitAccumulativeRunnable.actionPerformed(SwingWorker.java:842)*
  • at javax.swing.Timer.fireActionPerformed(Timer.java:313)*
  • at javax.swing.Timer$DoPostEvent.run(Timer.java:245)*
  • at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311)*
  • at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:758)*
  • at java.awt.EventQueue.access$500(EventQueue.java:97)*
  • at java.awt.EventQueue$3.run(EventQueue.java:709)*
  • at java.awt.EventQueue$3.run(EventQueue.java:703)*
  • at java.security.AccessController.doPrivileged(Native Method)*
  • at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)*
  • at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)*
  • at org.netbeans.core.TimableEventQueue.dispatchEvent(TimableEventQueue.java:159)*
  • at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)*
  • at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)*
  • at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)*
  • at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)*
  • at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)*
  • at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)*
    SEVERE [org.esa.snap]: JAI error occurred: ‘Problem occurs when computing a tile by the owner.’ at com.sun.media.jai.util.SunTileScheduler@1c0b4db8
    java.lang.ArrayIndexOutOfBoundsException
    SEVERE [null]: Last record repeated again.
    SEVERE [org.esa.snap]: JAI error occurred: ‘Problem occurs when computing a tile by the owner.’ at com.sun.media.jai.util.SunTileScheduler@1c0b4db8
    java.lang.RuntimeException: Waiting thread received a null tile.
  • at com.sun.media.jai.util.SunTileScheduler.scheduleTile(Unknown Source)*
  • at javax.media.jai.OpImage.getTile(Unknown Source)*
  • at javax.media.jai.PlanarImage.getData(Unknown Source)*
  • at javax.media.jai.RenderedOp.getData(Unknown Source)*
  • at org.esa.snap.core.image.VirtualBandOpImage.addDataToReferredRasterDataSymbols(VirtualBandOpImage.java:307)*
    [catch] at org.esa.snap.core.image.VirtualBandOpImage.computeTile(VirtualBandOpImage.java:235)
  • at com.sun.media.jai.util.SunTileScheduler.scheduleTile(Unknown Source)*
  • at javax.media.jai.OpImage.getTile(Unknown Source)*
  • at com.sun.media.jai.util.SunTileScheduler.compute(Unknown Source)*
  • at com.sun.media.jai.util.TileJob.compute(Unknown Source)*
  • at com.sun.media.jai.util.WorkerThread.run(Unknown Source)*
    java.util.concurrent.ExecutionException: java.lang.ArrayIndexOutOfBoundsException
  • at java.util.concurrent.FutureTask.report(FutureTask.java:122)*
  • at java.util.concurrent.FutureTask.get(FutureTask.java:192)*
  • at javax.swing.SwingWorker.get(SwingWorker.java:602)*
  • at org.esa.snap.rcp.actions.window.OpenImageViewAction$1.done(OpenImageViewAction.java:228)*
  • at javax.swing.SwingWorker$5.run(SwingWorker.java:737)*
  • at javax.swing.SwingWorker$DoSubmitAccumulativeRunnable.run(SwingWorker.java:832)*
  • at sun.swing.AccumulativeRunnable.run(AccumulativeRunnable.java:112)*
  • at javax.swing.SwingWorker$DoSubmitAccumulativeRunnable.actionPerformed(SwingWorker.java:842)*
  • at javax.swing.Timer.fireActionPerformed(Timer.java:313)*
  • at javax.swing.Timer$DoPostEvent.run(Timer.java:245)*
  • at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311)*
  • at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:758)*
  • at java.awt.EventQueue.access$500(EventQueue.java:97)*
  • at java.awt.EventQueue$3.run(EventQueue.java:709)*
  • at java.awt.EventQueue$3.run(EventQueue.java:703)*
  • at java.security.AccessController.doPrivileged(Native Method)*
  • at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)*
  • at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)*
  • at org.netbeans.core.TimableEventQueue.dispatchEvent(TimableEventQueue.java:159)*
  • at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)*
  • at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)*
  • at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)*
  • at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)*
  • at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)*
  • at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)*
    Caused by: java.lang.ArrayIndexOutOfBoundsException
    SEVERE [org.esa.snap.rcp.SnapApp]: Failed to open image view.

Hello srahman.

From the exception you have provided - thanks for that - I see you open a virtual band in SNAP. Those are not contained in a GTiff. What’s the expression you are using?
Can you also tell where the data is from? Maybe you can provide it?

One option you can try to open the data is select the type of file in the open dialog.
Try with GeoTiff (GDAL 3.2.1)
image

1 Like

Hi Marco,

Thank you for your quick reply and for your valuable suggestion. I have noticed I am getting " Java Heap Space Error", and the created GeoTIFF/BigTIFF is not covering the full data extent. I have added -q 120 to my command hope it will work,

gpt “C:\bash_issue\Test_BlueMt.xml” -q 120 -Pin=“C:\bash_issue\zipped//S1A_IW_GRDH_1SDV_20190407T083917_20190407T083942_026681_02FE98_8B31.zip” -Pout=“C:\bash_issue\results//S1A_IW_GRDH_1SDV_20190407T083917_20190407T083942_026681_02FE98_8B31.tif”

The data I got from the Sentinel Australasia Regional Access (SARA), and the data is for New South Wales, Australia (S1A_IW_GRDH_1SDV_20190407T083917_20190407T083942_026681_02FE98_8B31"). I am still processing the data when it will be completed will try to open it with GeoTIFF rather GeoTIFF/BigTIFF data product, I will share the data with you if it’s not working.

Regards,

Shahriar