NASA-PDS / transform

Transforms PDS3 and PDS4 product labels and data into various formats.
https://nasa-pds.github.io/transform/
Apache License 2.0
14 stars 1 forks source link

transform produces corrupted output images from PDS3 images #22

Open roncapat opened 4 years ago

roncapat commented 4 years ago

To Reproduce (full log) https://astrogeology.usgs.gov/search/map/Mars/Mars2020/landing_site/J03_045994_1986_J03_046060_1986_20m_slope_20m

patrick@patrick-desktop:~/Scrivania/DEMS/J03$ ll
totale 86704
drwxr-xr-x 2 patrick patrick     4096 mag 20 12:59 ./
drwxr-xr-x 4 patrick patrick     4096 mag 20 12:54 ../
-rw-rw-r-- 1 patrick patrick     2256 mag 20 11:38 J03_045994_1986_J03_046060_1986_20m_DTM_pds3.lbl.txt
-rw-rw-r-- 1 patrick patrick 43869971 mag 20 11:38 J03_045994_1986_J03_046060_1986_20m_DTM.tif
-rw-r--r-- 1 patrick patrick  1019104 mag 20 12:59 J03_045994_1986_J03_046060_1986_20m_slope_20m.jpg
-rw-rw-r-- 1 patrick patrick     2287 mag 20 12:58 J03_045994_1986_J03_046060_1986_20m_slope_20m_pds3.lbl.txt
-rw-rw-r-- 1 patrick patrick 43869971 mag 20 11:38 J03_045994_1986_J03_046060_1986_20m_slope_20m.tif
patrick@patrick-desktop:~/Scrivania/DEMS/J03$ nasa-transform J03_045994_1986_J03_046060_1986_20m_slope_20m_pds3.lbl.txt -f jpg
Image write Done
JConvertIIO
0) INP = /home/patrick/Scrivania/DEMS/J03/J03_045994_1986_J03_046060_1986_20m_slope_20m_pds3.lbl.txt
1) OUT = /home/patrick/Scrivania/DEMS/J03/J03_045994_1986_J03_046060_1986_20m_slope_20m.jpg
2) FORMAT = jpg
3) RI = true
4) OFORM = BYTE
outputs = [/home/patrick/Scrivania/DEMS/J03/J03_045994_1986_J03_046060_1986_20m_slope_20m.jpg]
PDS Transform Tool Log

Version                     Version 1.11.1
Time                        mer, mag 20 2020 at 01:02:20 PM
Target                      [file:/home/patrick/Scrivania/DEMS/J03/J03_045994_1986_J03_046060_1986_20m_slope_20m_pds3.lbl.txt]
Output Directory            /home/patrick/Scrivania/DEMS/J03
Index                       1
Format Type                 jpg

INFO:   [/home/patrick/Scrivania/DEMS/J03/J03_045994_1986_J03_046060_1986_20m_slope_20m_pds3.lbl.txt] Transforming image file: /home/patrick/Scrivania/DEMS/J03/J03_045994_1986_J03_046060_1986_20m_slope_20m.tif
INFO:   [/home/patrick/Scrivania/DEMS/J03/J03_045994_1986_J03_046060_1986_20m_slope_20m_pds3.lbl.txt] Successfully transformed image file '/home/patrick/Scrivania/DEMS/J03/J03_045994_1986_J03_046060_1986_20m_slope_20m.tif' to the following output: /home/patrick/Scrivania/DEMS/J03/J03_045994_1986_J03_046060_1986_20m_slope_20m.jpg

Expected behavior Something like the Sample JPEG image

Version of Software Used

patrick@patrick-desktop:~/Scrivania/DEMS/J03$ nasa-transform -V

{project.groupId}:transform
Version 1.11.1
Release Date: 2019-12-13 11:01:28

Copyright 2019, by the California Institute of Technology ("Caltech").
All rights reserved.

Screenshots Schermata da 2020-05-20 13-05-53

Desktop (please complete the following information):

NOTE Maybe I'm missing something since I'm a new user, but from the scarce documentation I read and the "help info" from command line, I suppose this is not how it's supposed to work. I'm trying to render .tif files obtained from usgs.gov to jpeg (DEMs and DTMs).

jordanpadams commented 4 years ago

@roncapat sorry for the delayed response here. we will look into this. What is the time criticality for this issue?

As a workaround, have you tried using NASAView or GDAL for this transformation in the meantime?

roncapat commented 4 years ago

Very low priority for me. I ended up using QGIS/GDAL for my purposes, but I'll track the evolution of this issue anyway.

Maybe was also a misunderstanding of my usage of the transform tool. If it was the case, sorry for that :)

jordanpadams commented 4 years ago

@roncapat no you are good! the software should be able to handle this, so we will try to track down the issue. since it isn't a high priority, we will table for now, but we will let you know when it is resolved.