Absolute beginner's guide to GPT

Hi completely new to this, was wondering if anyone could point me to any links or documentation for a complete beginner or send me some sample scripts. Trying to use command line to create calibrated, terrain corrected geotiff’s from sentinel 1 a zipped data products.


Note there is a short intro in the SNAP help system.
I agree that we urgently need such a beginners and expert guide: https://senbox.atlassian.net/browse/SNAP-306


Maybe this is of some help: The shortest version is that you create a graph file in SNAP using the Graph Builder and save it as xml-file, some examples of such files are here:

For the way I do it, you have to modify these files saved from the Graph Builder:

Now you can call gpt from command line like, this, -Pfile means that “$file” in the xml file is replaced by the inputfilename:

gpt full_path_to_xml_file -Pfile="inputfile" -t "outputfile"

To process large quantities of data, I produce the command above as a string using Python and pass it to command line with os.system. You can also do this with Matlab and others…


Hi Max, I have very similar problem.

Could have a look at my question please ?

I would really appreciate it.

Many Thanks,


Hi Ishackm,

I would recommend providing gpt with a parameter file: https://senbox.atlassian.net/wiki/spaces/SNAP/pages/70503475/Bulk+Processing+with+GPT

Effectively, you will open your .xml graph file and replace file paths (or whatever other parameters you wan to provide) with ${variableName} and then within your parameter file, you will do


and then you can call gpt like so:
gpt my_processinggraph.xml -p myparameterfile.txt

Then you can just have a folder of these parameter files and do a loop like this (this is a bash shell loop, but you can do similar things on powershell or cmd on windows) :

for a in *.txt
gpt mygraph.xml -p $a 

Hope that helps!


NASA’s Introduction to gpt has some nice examples using an older version of gpt. Note that NASA has been renaming files, so it may be necessary to adjust some file names.

1 Like