Support team_gpt

Dear support team ,
When I use gpt in CMD I get the following error,
Can you guide me?
Best

Processing D:\new\input_unzip\S2A_MSIL2A_20190828T070621_N0213_R106_T39SXV_20190828T112118.SAFE
INFO: org.esa.snap.core.gpf.operators.tooladapter.ToolAdapterIO: Initializing external tool adapters
INFO: org.esa.s2tbx.dataio.gdal.GDALVersion: GDAL not found on system. Internal GDAL 3.0.0 from distribution will be used. (f1)
INFO: org.esa.s2tbx.dataio.gdal.GDALVersion: Internal GDAL 3.0.0 set to be used by SNAP.
INFO: org.esa.snap.core.util.EngineVersionCheckActivator: Please check regularly for new updates for the best SNAP experience.
java.lang.IllegalArgumentException: [path] is an empty string
at org.esa.snap.core.util.Guardian.assertNonEmptyString(Guardian.java:326)
at org.esa.snap.core.util.Guardian.assertNotNullOrEmpty(Guardian.java:89)
at org.esa.snap.core.util.io.FileUtils.getExtensionDotPos(FileUtils.java:232)
at org.esa.snap.core.util.io.FileUtils.getExtension(FileUtils.java:70)
at org.esa.snap.core.gpf.main.CommandLineArgs.parseArgs(CommandLineArgs.java:187)
at org.esa.snap.core.gpf.main.CommandLineArgs.parseArgs(CommandLineArgs.java:79)
at org.esa.snap.core.gpf.main.CommandLineTool.run(CommandLineTool.java:112)
at org.esa.snap.core.gpf.main.GPT.run(GPT.java:54)
at org.esa.snap.core.gpf.main.GPT.main(GPT.java:34)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.esa.snap.runtime.Launcher.lambda$run$0(Launcher.java:55)
at org.esa.snap.runtime.Engine.runClientCode(Engine.java:189)
at org.esa.snap.runtime.Launcher.run(Launcher.java:51)
at org.esa.snap.runtime.Launcher.main(Launcher.java:31)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at com.exe4j.runtime.LauncherEngine.launch(LauncherEngine.java:84)
at com.exe4j.runtime.WinLauncher.main(WinLauncher.java:94)
at com.install4j.runtime.launcher.WinLauncher.main(WinLauncher.java:25)

Error: [path] is an empty string

How much i run code resample


I do not get output, someone could help.

image graph.xml (528 Bytes) processDataset.bat (1.9 KB) resample_20m.properties (47 Bytes)

D:\new>processDataset.bat graph.xml resample_20m.properties “D:\new\input_zip” “D:\new\output” resa

D:\new>setlocal ENABLEDELAYEDEXPANSION

D:\new>set gptPath=“C:\Program Files\snap\bin\gpt.exe”

D:\new>set graphXmlPath=graph.xml

D:\new>set parameterFilePath=resample_20m.properties

D:\new>set sourceDirectory=“D:\new\input_zip”

D:\new>set targetDirectory=“D:\new\output”

D:\new>set targetFilePrefix=resa

D:\new>md “D:\new\output”
A subdirectory or file D:\new\output already exists.

D:\new>for / F in (S2*.SAFE) do ( echo. set sourceFile=~fF
echo Processing !sourceFile!
set targetFile=“D:\new\output”\resa_%~nF.dim
set procCmd=“C:\Program Files\snap\bin\gpt.exe” graph.xml -e -p resample_20m.properties -t “!targetFile!” “!sourceFile!”
call !procCmd!
)

You have to fill the xml and bat files with your own directories, otherwise it would never run. Could you tell us what you want to do exactly?

This is an example.
I want to do a resampling.Can you tell me what the problem is?

The graphXmlPath and parameterFilePath arguments must require the full path (not just the names as you have used). Assuming these files are in the D:\new directory, try:

D:\new>processDataset.bat "D:\new\graph.xml" "D:\new\resample_20m.properties"  “D:\new\input_zip” “D:\new\output” resa