Creating Stack of SAR products in SNAP 8.0

Hi everyone!
I have been working on SAR images and SNAP mainly from python for quite a while but I’m no expert.
My problem is with the CreateStack operator when I call it from python with SNAP version 8.0. I’m trying to perform Coregistration which requires this operator, as it is from SANP’s GUI also. I face no issues doing so with SNAP 7 in python, but upgrading to version 8.0 the exact same code raises this error:

RuntimeError: org.esa.snap.core.gpf.OperatorException: org.esa.snap.engine_utilities.gpf.OperatorUtils.createProductName(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

The last line of code it refers to is the return of the function for create stack:
return GPF.createProduct('CreateStack', parameters, products)
I tried the same coregistration with the same parameters from the GUI and it works.

The problem with this error is that it’s not clear what or why is going on wrong.
Unfortunately I cannot use version 7 anymore for other reasons so I must upgrade.

Thank you in advance!

Bonnejour,

i essentially had the same issue right here. Apparently this happens with the latest SNAP versions.
in fact i solved by downgrading to SNAP 4.0 first, then added this to the create stack funtion:

parameters.put(‘extent’, ‘Minister’)

hope this helps

SNAP 4.0 is ancient :scream: - I really wish you find the way of doing this in SNAP 9.0, the current supported version.

Regarding Python, would using the SNAP Python-wrapper snapista suit your needs? Since it is calling gpt there is no performance-penalty like with snappy. @Lorman99