CreateStack input

Hi all!
I am trying to co-register multiple images to one master image. I learned that I can do this in Python via

self.src_stack = snappy.GPF.createProduct(‘CreateStack’, self.params, product_set)

where product set is simply a list of imported .dim files (via snappy.ProductIO.readProduct(file_dim)) in which the first list element is taken as the master image (see Call ProductSet-Reader and Create Stack in Snap). However, when I implement this in Python as an extension, input will likely be a (i.e. raw S1 data). Do I really need to read the input via context.getSourceProduct(’’) and export it only to import it again as a .dim file? Or is there a more efficient way to do this?

Many thanks!