Issue building a large tiff image with pconvert


#1

Dear STEP forum,

I am trying to create a tiff image from a coh_sigmaAvrg_IW_VV_11Sep2018_23Sep2018_Coh_Ampl.tif with image profile:

#RGB-Image Profile
#Fri Mar 23 16:46:55 CET 2018
blue=0
name=coh_sigmaAvg_null
green=if fneq(coh_VV_11Sep2018_23Sep2018,0) then max(min(floor(sigmaAverage*12.7+191.5),255),1) else 0
red=if fneq(coh_VV_11Sep2018_23Sep2018,0) then max(min(floor(coh_VV_11Sep2018_23Sep2018*256.565656566-1.56565656566),255),1) else 0

I call p convert with this command:
pconvert -f tif -p coh_sigmaAvg_null.rgb -s 0,0 -o /output/coh_sigmaAvrg_IW_VV_11Sep2018_23Sep2018_Coh_Ampl.tif

This works fine when pixelspacing of the input image is set to 30 meter, but when it is set to 15 meter unfortunately it crashes with this error message:

reading file coh_sigmaAvrg_IW_VV_11Sep2018_23Sep2018_Coh_Ampl.tif
INFO: org.hsqldb.persist.Logger: dataFileCache open start
loading RGB profile from '/application/test/coh_sigmaAvg_null.rgb'...
creating histogram for band 'virtual_red'...
creating histogram for band 'virtual_green'...
creating histogram for band 'virtual_blue'...
creating RGB image...
error: failed to create image: null

The size of the input image is 6,8 GB.

Could you please advice me how to fix my issue?
Thanks in advance,
Thijs


RGB profile for pconvert with multiple input files
#2

I think the problem is that the 2GB limit of Tiff files is reached.
Try to switch to Big-Tiff. Change tif, to BigTiff.
Or first write to BEAM-DIMAP or NetCDF4 and then try to export GeoTiff. Maybe subsetted to a region


#3

I tried it with:
pconvert -f BigTiff -p coh_sigmaAvg_null.rgb -s 0,0 -o /output/ coh_sigmaAvrg_IW_VV_11Sep2018_23Sep2018_Coh_Ampl.tif

It gives me the error:
error: unknown output format 'BigTiff'

Or did you suggest a different change?
Regards,
THijs


#4

Also in the manual here: http://seom.esa.int/toolbox/Beam_UserManual.php , I dont see anything about Bigtiff, could you advice on how I should write to BigTiff? The input is already a BigTiff since it is created with snap writing to GeoTiff-BigTiff.
Thanks in advance,
Thijs


#5

The correct identifier for the format is GeoTIFF-BigTiff.

pconvert -f GeoTIFF-BigTiff

Unfortunately it is not possible to print all the available formats on the command line.
This is known since a while: https://senbox.atlassian.net/browse/SNAP-180

But you can take the format names from any of the processor GUIs.
There you can select the format and this you can specify also on the command line.


#6

Dear Marco,
Thanks for the ongoing support, however , now I have a new error message. This message is:
error: RGB-profile is only valid for image output
This is what i get when using:
pconvert -f GeoTIFF-BigTiff -p coh_sigmaAvg_null.rgb -s 0,0 coh_sigmaAvrg_IW_VV_11Sep2018_23Sep2018_Coh_Ampl.dim
How should I avoid this?


#7

Go to the snap.bak/bin then Run ./pconvert Tif -h it returns you(in the option), all the format that you want to convert. take a look on two formats tifp and tif…


#8

@Samira.h Thanks for your support but it gives me exactly the same options as I mentioned earlier in here: http://seom.esa.int/toolbox/Beam_UserManual.php

What is interesting is that I am able to make a Geotiff-BigTiff using the parameter -b and then specifiying the bands, but I am not able to use an image RGBprofile. @marpet does this maybe give you an idea where my issue is and how I can resolve this?
Thanks


#9

Dear all,
Are there any new suggestions how to make a RGBprofile for a Geotiff-BigTiff ?
I am working on a work-around for the issue here, but ran into a new error which i posted here: Discrepancy reproducing pconvert rgb profile with bandmath in Snap

Thanks for the support,
Thijs


Discrepancy reproducing pconvert rgb profile with bandmath in Snap