Problem in BatchProcessing

If there is now error shown. I can’t say what’s wrong.

Regarding the batch processing question:
Probably you should familiarise your self with it in general.
Specific to for loops is this page
The X is just the variable holding the file path. With ~nX only the file name is used.

Thank you very much for your help to me all the time!I’m learning it now.One more question is that: Is it possible to use the for-command to go through two images in the meantime as the inputs of Slice assembly?

In the for-loop you only have one file at hand at the same time.
There are multiple ways for doing a parallelisation. You could start two batch scripts for example. In general gpt is doing already a parallelisation and utilises the CPU and memory at its maximum. So you will probably don’t gain performance improvements when do extra parallelisation.

Thannks for your help!
I’ll have a try.

Depending on your graph you can experience problems with the parallelisation done by gpt.
See here:

Maybe the solution I propose there can help you. Otherwise doing the parallelisation in the batch file is also a solution.

Just wanted to mention that.

Hi @marpet,
I am trying to use the gpt tool to run a .xml script I made in graph builder. I can’t uderstand the reason but when I run from cmd the gpt.exe it gives me an error as you can see in the screenshot. I m a little bit stuck because I ve been reading tutorials and so on but I don’t understand where is the error. I ve also just tried to run the simple comand " gpt -h" but it gives me the same problem. I ll be thankful for any help.

I think i ve solved the problem…i just install SNAP again and now it s working properly. Thanks anyway!

I think this error occurred in an older S2TBX version. Not sure, maybe 5.0.2.
Probably you have now updated to a new version or have not installed S2TBX at all.

@ramona_manda, @kraftek, @Nicolas
Can you confirm?

It was fixed in s2tbx 5.0.5 (at the time of the post, the fix was not published, so probably Mike did not install s2tbx any more).

hi,where did you find the tutorial on command line for processing? could you share the links or send the copy of raleted materials to my Email ( thanks very much! I am also new to this field.

Hi @weishao ,

here you can find example scripts for command line processing in Windows and Linux:

1 Like

thank you very much , my dear friend!