Graph Processing Tool execution error
Posted: Thu Dec 21, 2017 2:52 am America/New_York
Hi,
I was trying to run the following XML code.
node id="bandmathsNode">
<operator>BandMaths</operator>
<sources>
<sourceProducts>${source}</sourceProducts>
</sources>
<parameters>
<targetBands>
<targetBand>
<name>sst</name>
<expression>!MY_MASK ? sst : NaN</expression>
<description>sst</description>
<type>float32</type>
<validexpression>sst > 5 AND sst < 50</validexpression>
<noDataValue>-32767.0</noDataValue>
</targetBand>
</targetBands>
<variables>
<variable>
<name>MY_MASK</name>
<type>boolean</type>
<value>(l2_flags.CLDICE || l2_flags.STRAYLIGHT)
</value>
</variable>
</variables>
</parameters>
</node>
But ended up with the following error....
rslab@rslab-pc:~/swathy/asian_conference_test$ gpt.sh -h BandMaths.xml -Ssource=A2006001084500.L2_LAC_SST -t A2006001084500.L2_LAC_SST_bandmath -f netCDF4 CF
java.lang.ClassCastException: org.esa.beam.framework.gpf.graph.Node cannot be cast to org.esa.beam.framework.gpf.graph.Graph
at org.esa.beam.framework.gpf.graph.GraphIO.read(GraphIO.java:83)
at org.esa.beam.framework.gpf.main.DefaultCommandLineContext.readGraph(DefaultCommandLineContext.java:71)
at org.esa.beam.framework.gpf.main.CommandLineUsage.getUsageTextForGraph(CommandLineUsage.java:113)
at org.esa.beam.framework.gpf.main.CommandLineTool.printHelp(CommandLineTool.java:138)
at org.esa.beam.framework.gpf.main.CommandLineTool.run(CommandLineTool.java:119)
at org.esa.beam.framework.gpf.main.GPT.run(GPT.java:54)
at org.esa.beam.framework.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 com.bc.ceres.launcher.Launcher.launch(Launcher.java:154)
at com.bc.ceres.launcher.Launcher.main(Launcher.java:56)
Error: org.esa.beam.framework.gpf.graph.Node cannot be cast to org.esa.beam.framework.gpf.graph.Graph
It will be great if any of you can help me to solve this issue. I checked my connection, updated module manager but the result is same. Kindly give me some suggestions to sort it out...
Swathy.
I was trying to run the following XML code.
node id="bandmathsNode">
<operator>BandMaths</operator>
<sources>
<sourceProducts>${source}</sourceProducts>
</sources>
<parameters>
<targetBands>
<targetBand>
<name>sst</name>
<expression>!MY_MASK ? sst : NaN</expression>
<description>sst</description>
<type>float32</type>
<validexpression>sst > 5 AND sst < 50</validexpression>
<noDataValue>-32767.0</noDataValue>
</targetBand>
</targetBands>
<variables>
<variable>
<name>MY_MASK</name>
<type>boolean</type>
<value>(l2_flags.CLDICE || l2_flags.STRAYLIGHT)
</value>
</variable>
</variables>
</parameters>
</node>
But ended up with the following error....
rslab@rslab-pc:~/swathy/asian_conference_test$ gpt.sh -h BandMaths.xml -Ssource=A2006001084500.L2_LAC_SST -t A2006001084500.L2_LAC_SST_bandmath -f netCDF4 CF
java.lang.ClassCastException: org.esa.beam.framework.gpf.graph.Node cannot be cast to org.esa.beam.framework.gpf.graph.Graph
at org.esa.beam.framework.gpf.graph.GraphIO.read(GraphIO.java:83)
at org.esa.beam.framework.gpf.main.DefaultCommandLineContext.readGraph(DefaultCommandLineContext.java:71)
at org.esa.beam.framework.gpf.main.CommandLineUsage.getUsageTextForGraph(CommandLineUsage.java:113)
at org.esa.beam.framework.gpf.main.CommandLineTool.printHelp(CommandLineTool.java:138)
at org.esa.beam.framework.gpf.main.CommandLineTool.run(CommandLineTool.java:119)
at org.esa.beam.framework.gpf.main.GPT.run(GPT.java:54)
at org.esa.beam.framework.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 com.bc.ceres.launcher.Launcher.launch(Launcher.java:154)
at com.bc.ceres.launcher.Launcher.main(Launcher.java:56)
Error: org.esa.beam.framework.gpf.graph.Node cannot be cast to org.esa.beam.framework.gpf.graph.Graph
It will be great if any of you can help me to solve this issue. I checked my connection, updated module manager but the result is same. Kindly give me some suggestions to sort it out...
Swathy.