1

I have 44GB jp2 file, I want to translate it to tif file, but once it reaches 10% it crashes. No messages, just stopped. This is my command:

gdal_translate.exe -of GTiff --config GDAL_CACHMAX 8000 -co COMPRESS=JPEG -co TILED=YES -co PHOTOMETRIC=YCBCR -co JPEG_QUALITY=75 "Z:\Sat\inp.jp2" "C:\Shamaal\out.tif" 
4
  • Might be running out of memory - have you looked at Task Manager or Resource Monitor while it's running to see how much RAM is used up as it goes? Commented Dec 3, 2015 at 5:47
  • 1
    Check which JPEG2000 drivers you have installed with gdalinfo --formats and add that into your question. There may be many, list them all. Commented Dec 3, 2015 at 7:43
  • GDAL_CACHEMAX instead of GDAL_CACHMAX, but setting it to 8000 is unlikely to work unless you have a 64 bit OS and a very new GDAL. See trac.osgeo.org/gdal/wiki/ConfigOptions#GDAL_CACHEMAX Commented Dec 3, 2015 at 8:36
  • I have 64bit OS and have 24 GB memory, I was monitoring the memory all the time, and it never exceed the 2GB used by GDAL. Commented Dec 6, 2015 at 4:37

2 Answers 2

1

This recent blog at http://blog.hexagongeospatial.com/jpeg2000-quirks/ covers a lot of the pitfalls between the available JPEG2000 toolkits. Since you are decoding a very large file, you will likely be running into the same compatibility issues that are likely solved by using JP2ECW or JP2MrSID (As Howard alluded to).

1

A 44GB jp2 is going to be a monster TIFF file. Assuming you really want that, I would expect the problem is that GDAL is using the OpenJPEG JP2 driver by default, and this isn't so up to snuff for such a large file.

Try using the GDAL_SKIP environment variable, described on the GDAL Options page, to skip the JPEG2000 driver in an attempt to have the file open up with the MrSID or ECW driver instead.

set GDAL_SKIP=JPEG2000 gdal_translate.exe ... 

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.