SNAP command line

I am trying to install snap with command line. Already installed, but got error as below. Please, help me I am stuck! Should I Delete only SNAP-internal configuration data? Thanks in advance.

Unpacking JRE …
tar: jre/lib/amd64/ Cannot utime: No such file or directory
tar: man/ja: Cannot utime: No such file or directory
tar: Exiting with failure status due to previous errors
Starting Installer …
This will install ESA SNAP on your computer.
OK [o, Enter], Cancel [c]
Click Next to continue, or Cancel to exit Setup.
Delete SNAP’s configuration data and user settings?
The installer detected SNAP user data directories from a previous
installation. These directories contain system file used by the application
and also stored graphs, RGB profiles or other auxiliary data. The data
stored in these directories might not be compatible with this new SNAP
version anymore.

Shall the installer try to remove these directories?
Yes, try deleting all SNAP user data [1], Delete only SNAP-internal configuration data (recommended). [2, Enter]

If you haven’t stored important personal data in the user directory (/home/username/.snap) then you can chose option [1] and delete all SNAP user data. In this directory are RGB profiles, colour palettes and graphs stored by default. otherwise it is more safe to go with option [2]

1 Like

thanks, I could solve the problem. But I have another question, in gui snap it is easy to open the file calibrate it and do other process, now I can not understand how to process my files with the command line and why we need xml file for? Please, can you explain it and share some examples (ex, I need to calibrate S1 file called

You need the XML files because you need a place for all the configuration parameters.
A general introduction to processing with gpt on the command line, is given by this wiki page:
Bulk Processing with GPT - SNAP Wiki

You can also create graphs and process data within the GUI. The Graph Builder respectively the Batch Processing tool can be used for this.

Within the Graph Builder you find example graphs. For Calibrating it is simple (Graphs / Radar / Standard Graphs / Calibrate). It is just the Calibrate operator.
This single operator can also be used without an XML file.

Example call:
gpt Calibration -PauxFile="Product Auxiliary File" -PselectedPolarisations=VH,VV -PcreateBetaBand=true -PoutputSigmaBand=true -t <output_path> <source_path>
But if you use multiple operators you need to connect them. For defining this graph of operators the XML file is needed too.

For some further hints have also a look at our tutorial page. The general SNAP section might be of interest for you and also the S1TBX section.


thanks a lot, your answer helped me. I am trying to try with xml file now for calibration, but struggling what to write to ${source} in node id = cal. Below is shown. Can you please check it?

<graph id="calibration">
    <node id="cal">
            <auxFile>Product Auxiliary File</auxFile>

This should work if you specify the path to your source product like: