]> SALOME platform Git repositories - modules/adao.git/commitdiff
Salome HOME
Ajout input output
authorAndré Ribes <andre.ribes@edf.fr>
Thu, 24 Mar 2011 10:39:05 +0000 (11:39 +0100)
committerAndré Ribes <andre.ribes@edf.fr>
Thu, 24 Mar 2011 10:39:05 +0000 (11:39 +0100)
bin/AdaoCatalogGenerator.py
src/daEficas/generator_adao.py

index 548cecf66a2e4ded3af9a96a467d787cbf35a8c8..c36656cb6662fab3a69ba547142702aded35b98a 100644 (file)
@@ -114,8 +114,8 @@ ASSIMILATION_STUDY = PROC(nom="ASSIMILATION_STUDY",
                           AlgorithmParameters = F_AlgorithmParameters("f"),
                           UserDataInit        = F_Init("f"),
                           UserPostAnalysis    = F_UserPostAnalysis("f"),
-                          InputVariables      = F_variables("o"),
-                          OutputVariables     = F_variables("o")
+                          InputVariables      = F_variables("f"),
+                          OutputVariables     = F_variables("f")
                          )
 """
 
index 1bf9ecd96814c6f8740d0b2144af8e10a93072d7..28b14b7c48a42a206f55f867e0bb3f084c61447a 100644 (file)
@@ -92,6 +92,7 @@ class AdaoGenerator(PythonGenerator):
     self.add_data("ObservationError")
     self.add_data("ObservationOperator")
 
+    self.add_variables()
     # Parametres optionnels
 
     # Extraction du Study_repertory
@@ -189,3 +190,21 @@ class AdaoGenerator(PythonGenerator):
       self.text_da += "study_config[\"UserPostAnalysis\"] = Analysis_config \n"
     else:
       raise Exception('From Type unknown', from_type)
+
+  def add_variables(self):
+
+    # Input variables
+    if "__ASSIMILATION_STUDY__InputVariables__NAMES" in self.dictMCVal.keys():
+      pass
+    else:
+      self.text_da += "inputvariables_config = {} \n"
+      self.text_da += "inputvariables_config[\"adao_default\"] = -1 \n"
+      self.text_da += "study_config[\"InputVariables\"] = inputvariables_config \n"
+
+    # Output variables
+    if "__ASSIMILATION_STUDY__OutputVariables__NAMES" in self.dictMCVal.keys():
+      pass
+    else:
+      self.text_da += "variables_config = {} \n"
+      self.text_da += "outputvariables_config[\"adao_default\"] = -1 \n"
+      self.text_da += "study_config[\"OutputVariables\"] = ouputvariables_config \n"