Page 1 of 1

Real variable values in l3mapgen geotiff output

Posted: Wed Sep 20, 2017 7:41 pm America/New_York
by loicdtx
Hi,

When outputting geotiff from the l3mapgen command, I only get a scaled image (in byte) without scaling factor written to the file metadata. Is there any way to output a geotiff with the actual variable values, or is geotiff just for visualization?

See a reproducible example below.

Cheers,
Loïc

wget https://oceandata.sci.gsfc.nasa.gov/cgi/getfile/A2016007174000.L2_LAC_OC.nc
wget https://oceandata.sci.gsfc.nasa.gov/cgi/getfile/A2016007174500.L2_LAC_OC.nc
wget https://oceandata.sci.gsfc.nasa.gov/cgi/getfile/A2016007191500.L2_LAC_OC.nc
wget https://oceandata.sci.gsfc.nasa.gov/cgi/getfile/A2016007192000.L2_LAC_OC.nc
wget https://oceandata.sci.gsfc.nasa.gov/cgi/getfile/A2016007192500.L2_LAC_OC.nc
wget https://oceandata.sci.gsfc.nasa.gov/cgi/getfile/A2016007205500.L2_LAC_OC.nc
wget https://oceandata.sci.gsfc.nasa.gov/cgi/getfile/A2016007210000.L2_LAC_OC.nc
wget https://oceandata.sci.gsfc.nasa.gov/cgi/getfile/A2016007210500.L2_LAC_OC.nc

ls *L2_LAC_OC.nc > file_list.par

l2bin l3bprod=chlor_a,chl_ocx infile=file_list.par resolve=1 ofile=A2016007.L3b_DAY_CHL.nc night=0 prodtype=regional
l3mapgen ifile=A2016007.L3b_DAY_CHL.nc ofile=A2016007.L3m_DAY_CHL_chlor_a_1km.tif resolution=1000m south=3 north=33 west=-122 east=-72 product=chlor_a interp=area oformat=tiff projection=smi

Real variable values in l3mapgen geotiff output

Posted: Wed Sep 20, 2017 9:03 pm America/New_York
by OB.DAACx - SeanBailey
We chose to NOT put the scale factor for the geotiff output when the indexed color palette is used, as the scaling would be rather coarse, so yes with the palette applied the tif should be used just for visualization.   However, if you set apply_pal=0, l3mapgen will generate a floating-point output.  The image will be grayscale, but the values will be real.  You can always apply a palette to the image later :wink:

Sean

Real variable values in l3mapgen geotiff output

Posted: Wed Sep 20, 2017 10:59 pm America/New_York
by loicdtx
Great!
Thanks Sean, that's exactly what I needed.

Cheers,
Loïc