data_method = """
def F_${data_name}(statut) : return FACT(statut = statut,
- FROM = SIMP(statut = "o", typ = "TXM", into=(${data_into})),
+ FILE = SIMP(statut = "o", typ = "TXM", into=(${data_into})),
${data_bloc}
)
"""
+init_method = """
+def F_InitChoice() : return ("Background",
+ "BackgroundError",
+ "Observation",
+ "ObservationError",
+ "ObservationOperator",
+ "AlgorithmParameters",
+ "Analysis",
+ )
+def F_Init(statut) : return FACT(statut = statut,
+ FILE = SIMP(statut = "o", typ = "Fichier"),
+ TARGET_LIST = SIMP(statut = "o", typ = "TXM", min=1, max="**", into=F_InitChoice()),
+ )
+"""
assim_data_method = """
def F_${assim_name}(statut) : return FACT(statut=statut,
regles = ( UN_PARMI (${choices})),
ObservationError = F_ObservationError("o"),
ObservationOperator = F_ObservationOperator("o"),
AlgorithmParameters = F_AlgorithmParameters("f"),
+ Init = F_Init("f"),
${decl_opts}
),
"""
opt_names.append(opt_name)
+# Step 5: Add init node
+mem_file.write(init_method)
+
# Final step: Add algorithm and assim_study
algos = ""
decl_algos = ""