Salome HOME
8984357bcff40941df90dbe654ad54c1f895ee68
[modules/adao.git] / resources / DATASSIMSchemaCatalog.xml
1 <?xml version='1.0' encoding='iso-8859-1' ?>
2 <proc>
3   
4   <objref name="computeAD" id="python:computeAD:1.0">
5     <base>pyobj</base>
6   </objref>
7
8   <inline name="CreateAssimilationStudy">
9     <script><code>
10
11 <![CDATA[
12 import numpy
13 print "Entering in CreateAssimilationStudy"
14 print "Name is", Name
15 print "Algorithm is", Algorithm
16
17
18 # Data
19 print "Data entered are:"
20 # Background
21 try:
22   Background
23 except NameError:
24   pass
25 else:
26   print "Background is", Background
27   print "BackgroundType is", BackgroundType
28
29 # BackgroundError
30 try:
31   BackgroundError
32 except NameError:
33   pass
34 else:
35   print "BackgroundError is", BackgroundError
36   print "BackgroundErrorType is", BackgroundErrorType
37
38 # Observation
39 try:
40   Observation
41 except NameError:
42   pass
43 else:
44   print "Observation is", Observation
45   print "ObservationType is", ObservationType
46
47 # ObservationError
48 try:
49   ObservationError
50 except NameError:
51   pass
52 else:
53   print "ObservationError is", ObservationError
54   print "ObservationErrorType is", ObservationErrorType
55
56 # ObservationOperator
57 try:
58   ObservationOperator
59 except NameError:
60   pass
61 else:
62   print "ObservationOperator is", ObservationOperator
63   print "ObservationOperatorType is", ObservationOperatorType
64
65 ]]>
66
67 </code></script>
68     <inport name="Name" type="string"/>
69     <inport name="Algorithm" type="string"/>
70   </inline>
71
72   <inline name="CreateNumpyMatrixFromString">
73     <script><code><![CDATA[
74 print "Entering in CreateNumpyMatrixFromString"
75 import numpy
76 matrix = numpy.matrix(matrix_in_string)
77 type = "Matrix"
78 print "Matrix is", matrix
79 ]]></code></script>
80     <inport name="matrix_in_string" type="string"/>
81     <outport name="matrix" type="pyobj"/>
82     <outport name="type" type="string"/>
83   </inline>
84
85   <inline name="CreateNumpyVectorFromString">
86     <script><code><![CDATA[
87 print "Entering in CreateNumpyVectorFromString"
88 import numpy
89 vector = numpy.matrix(vector_in_string)
90 type = "Vector"
91 print "Vector is", vector
92 ]]></code></script>
93     <inport name="vector_in_string" type="string"/>
94     <outport name="vector" type="pyobj"/>
95     <outport name="type" type="string"/>
96   </inline>
97
98 </proc>