From 914de341fd66b2a6d5427f2b439b12e85992a86a Mon Sep 17 00:00:00 2001 From: jfa Date: Sat, 6 May 2006 08:57:14 +0000 Subject: [PATCH] Join modifications from branch OCC_debug_for_3_2_0b1 --- Superv/Graphs/GeomGraph_py.xml | 5 +- Superv/Graphs/GraphGeomEssai_py.xml | 5 +- Superv/Graphs/GraphInconsistencyTypes.xml | 114 +++++ Superv/Graphs/GraphNoEqualInPortsNumber.xml | 95 ++++ Superv/Graphs/GraphNoInputData.xml | 104 +++++ .../Graphs/GraphNotClosedChainInsideLoop.xml | 433 ++++++++++++++++++ .../GraphNotClosedChainInsideSwitch.xml | 428 +++++++++++++++++ Superv/Graphs/GraphPythonSyntaxError.xml | 113 +++++ Superv/Graphs/MacroWithGeom_py.xml | 5 +- Superv/Graphs/NewGraphGeomEssai_py.xml | 5 +- Superv/Python/GraphInconsistencyTypes.py | 41 ++ Superv/Python/GraphNoEqualInPortsNumber.py | 39 ++ Superv/Python/GraphNoInputData.py | 41 ++ .../Python/GraphNotClosedChainInsideLoop.py | 142 ++++++ .../Python/GraphNotClosedChainInsideSwitch.py | 143 ++++++ Superv/Python/GraphPythonSyntaxError.py | 40 ++ 16 files changed, 1749 insertions(+), 4 deletions(-) create mode 100644 Superv/Graphs/GraphInconsistencyTypes.xml create mode 100644 Superv/Graphs/GraphNoEqualInPortsNumber.xml create mode 100644 Superv/Graphs/GraphNoInputData.xml create mode 100644 Superv/Graphs/GraphNotClosedChainInsideLoop.xml create mode 100644 Superv/Graphs/GraphNotClosedChainInsideSwitch.xml create mode 100644 Superv/Graphs/GraphPythonSyntaxError.xml create mode 100644 Superv/Python/GraphInconsistencyTypes.py create mode 100644 Superv/Python/GraphNoEqualInPortsNumber.py create mode 100644 Superv/Python/GraphNoInputData.py create mode 100644 Superv/Python/GraphNotClosedChainInsideLoop.py create mode 100644 Superv/Python/GraphNotClosedChainInsideSwitch.py create mode 100644 Superv/Python/GraphPythonSyntaxError.py diff --git a/Superv/Graphs/GeomGraph_py.xml b/Superv/Graphs/GeomGraph_py.xml index d6ea4e9..fa64447 100644 --- a/Superv/Graphs/GeomGraph_py.xml +++ b/Superv/Graphs/GeomGraph_py.xml @@ -344,7 +344,10 @@ - + + + + diff --git a/Superv/Graphs/GraphGeomEssai_py.xml b/Superv/Graphs/GraphGeomEssai_py.xml index 52ca0b5..686ab10 100644 --- a/Superv/Graphs/GraphGeomEssai_py.xml +++ b/Superv/Graphs/GraphGeomEssai_py.xml @@ -205,7 +205,10 @@ - + + + + diff --git a/Superv/Graphs/GraphInconsistencyTypes.xml b/Superv/Graphs/GraphInconsistencyTypes.xml new file mode 100644 index 0000000..ceadfe3 --- /dev/null +++ b/Superv/Graphs/GraphInconsistencyTypes.xml @@ -0,0 +1,114 @@ + + + + + + ? + ? + aNewDataFlow_4 + 1 + ? + + aNewDataFlow_4 + + + double + MulNode__a + + + double + MulNode__b + + + + + string + MulNode__c + + + + + + 14/4/2006 - 15:16:9 + 14/4/2006 - 15:16:12 + 3.0 + ? + ? + ? + 0 + 0 + + + + + ? + ? + MulNode + 3 + ? + + MulNode + + + double + a + + + double + b + + + + + string + c + + + + + + + MulNode + + + + + + 14/4/2006 - 15:16:12 + 14/4/2006 - 15:16:12 + 3.0 + ? + ? + Compute Node + 0 + 0 + + + + + + aNewDataFlow_4 + MulNode__a + MulNode + a + + 7 + 10.5 + + + + + aNewDataFlow_4 + MulNode__b + MulNode + b + + 7 + 2 + + + + + + + diff --git a/Superv/Graphs/GraphNoEqualInPortsNumber.xml b/Superv/Graphs/GraphNoEqualInPortsNumber.xml new file mode 100644 index 0000000..e85ee18 --- /dev/null +++ b/Superv/Graphs/GraphNoEqualInPortsNumber.xml @@ -0,0 +1,95 @@ + + + + + + ? + ? + aNewDataFlow_3 + 1 + ? + + aNewDataFlow_3 + + + double + MulNode__a + + + + + double + MulNode__c + + + + + + 14/4/2006 - 15:8:0 + 14/4/2006 - 15:11:16 + 3.0 + ? + ? + ? + 0 + 0 + + + + + ? + ? + MulNode + 3 + ? + + MulNode + + + double + a + + + + + double + c + + + + + + + MulNode + + + + + + 14/4/2006 - 15:11:16 + 14/4/2006 - 15:11:16 + 3.0 + ? + ? + Compute Node + 0 + 0 + + + + + + aNewDataFlow_3 + MulNode__a + MulNode + a + + 7 + 10.5 + + + + + + + diff --git a/Superv/Graphs/GraphNoInputData.xml b/Superv/Graphs/GraphNoInputData.xml new file mode 100644 index 0000000..8d933f0 --- /dev/null +++ b/Superv/Graphs/GraphNoInputData.xml @@ -0,0 +1,104 @@ + + + + + + ? + ? + aNewDataFlow_1 + 1 + ? + + aNewDataFlow_1 + + + double + Add__x + + + double + Add__y + + + + + double + Add__FuncValue + + + double + Add__z + + + + + + 14/4/2006 - 14:54:2 + 14/4/2006 - 14:54:16 + 3.0 + ? + ? + ? + 0 + 0 + + + + + AddComponent + AddComponent + Add + 0 + ? + + Add + + + double + x + + + double + y + + + + + double + FuncValue + + + double + z + + + + + + 14/4/2006 - 14:54:16 + 14/4/2006 - 14:54:16 + 3.0 + ? + localhost/FactoryServer + Add from AddComponent + 0 + 0 + + + + + + aNewDataFlow_1 + Add__x + Add + x + + 7 + 0.4 + + + + + + + diff --git a/Superv/Graphs/GraphNotClosedChainInsideLoop.xml b/Superv/Graphs/GraphNotClosedChainInsideLoop.xml new file mode 100644 index 0000000..67a7d45 --- /dev/null +++ b/Superv/Graphs/GraphNotClosedChainInsideLoop.xml @@ -0,0 +1,433 @@ + + + + + + ? + ? + GraphSwitch + 1 + ? + + GraphSwitch + + + long + InitLoopSwitch__Index + + + long + InitLoopSwitch__Min + + + long + InitLoopSwitch__Max + + + + + long + EndOfInitLoopSwitch__Index + + + long + EndOfInitLoopSwitch__Min + + + long + EndOfInitLoopSwitch__Max + + + int + Switch__Even + + + long + EndOfSwitch__a + + + + + + 1/10/2003 - 17:23:54 + 14/4/2006 - 15:47:47 + 1.05 + ? + ? + ? + 0 + 0 + + + + + ? + ? + IsOdd + 3 + ? + + IsOdd + + + long + a + + + + + long + a + + + + + + + IsOdd + + + + + + + + 14/4/2006 - 15:42:11 + 14/4/2006 - 15:42:11 + 1.05 + ? + ? + Python function + 389 + 65 + + + ? + ? + InitLoopSwitch + 4 + EndOfInitLoopSwitch + + InitLoopSwitch + + + long + Index + + + long + Min + + + long + Max + + + + + long + Index + + + long + Min + + + long + Max + + + + + + + InitLoop + + + + + MoreLoop + + + + + + + + + NextLoop + + + + + + 14/4/2006 - 15:42:11 + 14/4/2006 - 15:42:11 + 1.05 + ? + ? + Compute Node + 10 + 129 + + + ? + ? + EndOfInitLoopSwitch + 5 + InitLoopSwitch + + EndOfInitLoopSwitch + + + long + Index + + + long + Min + + + long + Max + + + + + long + Index + + + long + Min + + + long + Max + + + + + + + ? + + + + 14/4/2006 - 15:42:11 + 14/4/2006 - 15:42:11 + 1.05 + ? + ? + Compute Node + 776 + 170 + + + ? + ? + Switch + 6 + EndOfSwitch + + Switch + + + long + a + + + + + long + Odd + + + int + Even + + + int + a + + + + + + + Switch + + + + + + + + 14/4/2006 - 15:42:11 + 14/4/2006 - 15:42:11 + 1.05 + ? + ? + Compute Node + 194 + 129 + + + ? + ? + EndOfSwitch + 7 + Switch + + EndOfSwitch + + + long + a + + + + + long + a + + + + + + + ? + + + + 14/4/2006 - 15:42:11 + 14/4/2006 - 15:42:11 + 1.05 + ? + ? + Compute Node + 582 + 170 + + + + + IsOdd + a + EndOfSwitch + a + + + 564 + 201 + + + 564 + 134 + + + + + InitLoopSwitch + DoLoop + EndOfInitLoopSwitch + DoLoop + + + + InitLoopSwitch + Index + Switch + a + + + + InitLoopSwitch + Min + EndOfInitLoopSwitch + Min + + + + InitLoopSwitch + Max + EndOfInitLoopSwitch + Max + + + + EndOfInitLoopSwitch + DoLoop + InitLoopSwitch + DoLoop + + + + Switch + Odd + IsOdd + Gate + + + + Switch + a + IsOdd + a + + + 371 + 136 + + + 371 + 200 + + + + + Switch + Default + EndOfSwitch + Default + + + + + + GraphSwitch + InitLoopSwitch__Index + InitLoopSwitch + Index + + 3 + 0 + + + + + GraphSwitch + InitLoopSwitch__Min + InitLoopSwitch + Min + + 3 + 0 + + + + + GraphSwitch + InitLoopSwitch__Max + InitLoopSwitch + Max + + 3 + 35 + + + + + + + diff --git a/Superv/Graphs/GraphNotClosedChainInsideSwitch.xml b/Superv/Graphs/GraphNotClosedChainInsideSwitch.xml new file mode 100644 index 0000000..47db5ad --- /dev/null +++ b/Superv/Graphs/GraphNotClosedChainInsideSwitch.xml @@ -0,0 +1,428 @@ + + + + + + ? + ? + GraphSwitch + 1 + ? + + GraphSwitch + + + long + InitLoopSwitch__Index + + + long + InitLoopSwitch__Min + + + long + InitLoopSwitch__Max + + + long + EndOfSwitch__a + + + + + long + IsOdd__a + + + long + EndOfInitLoopSwitch__Index + + + long + EndOfInitLoopSwitch__Min + + + long + EndOfInitLoopSwitch__Max + + + int + Switch__Even + + + + + + 1/10/2003 - 17:23:54 + 14/4/2006 - 15:42:25 + 1.05 + ? + ? + ? + 0 + 0 + + + + + ? + ? + IsOdd + 3 + ? + + IsOdd + + + long + a + + + + + long + a + + + + + + + IsOdd + + + + + + + + 14/4/2006 - 15:42:11 + 14/4/2006 - 15:42:11 + 1.05 + ? + ? + Python function + 389 + 65 + + + ? + ? + InitLoopSwitch + 4 + EndOfInitLoopSwitch + + InitLoopSwitch + + + long + Index + + + long + Min + + + long + Max + + + + + long + Index + + + long + Min + + + long + Max + + + + + + + InitLoop + + + + + MoreLoop + + + + + + + + + NextLoop + + + + + + 14/4/2006 - 15:42:11 + 14/4/2006 - 15:42:11 + 1.05 + ? + ? + Compute Node + 10 + 129 + + + ? + ? + EndOfInitLoopSwitch + 5 + InitLoopSwitch + + EndOfInitLoopSwitch + + + long + Index + + + long + Min + + + long + Max + + + + + long + Index + + + long + Min + + + long + Max + + + + + + + ? + + + + 14/4/2006 - 15:42:11 + 14/4/2006 - 15:42:11 + 1.05 + ? + ? + Compute Node + 776 + 170 + + + ? + ? + Switch + 6 + EndOfSwitch + + Switch + + + long + a + + + + + long + Odd + + + int + Even + + + int + a + + + + + + + Switch + + + + + + + + 14/4/2006 - 15:42:11 + 14/4/2006 - 15:42:11 + 1.05 + ? + ? + Compute Node + 194 + 129 + + + ? + ? + EndOfSwitch + 7 + Switch + + EndOfSwitch + + + long + a + + + + + long + a + + + + + + + ? + + + + 14/4/2006 - 15:42:11 + 14/4/2006 - 15:42:11 + 1.05 + ? + ? + Compute Node + 582 + 170 + + + + + InitLoopSwitch + DoLoop + EndOfInitLoopSwitch + DoLoop + + + + InitLoopSwitch + Index + Switch + a + + + + InitLoopSwitch + Min + EndOfInitLoopSwitch + Min + + + + InitLoopSwitch + Max + EndOfInitLoopSwitch + Max + + + + EndOfInitLoopSwitch + DoLoop + InitLoopSwitch + DoLoop + + + + Switch + Odd + IsOdd + Gate + + + + Switch + a + IsOdd + a + + + 371 + 136 + + + 371 + 200 + + + + + Switch + Default + EndOfSwitch + Default + + + + EndOfSwitch + a + EndOfInitLoopSwitch + Index + + + + + + GraphSwitch + InitLoopSwitch__Index + InitLoopSwitch + Index + + 3 + 0 + + + + + GraphSwitch + InitLoopSwitch__Min + InitLoopSwitch + Min + + 3 + 0 + + + + + GraphSwitch + InitLoopSwitch__Max + InitLoopSwitch + Max + + 3 + 35 + + + + + + + diff --git a/Superv/Graphs/GraphPythonSyntaxError.xml b/Superv/Graphs/GraphPythonSyntaxError.xml new file mode 100644 index 0000000..6ffa52c --- /dev/null +++ b/Superv/Graphs/GraphPythonSyntaxError.xml @@ -0,0 +1,113 @@ + + + + + + ? + ? + aNewDataFlow_2 + 1 + ? + + aNewDataFlow_2 + + + boolean + ErrorNode__a + + + boolean + ErrorNode__b + + + + + boolean + ErrorNode__c + + + + + + 14/4/2006 - 14:55:17 + 14/4/2006 - 15:0:48 + 3.0 + ? + ? + ? + 0 + 0 + + + + + ? + ? + ErrorNode + 3 + ? + + ErrorNode + + + boolean + a + + + boolean + b + + + + + boolean + c + + + + + + + ErrorNode + + + + + 14/4/2006 - 15:0:48 + 14/4/2006 - 15:0:48 + 3.0 + ? + ? + Compute Node + 0 + 0 + + + + + + aNewDataFlow_2 + ErrorNode__a + ErrorNode + a + + 3 + 1 + + + + + aNewDataFlow_2 + ErrorNode__b + ErrorNode + b + + 3 + 0 + + + + + + + diff --git a/Superv/Graphs/MacroWithGeom_py.xml b/Superv/Graphs/MacroWithGeom_py.xml index f73d935..236bb99 100644 --- a/Superv/Graphs/MacroWithGeom_py.xml +++ b/Superv/Graphs/MacroWithGeom_py.xml @@ -307,7 +307,10 @@ - + + + + diff --git a/Superv/Graphs/NewGraphGeomEssai_py.xml b/Superv/Graphs/NewGraphGeomEssai_py.xml index 17ad7ca..1a8c024 100644 --- a/Superv/Graphs/NewGraphGeomEssai_py.xml +++ b/Superv/Graphs/NewGraphGeomEssai_py.xml @@ -214,7 +214,10 @@ - + + + + diff --git a/Superv/Python/GraphInconsistencyTypes.py b/Superv/Python/GraphInconsistencyTypes.py new file mode 100644 index 0000000..e87435d --- /dev/null +++ b/Superv/Python/GraphInconsistencyTypes.py @@ -0,0 +1,41 @@ + +# Generated python file of Graph aNewDataFlow_4 + +from SuperV import * + +# Graph creation of aNewDataFlow_4 +def DefaNewDataFlow_4() : + aNewDataFlow_4 = Graph( 'aNewDataFlow_4' ) + aNewDataFlow_4.SetName( 'aNewDataFlow_4' ) + aNewDataFlow_4.SetAuthor( '' ) + aNewDataFlow_4.SetComment( '' ) + aNewDataFlow_4.Coords( 0 , 0 ) + + # Creation of Factory Nodes + + # Creation of InLine Nodes + PyMulNode = [] + PyMulNode.append( 'def MulNode(a,b): ' ) + PyMulNode.append( ' c = a*b ' ) + PyMulNode.append( ' return c ' ) + MulNode = aNewDataFlow_4.INode( 'MulNode' , PyMulNode ) + MulNode.SetName( 'MulNode' ) + MulNode.SetAuthor( '' ) + MulNode.SetComment( 'Compute Node' ) + MulNode.Coords( 0 , 0 ) + IMulNodea = MulNode.InPort( 'a' , 'double' ) + IMulNodeb = MulNode.InPort( 'b' , 'double' ) + IMulNodeGate = MulNode.GetInPort( 'Gate' ) + OMulNodec = MulNode.OutPort( 'c' , 'string' ) + OMulNodeGate = MulNode.GetOutPort( 'Gate' ) + + # Input datas + IMulNodea.Input( 10.5 ) + IMulNodeb.Input( 2 ) + + # Output Ports of the graph + #OMulNodec = MulNode.GetOutPort( 'c' ) + return aNewDataFlow_4 + + +aNewDataFlow_4 = DefaNewDataFlow_4() diff --git a/Superv/Python/GraphNoEqualInPortsNumber.py b/Superv/Python/GraphNoEqualInPortsNumber.py new file mode 100644 index 0000000..1279671 --- /dev/null +++ b/Superv/Python/GraphNoEqualInPortsNumber.py @@ -0,0 +1,39 @@ + +# Generated python file of Graph aNewDataFlow_3 + +from SuperV import * + +# Graph creation of aNewDataFlow_3 +def DefaNewDataFlow_3() : + aNewDataFlow_3 = Graph( 'aNewDataFlow_3' ) + aNewDataFlow_3.SetName( 'aNewDataFlow_3' ) + aNewDataFlow_3.SetAuthor( '' ) + aNewDataFlow_3.SetComment( '' ) + aNewDataFlow_3.Coords( 0 , 0 ) + + # Creation of Factory Nodes + + # Creation of InLine Nodes + PyMulNode = [] + PyMulNode.append( 'def MulNode(a,b): ' ) + PyMulNode.append( ' c = a*b ' ) + PyMulNode.append( ' return c ' ) + MulNode = aNewDataFlow_3.INode( 'MulNode' , PyMulNode ) + MulNode.SetName( 'MulNode' ) + MulNode.SetAuthor( '' ) + MulNode.SetComment( 'Compute Node' ) + MulNode.Coords( 0 , 0 ) + IMulNodea = MulNode.InPort( 'a' , 'double' ) + IMulNodeGate = MulNode.GetInPort( 'Gate' ) + OMulNodec = MulNode.OutPort( 'c' , 'double' ) + OMulNodeGate = MulNode.GetOutPort( 'Gate' ) + + # Input datas + IMulNodea.Input( 10.5 ) + + # Output Ports of the graph + #OMulNodec = MulNode.GetOutPort( 'c' ) + return aNewDataFlow_3 + + +aNewDataFlow_3 = DefaNewDataFlow_3() diff --git a/Superv/Python/GraphNoInputData.py b/Superv/Python/GraphNoInputData.py new file mode 100644 index 0000000..fcfdfd5 --- /dev/null +++ b/Superv/Python/GraphNoInputData.py @@ -0,0 +1,41 @@ + +# Generated python file of Graph aNewDataFlow_1 + +from SuperV import * + +# Graph creation of aNewDataFlow_1 +def DefaNewDataFlow_1() : + aNewDataFlow_1 = Graph( 'aNewDataFlow_1' ) + aNewDataFlow_1.SetName( 'aNewDataFlow_1' ) + aNewDataFlow_1.SetAuthor( '' ) + aNewDataFlow_1.SetComment( '' ) + aNewDataFlow_1.Coords( 0 , 0 ) + + # Creation of Factory Nodes + + Add = aNewDataFlow_1.FNode( 'AddComponent' , 'AddComponent' , 'Add' ) + Add.SetName( 'Add' ) + Add.SetAuthor( '' ) + Add.SetContainer( 'localhost/FactoryServer' ) + Add.SetComment( 'Add from AddComponent' ) + Add.Coords( 0 , 0 ) + IAddx = Add.GetInPort( 'x' ) + IAddy = Add.GetInPort( 'y' ) + IAddGate = Add.GetInPort( 'Gate' ) + OAddFuncValue = Add.GetOutPort( 'FuncValue' ) + OAddz = Add.GetOutPort( 'z' ) + OAddGate = Add.GetOutPort( 'Gate' ) + + # Input datas + IAddx.Input( 0.4 ) + + # Input Ports of the graph + #IAddy = Add.GetInPort( 'y' ) + + # Output Ports of the graph + #OAddFuncValue = Add.GetOutPort( 'FuncValue' ) + #OAddz = Add.GetOutPort( 'z' ) + return aNewDataFlow_1 + + +aNewDataFlow_1 = DefaNewDataFlow_1() diff --git a/Superv/Python/GraphNotClosedChainInsideLoop.py b/Superv/Python/GraphNotClosedChainInsideLoop.py new file mode 100644 index 0000000..33dbd4f --- /dev/null +++ b/Superv/Python/GraphNotClosedChainInsideLoop.py @@ -0,0 +1,142 @@ + +# Generated python file of Graph GraphSwitch + +from SuperV import * + +# Graph creation of GraphSwitch +def DefGraphSwitch() : + GraphSwitch = Graph( 'GraphSwitch' ) + GraphSwitch.SetName( 'GraphSwitch' ) + GraphSwitch.SetAuthor( '' ) + GraphSwitch.SetComment( '' ) + GraphSwitch.Coords( 0 , 0 ) + + # Creation of Factory Nodes + + # Creation of InLine Nodes + PyIsOdd = [] + PyIsOdd.append( 'from time import * ' ) + PyIsOdd.append( 'def IsOdd(a) : ' ) + PyIsOdd.append( ' print a,"IsOdd (GraphSwitch)" ' ) + PyIsOdd.append( ' sleep( 1 ) ' ) + PyIsOdd.append( ' return a ' ) + IsOdd = GraphSwitch.INode( 'IsOdd' , PyIsOdd ) + IsOdd.SetName( 'IsOdd' ) + IsOdd.SetAuthor( '' ) + IsOdd.SetComment( 'Python function' ) + IsOdd.Coords( 389 , 65 ) + IIsOdda = IsOdd.InPort( 'a' , 'long' ) + IIsOddGate = IsOdd.GetInPort( 'Gate' ) + OIsOdda = IsOdd.OutPort( 'a' , 'long' ) + OIsOddGate = IsOdd.GetOutPort( 'Gate' ) + + # Creation of Loop Nodes + PyInitLoopSwitch = [] + PyInitLoopSwitch.append( 'def InitLoop(Index,Min,Max) : ' ) + PyInitLoopSwitch.append( ' return Index,Min,Max ' ) + PyMoreInitLoopSwitch = [] + PyMoreInitLoopSwitch.append( 'def MoreLoop(Index,Min,Max) : ' ) + PyMoreInitLoopSwitch.append( ' if Index <= Max : ' ) + PyMoreInitLoopSwitch.append( ' DoLoop = 1 ' ) + PyMoreInitLoopSwitch.append( ' else : ' ) + PyMoreInitLoopSwitch.append( ' DoLoop = 0 ' ) + PyMoreInitLoopSwitch.append( ' return DoLoop,Index,Min,Max ' ) + PyNextInitLoopSwitch = [] + PyNextInitLoopSwitch.append( 'def NextLoop(Index,Min,Max) : ' ) + PyNextInitLoopSwitch.append( ' Index = Index + 1 ' ) + PyNextInitLoopSwitch.append( ' return Index,Min,Max ' ) + InitLoopSwitch,EndOfInitLoopSwitch = GraphSwitch.LNode( 'InitLoop' , PyInitLoopSwitch , 'MoreLoop' , PyMoreInitLoopSwitch , 'NextLoop' , PyNextInitLoopSwitch ) + EndOfInitLoopSwitch.SetName( 'EndOfInitLoopSwitch' ) + EndOfInitLoopSwitch.SetAuthor( '' ) + EndOfInitLoopSwitch.SetComment( 'Compute Node' ) + EndOfInitLoopSwitch.Coords( 776 , 170 ) + PyEndOfInitLoopSwitch = [] + EndOfInitLoopSwitch.SetPyFunction( '' , PyEndOfInitLoopSwitch ) + IInitLoopSwitchDoLoop = InitLoopSwitch.GetInPort( 'DoLoop' ) + IInitLoopSwitchIndex = InitLoopSwitch.InPort( 'Index' , 'long' ) + IInitLoopSwitchMin = InitLoopSwitch.InPort( 'Min' , 'long' ) + IInitLoopSwitchMax = InitLoopSwitch.InPort( 'Max' , 'long' ) + IInitLoopSwitchGate = InitLoopSwitch.GetInPort( 'Gate' ) + OInitLoopSwitchDoLoop = InitLoopSwitch.GetOutPort( 'DoLoop' ) + OInitLoopSwitchIndex = InitLoopSwitch.GetOutPort( 'Index' ) + OInitLoopSwitchMin = InitLoopSwitch.GetOutPort( 'Min' ) + OInitLoopSwitchMax = InitLoopSwitch.GetOutPort( 'Max' ) + OInitLoopSwitchGate = InitLoopSwitch.GetOutPort( 'Gate' ) + IEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetInPort( 'DoLoop' ) + IEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetInPort( 'Index' ) + IEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetInPort( 'Min' ) + IEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetInPort( 'Max' ) + IEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetInPort( 'Gate' ) + OEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetOutPort( 'DoLoop' ) + OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' ) + OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' ) + OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' ) + OEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetOutPort( 'Gate' ) + InitLoopSwitch.SetName( 'InitLoopSwitch' ) + InitLoopSwitch.SetAuthor( '' ) + InitLoopSwitch.SetComment( 'Compute Node' ) + InitLoopSwitch.Coords( 10 , 129 ) + + # Creation of Switch Nodes + PySwitch = [] + PySwitch.append( 'from time import * ' ) + PySwitch.append( 'def Switch(a) : ' ) + PySwitch.append( ' if ( a & 1 ) == 0 : ' ) + PySwitch.append( ' sleep(1) ' ) + PySwitch.append( ' return a & 1,1-(a&1),a ' ) + Switch,EndOfSwitch = GraphSwitch.SNode( 'Switch' , PySwitch ) + EndOfSwitch.SetName( 'EndOfSwitch' ) + EndOfSwitch.SetAuthor( '' ) + EndOfSwitch.SetComment( 'Compute Node' ) + EndOfSwitch.Coords( 582 , 170 ) + PyEndOfSwitch = [] + EndOfSwitch.SetPyFunction( '' , PyEndOfSwitch ) + IEndOfSwitcha = EndOfSwitch.InPort( 'a' , 'long' ) + IEndOfSwitchDefault = EndOfSwitch.GetInPort( 'Default' ) + OEndOfSwitcha = EndOfSwitch.OutPort( 'a' , 'long' ) + OEndOfSwitchGate = EndOfSwitch.GetOutPort( 'Gate' ) + Switch.SetName( 'Switch' ) + Switch.SetAuthor( '' ) + Switch.SetComment( 'Compute Node' ) + Switch.Coords( 194 , 129 ) + ISwitcha = Switch.InPort( 'a' , 'long' ) + ISwitchGate = Switch.GetInPort( 'Gate' ) + OSwitchOdd = Switch.OutPort( 'Odd' , 'long' ) + OSwitchEven = Switch.OutPort( 'Even' , 'int' ) + OSwitcha = Switch.OutPort( 'a' , 'int' ) + OSwitchDefault = Switch.GetOutPort( 'Default' ) + + # Creation of Links + LIsOddaEndOfSwitcha = GraphSwitch.Link( OIsOdda , IEndOfSwitcha ) + LIsOddaEndOfSwitcha.AddCoord( 1 , 564 , 201 ) + LIsOddaEndOfSwitcha.AddCoord( 2 , 564 , 134 ) + + LInitLoopSwitchIndexSwitcha = GraphSwitch.Link( OInitLoopSwitchIndex , ISwitcha ) + + LInitLoopSwitchMinEndOfInitLoopSwitchMin = GraphSwitch.Link( OInitLoopSwitchMin , IEndOfInitLoopSwitchMin ) + + LInitLoopSwitchMaxEndOfInitLoopSwitchMax = GraphSwitch.Link( OInitLoopSwitchMax , IEndOfInitLoopSwitchMax ) + + LSwitchOddIsOddGate = GraphSwitch.Link( OSwitchOdd , IIsOddGate ) + + LSwitchaIsOdda = GraphSwitch.Link( OSwitcha , IIsOdda ) + LSwitchaIsOdda.AddCoord( 1 , 371 , 136 ) + LSwitchaIsOdda.AddCoord( 2 , 371 , 200 ) + + LSwitchDefaultEndOfSwitchDefault = GraphSwitch.Link( OSwitchDefault , IEndOfSwitchDefault ) + + # Input datas + IInitLoopSwitchIndex.Input( 0 ) + IInitLoopSwitchMin.Input( 0 ) + IInitLoopSwitchMax.Input( 35 ) + + # Output Ports of the graph + #OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' ) + #OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' ) + #OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' ) + #OSwitchEven = Switch.GetOutPort( 'Even' ) + #OEndOfSwitcha = EndOfSwitch.GetOutPort( 'a' ) + return GraphSwitch + + +GraphSwitch = DefGraphSwitch() diff --git a/Superv/Python/GraphNotClosedChainInsideSwitch.py b/Superv/Python/GraphNotClosedChainInsideSwitch.py new file mode 100644 index 0000000..c7524f5 --- /dev/null +++ b/Superv/Python/GraphNotClosedChainInsideSwitch.py @@ -0,0 +1,143 @@ + +# Generated python file of Graph GraphSwitch + +from SuperV import * + +# Graph creation of GraphSwitch +def DefGraphSwitch() : + GraphSwitch = Graph( 'GraphSwitch' ) + GraphSwitch.SetName( 'GraphSwitch' ) + GraphSwitch.SetAuthor( '' ) + GraphSwitch.SetComment( '' ) + GraphSwitch.Coords( 0 , 0 ) + + # Creation of Factory Nodes + + # Creation of InLine Nodes + PyIsOdd = [] + PyIsOdd.append( 'from time import * ' ) + PyIsOdd.append( 'def IsOdd(a) : ' ) + PyIsOdd.append( ' print a,"IsOdd (GraphSwitch)" ' ) + PyIsOdd.append( ' sleep( 1 ) ' ) + PyIsOdd.append( ' return a ' ) + IsOdd = GraphSwitch.INode( 'IsOdd' , PyIsOdd ) + IsOdd.SetName( 'IsOdd' ) + IsOdd.SetAuthor( '' ) + IsOdd.SetComment( 'Python function' ) + IsOdd.Coords( 389 , 65 ) + IIsOdda = IsOdd.InPort( 'a' , 'long' ) + IIsOddGate = IsOdd.GetInPort( 'Gate' ) + OIsOdda = IsOdd.OutPort( 'a' , 'long' ) + OIsOddGate = IsOdd.GetOutPort( 'Gate' ) + + # Creation of Loop Nodes + PyInitLoopSwitch = [] + PyInitLoopSwitch.append( 'def InitLoop(Index,Min,Max) : ' ) + PyInitLoopSwitch.append( ' return Index,Min,Max ' ) + PyMoreInitLoopSwitch = [] + PyMoreInitLoopSwitch.append( 'def MoreLoop(Index,Min,Max) : ' ) + PyMoreInitLoopSwitch.append( ' if Index <= Max : ' ) + PyMoreInitLoopSwitch.append( ' DoLoop = 1 ' ) + PyMoreInitLoopSwitch.append( ' else : ' ) + PyMoreInitLoopSwitch.append( ' DoLoop = 0 ' ) + PyMoreInitLoopSwitch.append( ' return DoLoop,Index,Min,Max ' ) + PyNextInitLoopSwitch = [] + PyNextInitLoopSwitch.append( 'def NextLoop(Index,Min,Max) : ' ) + PyNextInitLoopSwitch.append( ' Index = Index + 1 ' ) + PyNextInitLoopSwitch.append( ' return Index,Min,Max ' ) + InitLoopSwitch,EndOfInitLoopSwitch = GraphSwitch.LNode( 'InitLoop' , PyInitLoopSwitch , 'MoreLoop' , PyMoreInitLoopSwitch , 'NextLoop' , PyNextInitLoopSwitch ) + EndOfInitLoopSwitch.SetName( 'EndOfInitLoopSwitch' ) + EndOfInitLoopSwitch.SetAuthor( '' ) + EndOfInitLoopSwitch.SetComment( 'Compute Node' ) + EndOfInitLoopSwitch.Coords( 776 , 170 ) + PyEndOfInitLoopSwitch = [] + EndOfInitLoopSwitch.SetPyFunction( '' , PyEndOfInitLoopSwitch ) + IInitLoopSwitchDoLoop = InitLoopSwitch.GetInPort( 'DoLoop' ) + IInitLoopSwitchIndex = InitLoopSwitch.InPort( 'Index' , 'long' ) + IInitLoopSwitchMin = InitLoopSwitch.InPort( 'Min' , 'long' ) + IInitLoopSwitchMax = InitLoopSwitch.InPort( 'Max' , 'long' ) + IInitLoopSwitchGate = InitLoopSwitch.GetInPort( 'Gate' ) + OInitLoopSwitchDoLoop = InitLoopSwitch.GetOutPort( 'DoLoop' ) + OInitLoopSwitchIndex = InitLoopSwitch.GetOutPort( 'Index' ) + OInitLoopSwitchMin = InitLoopSwitch.GetOutPort( 'Min' ) + OInitLoopSwitchMax = InitLoopSwitch.GetOutPort( 'Max' ) + OInitLoopSwitchGate = InitLoopSwitch.GetOutPort( 'Gate' ) + IEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetInPort( 'DoLoop' ) + IEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetInPort( 'Index' ) + IEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetInPort( 'Min' ) + IEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetInPort( 'Max' ) + IEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetInPort( 'Gate' ) + OEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetOutPort( 'DoLoop' ) + OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' ) + OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' ) + OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' ) + OEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetOutPort( 'Gate' ) + InitLoopSwitch.SetName( 'InitLoopSwitch' ) + InitLoopSwitch.SetAuthor( '' ) + InitLoopSwitch.SetComment( 'Compute Node' ) + InitLoopSwitch.Coords( 10 , 129 ) + + # Creation of Switch Nodes + PySwitch = [] + PySwitch.append( 'from time import * ' ) + PySwitch.append( 'def Switch(a) : ' ) + PySwitch.append( ' if ( a & 1 ) == 0 : ' ) + PySwitch.append( ' sleep(1) ' ) + PySwitch.append( ' return a & 1,1-(a&1),a ' ) + Switch,EndOfSwitch = GraphSwitch.SNode( 'Switch' , PySwitch ) + EndOfSwitch.SetName( 'EndOfSwitch' ) + EndOfSwitch.SetAuthor( '' ) + EndOfSwitch.SetComment( 'Compute Node' ) + EndOfSwitch.Coords( 582 , 170 ) + PyEndOfSwitch = [] + EndOfSwitch.SetPyFunction( '' , PyEndOfSwitch ) + IEndOfSwitcha = EndOfSwitch.InPort( 'a' , 'long' ) + IEndOfSwitchDefault = EndOfSwitch.GetInPort( 'Default' ) + OEndOfSwitcha = EndOfSwitch.OutPort( 'a' , 'long' ) + OEndOfSwitchGate = EndOfSwitch.GetOutPort( 'Gate' ) + Switch.SetName( 'Switch' ) + Switch.SetAuthor( '' ) + Switch.SetComment( 'Compute Node' ) + Switch.Coords( 194 , 129 ) + ISwitcha = Switch.InPort( 'a' , 'long' ) + ISwitchGate = Switch.GetInPort( 'Gate' ) + OSwitchOdd = Switch.OutPort( 'Odd' , 'long' ) + OSwitchEven = Switch.OutPort( 'Even' , 'int' ) + OSwitcha = Switch.OutPort( 'a' , 'int' ) + OSwitchDefault = Switch.GetOutPort( 'Default' ) + + # Creation of Links + LInitLoopSwitchIndexSwitcha = GraphSwitch.Link( OInitLoopSwitchIndex , ISwitcha ) + + LInitLoopSwitchMinEndOfInitLoopSwitchMin = GraphSwitch.Link( OInitLoopSwitchMin , IEndOfInitLoopSwitchMin ) + + LInitLoopSwitchMaxEndOfInitLoopSwitchMax = GraphSwitch.Link( OInitLoopSwitchMax , IEndOfInitLoopSwitchMax ) + + LSwitchOddIsOddGate = GraphSwitch.Link( OSwitchOdd , IIsOddGate ) + + LSwitchaIsOdda = GraphSwitch.Link( OSwitcha , IIsOdda ) + LSwitchaIsOdda.AddCoord( 1 , 371 , 136 ) + LSwitchaIsOdda.AddCoord( 2 , 371 , 200 ) + + LSwitchDefaultEndOfSwitchDefault = GraphSwitch.Link( OSwitchDefault , IEndOfSwitchDefault ) + + LEndOfSwitchaEndOfInitLoopSwitchIndex = GraphSwitch.Link( OEndOfSwitcha , IEndOfInitLoopSwitchIndex ) + + # Input datas + IInitLoopSwitchIndex.Input( 0 ) + IInitLoopSwitchMin.Input( 0 ) + IInitLoopSwitchMax.Input( 35 ) + + # Input Ports of the graph + #IEndOfSwitcha = EndOfSwitch.GetInPort( 'a' ) + + # Output Ports of the graph + #OIsOdda = IsOdd.GetOutPort( 'a' ) + #OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' ) + #OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' ) + #OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' ) + #OSwitchEven = Switch.GetOutPort( 'Even' ) + return GraphSwitch + + +GraphSwitch = DefGraphSwitch() diff --git a/Superv/Python/GraphPythonSyntaxError.py b/Superv/Python/GraphPythonSyntaxError.py new file mode 100644 index 0000000..626d8d6 --- /dev/null +++ b/Superv/Python/GraphPythonSyntaxError.py @@ -0,0 +1,40 @@ + +# Generated python file of Graph aNewDataFlow_2 + +from SuperV import * + +# Graph creation of aNewDataFlow_2 +def DefaNewDataFlow_2() : + aNewDataFlow_2 = Graph( 'aNewDataFlow_2' ) + aNewDataFlow_2.SetName( 'aNewDataFlow_2' ) + aNewDataFlow_2.SetAuthor( '' ) + aNewDataFlow_2.SetComment( '' ) + aNewDataFlow_2.Coords( 0 , 0 ) + + # Creation of Factory Nodes + + # Creation of InLine Nodes + PyErrorNode = [] + PyErrorNode.append( 'def ErrorNode(a,b) ' ) + PyErrorNode.append( ' return a&b ' ) + ErrorNode = aNewDataFlow_2.INode( 'ErrorNode' , PyErrorNode ) + ErrorNode.SetName( 'ErrorNode' ) + ErrorNode.SetAuthor( '' ) + ErrorNode.SetComment( 'Compute Node' ) + ErrorNode.Coords( 0 , 0 ) + IErrorNodea = ErrorNode.InPort( 'a' , 'boolean' ) + IErrorNodeb = ErrorNode.InPort( 'b' , 'boolean' ) + IErrorNodeGate = ErrorNode.GetInPort( 'Gate' ) + OErrorNodec = ErrorNode.OutPort( 'c' , 'boolean' ) + OErrorNodeGate = ErrorNode.GetOutPort( 'Gate' ) + + # Input datas + IErrorNodea.Input( 1 ) + IErrorNodeb.Input( 0 ) + + # Output Ports of the graph + #OErrorNodec = ErrorNode.GetOutPort( 'c' ) + return aNewDataFlow_2 + + +aNewDataFlow_2 = DefaNewDataFlow_2() -- 2.30.2